@all
I have found a very strange linking error.
I did a test today and tried to compile ScummVM with -Os instead of -O3 and while the static version builds fine and produce a working exe, the shared version error in linking state with thousands (probably one for every source file) undefined references, like so
audio/softsynth/mt32/libmt32.a(SampleRateConverter.o): In function `MT32Emu::SampleRateConverter::getBestAnalogOutputMode(double)':
SampleRateConverter.cpp:(.text+0x90): undefined reference to `_restfpr_30_x'
audio/softsynth/mt32/libmt32.a(SampleRateConverter.o): In function `MT32Emu::SampleRateConverter::SampleRateConverter(MT32Emu::Synth&, double, MT32Emu::SamplerateConversionQuality)':
SampleRateConverter.cpp:(.text+0x160): undefined reference to `_restfpr_31_x'
audio/softsynth/mt32/libmt32.a(SampleRateConverter.o): In function `MT32Emu::SampleRateConverter::getOutputSamples(short*, unsigned int)':
SampleRateConverter.cpp:(.text+0x2f8): undefined reference to `_restgpr_24_x'
gmake: *** [scummvm] Error 1
I dug a little on the net and found something mentioned from the gcc devs (but it was fixed in
2009 and the rest of the discussion went flying over my head),
Any hints?
Not that it really matters, i probably won't use -Os anyway since the save on binary size is a few tenthousand bytes on a 18 MB binary.
Just want to make sure there isn't something broken in our gcc.
@capehill
One more thing...you mentioned that using MAXPATHLEN might be suboptimal due to the path growing too big for the buffer.
Do you have a more robust solution?
btw: Thank you for still caring for my noob problems
Edited by Raziel on 2021/4/19 16:46:58