/usr/bin/ld: ./mupen64plus-core/src/dd/dd_disk.o:(.bss+0xc): multiple definition of CUR_BLOCK'; ./mupen64plus-core/src/dd/dd_controller.o:(.bss+0x8): first defined here /usr/bin/ld: ./mupen64plus-core/src/dd/dd_disk.o:(.bss+0x10): multiple definition ofdd_bm_mode_read'; ./mupen64plus-core/src/dd/dd_controller.o:(.bss+0xc): first defined here
/usr/bin/ld: ./mupen64plus-core/src/plugin/emulate_game_controller_via_libretro.o:(.bss+0x24): multiple definition of alternate_mapping'; ./libretro/libretro.o:(.bss+0x3c): first defined here /usr/bin/ld: ./gles2n64/src/N64.o:(.bss+0x1008): multiple definition ofDMEM'; ./mupen64plus-rsp-cxd4/rsp.o:(.bss+0x154): first defined here
/usr/bin/ld: ./glide2gl/src/Glide64/Framebuffer_glide64.o:(.bss+0x50): multiple definition of _gSPVertex'; ./glide2gl/src/Glide64/glide64_3dmath.o:(.bss+0x0): first defined here /usr/bin/ld: ./glide2gl/src/Glide64/Glide64_Ini.o:(.bss+0x0): multiple definition of_gSPVertex'; ./glide2gl/src/Glide64/glide64_3dmath.o:(.bss+0x0): first defined here
/usr/bin/ld: ./glide2gl/src/Glide64/glidemain.o:(.bss+0x116c): multiple definition of _gSPVertex'; ./glide2gl/src/Glide64/glide64_3dmath.o:(.bss+0x0): first defined here /usr/bin/ld: ./glide2gl/src/Glide64/glide64_util.o:(.bss+0x8): multiple definition of_gSPVertex'; ./glide2gl/src/Glide64/glide64_3dmath.o:(.bss+0x0): first defined here
/usr/bin/ld: ./glide2gl/src/Glide64/Glide64_UCode.o:(.bss+0x0): multiple definition of _gSPVertex'; ./glide2gl/src/Glide64/glide64_3dmath.o:(.bss+0x0): first defined here /usr/bin/ld: ./glide2gl/src/Glide64/glide64_gSP.o:(.bss+0x4): multiple definition of_gSPVertex'; ./glide2gl/src/Glide64/glide64_3dmath.o:(.bss+0x0): first defined here
/usr/bin/ld: ./glide2gl/src/Glide64/glide64_gDP.o:(.bss+0x0): multiple definition of _gSPVertex'; ./glide2gl/src/Glide64/glide64_3dmath.o:(.bss+0x0): first defined here /usr/bin/ld: ./glide2gl/src/Glide64/Combine.o:(.bss+0x998): multiple definition of_gSPVertex'; ./glide2gl/src/Glide64/glide64_3dmath.o:(.bss+0x0): first defined here
/usr/bin/ld: ./glide2gl/src/Glide64/TexCache.o:(.bss+0x204007c): multiple definition of _gSPVertex'; ./glide2gl/src/Glide64/glide64_3dmath.o:(.bss+0x0): first defined here /usr/bin/ld: ./glide2gl/src/Glide64/TexLoad.o:(.bss+0x0): multiple definition of_gSPVertex'; ./glide2gl/src/Glide64/glide64_3dmath.o:(.bss+0x0): first defined here
/usr/bin/ld: ./glide2gl/src/Glide64/glide64_rdp.o:(.bss+0x1048): multiple definition of _gSPVertex'; ./glide2gl/src/Glide64/glide64_3dmath.o:(.bss+0x0): first defined here /usr/bin/ld: ./glide2gl/src/Glitch64/geometry.o:(.bss+0xea74): multiple definition of_gSPVertex'; ./glide2gl/src/Glide64/glide64_3dmath.o:(.bss+0x0): first defined here
/usr/bin/ld: ./glide2gl/src/Glitch64/glitchmain.o:(.bss+0x54): multiple definition of `_gSPVertex'; ./glide2gl/src/Glide64/glide64_3dmath.o:(.bss+0x0): first defined here
collect2: fout: ld gaf exit-status 1 terug
Tested on Fedora 32 built with GCC 10 on XU4 running great.
LTO seems to be unstable still so I disabled it by default as you can see in the description and commit.
Present optional HAVE_LTCG parameter to enable LTO (disabled by default as untested)
Make it possible to speciy odroid "BOARD" variable on cmdline since mainline kernel doesn't provide it in /proc/cpuinfo
"ODROID-XU" will match both XU3, XU4 and XU3-Lite
Target the cortex-a15 cpu on odroid xu3/4 instead of the armv7ve architecture
Remove pre-4.9 checks since they fail when GCC version is 10
Pass CPUFLAGS to the assembler and linker as well, this fixes native compilation when the linux ditribution uses different defaults for compiler flags
No need to specify $(PLATCFLAGS) twice
Workaround for building with GCC 10 requiring "-fcommon"
TODO - The GCC 10 workaround needs a real fix, see: https://wiki.gentoo.org/wiki/Gcc_10_porting_notes/fno_common
Without -fcommon the build will fail with:
/usr/bin/ld: ./mupen64plus-core/src/dd/dd_disk.o:(.bss+0xc): multiple definition of
CUR_BLOCK'; ./mupen64plus-core/src/dd/dd_controller.o:(.bss+0x8): first defined here /usr/bin/ld: ./mupen64plus-core/src/dd/dd_disk.o:(.bss+0x10): multiple definition of
dd_bm_mode_read'; ./mupen64plus-core/src/dd/dd_controller.o:(.bss+0xc): first defined here /usr/bin/ld: ./mupen64plus-core/src/plugin/emulate_game_controller_via_libretro.o:(.bss+0x24): multiple definition ofalternate_mapping'; ./libretro/libretro.o:(.bss+0x3c): first defined here /usr/bin/ld: ./gles2n64/src/N64.o:(.bss+0x1008): multiple definition of
DMEM'; ./mupen64plus-rsp-cxd4/rsp.o:(.bss+0x154): first defined here /usr/bin/ld: ./glide2gl/src/Glide64/Framebuffer_glide64.o:(.bss+0x50): multiple definition of_gSPVertex'; ./glide2gl/src/Glide64/glide64_3dmath.o:(.bss+0x0): first defined here /usr/bin/ld: ./glide2gl/src/Glide64/Glide64_Ini.o:(.bss+0x0): multiple definition of
_gSPVertex'; ./glide2gl/src/Glide64/glide64_3dmath.o:(.bss+0x0): first defined here /usr/bin/ld: ./glide2gl/src/Glide64/glidemain.o:(.bss+0x116c): multiple definition of_gSPVertex'; ./glide2gl/src/Glide64/glide64_3dmath.o:(.bss+0x0): first defined here /usr/bin/ld: ./glide2gl/src/Glide64/glide64_util.o:(.bss+0x8): multiple definition of
_gSPVertex'; ./glide2gl/src/Glide64/glide64_3dmath.o:(.bss+0x0): first defined here /usr/bin/ld: ./glide2gl/src/Glide64/Glide64_UCode.o:(.bss+0x0): multiple definition of_gSPVertex'; ./glide2gl/src/Glide64/glide64_3dmath.o:(.bss+0x0): first defined here /usr/bin/ld: ./glide2gl/src/Glide64/glide64_gSP.o:(.bss+0x4): multiple definition of
_gSPVertex'; ./glide2gl/src/Glide64/glide64_3dmath.o:(.bss+0x0): first defined here /usr/bin/ld: ./glide2gl/src/Glide64/glide64_gDP.o:(.bss+0x0): multiple definition of_gSPVertex'; ./glide2gl/src/Glide64/glide64_3dmath.o:(.bss+0x0): first defined here /usr/bin/ld: ./glide2gl/src/Glide64/Combine.o:(.bss+0x998): multiple definition of
_gSPVertex'; ./glide2gl/src/Glide64/glide64_3dmath.o:(.bss+0x0): first defined here /usr/bin/ld: ./glide2gl/src/Glide64/TexCache.o:(.bss+0x204007c): multiple definition of_gSPVertex'; ./glide2gl/src/Glide64/glide64_3dmath.o:(.bss+0x0): first defined here /usr/bin/ld: ./glide2gl/src/Glide64/TexLoad.o:(.bss+0x0): multiple definition of
_gSPVertex'; ./glide2gl/src/Glide64/glide64_3dmath.o:(.bss+0x0): first defined here /usr/bin/ld: ./glide2gl/src/Glide64/glide64_rdp.o:(.bss+0x1048): multiple definition of_gSPVertex'; ./glide2gl/src/Glide64/glide64_3dmath.o:(.bss+0x0): first defined here /usr/bin/ld: ./glide2gl/src/Glitch64/geometry.o:(.bss+0xea74): multiple definition of
_gSPVertex'; ./glide2gl/src/Glide64/glide64_3dmath.o:(.bss+0x0): first defined here /usr/bin/ld: ./glide2gl/src/Glitch64/glitchmain.o:(.bss+0x54): multiple definition of `_gSPVertex'; ./glide2gl/src/Glide64/glide64_3dmath.o:(.bss+0x0): first defined here collect2: fout: ld gaf exit-status 1 terug