godotengine / godot

Godot Engine – Multi-platform 2D and 3D game engine
https://godotengine.org
MIT License
90.23k stars 21.04k forks source link

Linux arm64 warning in GDNative code: 'sysv_abi' attribute directive ignored [-Wattributes] #41160

Closed ikostan closed 10 months ago

ikostan commented 4 years ago

Godot version: 3.2.2-stable

OS/device including version: Manjaro ARM Linux (Linux 5.4.51-2-MANJARO-ARM (aarch64)) + Raspberry Pi 4 4 GB

Issue description: "warning: 'sysv_abi' attribute directive ignored [-Wattributes]" warning appears while trying to compile Godot engine

Steps to reproduce:

In general I am trying to compile Godot for my Raspberry Pi. I do that because there is no official Godot version for my setup at the moment. The full procedure description you can find here.

  1. Open terminal and run: "sudo pacman -S scons pkgconf gcc libxcursor libxinerama libxi libxrandr mesa glu alsa-lib pulseaudio \ freetype2 yasm"

  2. Download official Godot version from here: 3.2.2-stable

  3. Extract files to: "/home/superadmin/Godot/godot-3.2.2-stable/"

  4. Open terminal and run: "cd /home/superadmin/Godot/godot-3.2.2-stable/"

  5. Then run: "scons -j8 platform=x11 bits=64"

Actual results:

  1. The compile time is taking too long. By the time I open this bug it still compiling and it like this for over 1.5 hr already.
  2. Countless warnings appear in the console:

" | ^ modules/gdnative/include/gdnative/gdnative.h:281:111: warning: 'sysv_abi' attribute directive ignored [-Wattributes] 281 | void GDAPI godot_print_error(const char p_description, const char p_function, const char p_file, int p_line); | ^ modules/gdnative/include/gdnative/gdnative.h:282:113: warning: 'sysv_abi' attribute directive ignored [-Wattributes] 282 | void GDAPI godot_print_warning(const char p_description, const char p_function, const char p_file, int p_line); | ^ modules/gdnative/include/gdnative/gdnative.h:283:53: warning: 'sysv_abi' attribute directive ignored [-Wattributes] 283 | void GDAPI godot_print(const godot_string p_message); | ^ modules/gdnative/include/gdnative/gdnative.h:287:64: warning: 'sysv_abi' attribute directive ignored [-Wattributes] 287 | bool GDAPI godot_is_instance_valid(const godot_object p_object); | ^ modules/gdnative/include/gdnative/gdnative.h:290:65: warning: 'sysv_abi' attribute directive ignored [-Wattributes] 290 | void GDAPI godot_get_class_tag(const godot_string_name p_class);

"

Minimal reproduction project:

Calinou commented 4 years ago

Actual results:

  1. The compile time is taking too long. By the time I open this bug it still compiling and it like this for over 1.5 hr already.

Godot (especially with the editor) is a complex C++ codebase, spanning over 1 million lines of SLOC when including third-party dependencies (which will also be compiled). I don't think much can be done about it :slightly_smiling_face:

ikostan commented 4 years ago

I'll close this one. I think that there was something wrong with 'scons' command and I can't reproduce it anymore. I have one more issue here. So you can look at it for the reference.

akien-mga commented 10 months ago

This is actually still reproducible in latest 3.x.

akien-mga commented 10 months ago

Fixed by #85916.