muttleyxd / arma3-unix-launcher

Launcher for Linux and Mac ArmA 3
MIT License
210 stars 43 forks source link

Error in compilation with gcc 13 #249

Closed memchr closed 1 year ago

memchr commented 1 year ago

Compiling the latest git source with GCC 13 results in the following error.

/home/builder/.cache/paru/clone/arma3-linux-launcher-git/src/arma3-linux-launcher-git/src/steam-integration/steam_integration_stub.cpp:33:68: error: return type ‘std::string’ {aka ‘class std::__cxx11::basic_string<char>’} is incomplete
   33 |     std::string IntegrationStub::get_item_title(std::uint64_t const)
      |                                                                    ^
make[2]: *** [src/steam-integration/CMakeFiles/steam-integration.dir/build.make:90: src/steam-integration/CMakeFiles/steam-integration.dir/steam_integration_stub.cpp.o] Error 1
make[2]: *** Waiting for unfinished jobs....
In file included from /home/builder/.cache/paru/clone/arma3-linux-launcher-git/src/arma3-linux-launcher-git/src/steam-integration/steam_integration_impl.cpp:1:
/home/builder/.cache/paru/clone/arma3-linux-launcher-git/src/arma3-linux-launcher-git/src/steam-integration/steam_integration_impl.hpp:35:25: error: field ‘app_id’ has incomplete type ‘std::string’ {aka ‘std::__cxx11::basic_string<char>’}
   35 |             std::string app_id;
      |                         ^~~~~~
In file included from /usr/include/c++/13.1.1/iosfwd:41,
                 from /usr/include/c++/13.1.1/bits/shared_ptr.h:52,
                 from /usr/include/c++/13.1.1/memory:80,
                 from /home/builder/.cache/paru/clone/arma3-linux-launcher-git/src/arma3-linux-launcher-git/src/steam-integration/steam_integration_stub.hpp:6,
                 from /home/builder/.cache/paru/clone/arma3-linux-launcher-git/src/arma3-linux-launcher-git/src/steam-integration/steam_integration_impl.hpp:3:
/usr/include/c++/13.1.1/bits/stringfwd.h:72:11: note: declaration of ‘std::string’ {aka ‘class std::__cxx11::basic_string<char>’}
   72 |     class basic_string;
      |           ^~~~~~~~~~~~
/home/builder/.cache/paru/clone/arma3-linux-launcher-git/src/arma3-linux-launcher-git/src/steam-integration/steam_integration_impl.cpp:48:10: warning: ‘bool {anonymous}::initialize_steam_api(const std::string&)’ defined but not used [-Wunused-function]
   48 |     bool initialize_steam_api(std::string const &app_id)
      |          ^~~~~~~~~~~~~~~~~~~~
make[2]: *** [src/steam-integration/CMakeFiles/steam-integration.dir/build.make:76: src/steam-integration/CMakeFiles/steam-integration.dir/steam_integration_impl.cpp.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:316: src/steam-integration/CMakeFiles/steam-integration.dir/all] Error 2
make: *** [Makefile:136: all] Error 2

environment

OS: Arch Linux
ARCH: x86_64
GCC: gcc version 13.1.1 20230429