libretro / mupen64plus-libretro-nx

Improved mupen64plus libretro core reimplementation
GNU General Public License v2.0
212 stars 108 forks source link

GCC 13 build failure #515

Open fmahnke opened 5 months ago

fmahnke commented 5 months ago

The build fails under GCC 13 because of missing <cstdint> . Adding -include cstdint to command line options allows the files to compile.

g++  -DHAVE_THR_AL -DGRANITE_VULKAN_MT -DHAVE_PARALLEL_RDP -I./mupen64plus-rsp-paraLLEl/arch/simd/rsp -I./mupen64plus-rsp-paraLLEl/lightning/include -DHAVE_PARALLEL_RSP -DPARALLEL_INTEGRATION -fvisibility-inlines-hidden -std=gnu++11 -D_CRT_SECURE_NO_WARNINGS -O3 -DNDEBUG -fsigned-char -ffast-math -fno-strict-aliasing -fomit-frame-pointer -fvisibility=hidden -fcommon -DOS_LINUX -I./mupen64plus-core/subprojects/md5 -DARCH_MIN_SSE2 -msse -msse2 -DHAVE_LLE -D__STDC_CONSTANT_MACROS -D__STDC_LIMIT_MACROS -D__LIBRETRO__ -DUSE_FILE32API -DM64P_PLUGIN_API -DM64P_CORE_PROTOTYPES -D_ENDUSER_RELEASE -DSINC_LOWER_QUALITY -DTXFILTER_LIB -D__VEC4_OPT -DMUPENPLUSAPI -I./custom -I./custom/mupen64plus-core -I./custom/android/include -I./custom/GLideN64 -I./GLideN64/src -I./GLideN64/src/osal -I./mupen64plus-core/src -I./mupen64plus-core/src/api -I./custom/mupen64plus-core/plugin/audio_libretro -I./libretro-common/include -I./libretro -I./GLideN64/src/inc -I./custom/dependencies/libpng -I./mupen64plus-core/subprojects/minizip -I./xxHash -I./custom/dependencies/libzlib -I./mupen64plus-video-paraLLEl/parallel-rdp/parallel-rdp -I./mupen64plus-video-paraLLEl/parallel-rdp/volk -I./mupen64plus-video-paraLLEl/parallel-rdp/vulkan -I./mupen64plus-video-paraLLEl/parallel-rdp/vulkan-headers/include -I./mupen64plus-video-paraLLEl/parallel-rdp/util  -fPIC  -DCORE -DHAVE_OPENGL -DNEW_DYNAREC=2 -DDYNAREC -I./mupen64plus-core/src/asm_defines/ -c mupen64plus-rsp-paraLLEl/rsp_disasm.cpp -o mupen64plus-rsp-paraLLEl/rsp_disasm.o
In file included from mupen64plus-rsp-paraLLEl/rsp_disasm.cpp:1:
mupen64plus-rsp-paraLLEl/rsp_disasm.hpp:8:25: error: 'uint32_t' was not declared in this scope
    8 | std::string disassemble(uint32_t pc, uint32_t instr);
      |                         ^~~~~~~~
mupen64plus-rsp-paraLLEl/rsp_disasm.hpp:5:1: note: 'uint32_t' is defined in header '<cstdint>'; did you forget to '#include <cstdint>'?
    4 | #include <string>
  +++ |+#include <cstdint>
    5 |
mupen64plus-rsp-paraLLEl/rsp_disasm.hpp:8:38: error: 'uint32_t' was not declared in this scope
    8 | std::string disassemble(uint32_t pc, uint32_t instr);
      |                                      ^~~~~~~~
mupen64plus-rsp-paraLLEl/rsp_disasm.hpp:8:38: note: 'uint32_t' is defined in header '<cstdint>'; did you forget to '#include <cstdint>'?
mupen64plus-rsp-paraLLEl/rsp_disasm.cpp:30:13: error: redefinition of 'std::string RSP::disassemble'
   30 | std::string disassemble(uint32_t pc, uint32_t instr)
      |             ^~~~~~~~~~~
mupen64plus-rsp-paraLLEl/rsp_disasm.hpp:8:13: note: 'std::string RSP::disassemble' previously declared here
    8 | std::string disassemble(uint32_t pc, uint32_t instr);
      |             ^~~~~~~~~~~
mupen64plus-rsp-paraLLEl/rsp_disasm.cpp:30:25: error: 'uint32_t' was not declared in this scope
   30 | std::string disassemble(uint32_t pc, uint32_t instr)
      |                         ^~~~~~~~
mupen64plus-rsp-paraLLEl/rsp_disasm.cpp:3:1: note: 'uint32_t' is defined in header '<cstdint>'; did you forget to '#include <cstdint>'?
    2 | #include <assert.h>
  +++ |+#include <cstdint>
    3 |
mupen64plus-rsp-paraLLEl/rsp_disasm.cpp:30:38: error: 'uint32_t' was not declared in this scope
   30 | std::string disassemble(uint32_t pc, uint32_t instr)
      |                                      ^~~~~~~~
mupen64plus-rsp-paraLLEl/rsp_disasm.cpp:30:38: note: 'uint32_t' is defined in header '<cstdint>'; did you forget to '#include <cstdint>'?
fmahnke commented 5 months ago

https://github.com/fmahnke/mupen64plus-libretro-nx/commit/34da02d820ec73637e9adbf63711af670eceafdc resolves the build error in the configuration used by nixpkgs.

m4xw commented 3 months ago

dont think its needed anymore