make sure that the same compiler flags are used too
Good point - I now recall being tripped up by different optimization levels in the past.
However, I think the OP has probably already followed that advice by having built the executable with:
gcc -s -O2 -DWIN32 -fwrapv -fno-strict-aliasing -mms-bitfields -o fite
+st.exe fitest.c -lfreeimage
Maybe there's some other pertinent option that has been omitted. We can't tell unless we see the output of
perl -V:ccflags
There must be a Makefile somewhere created by Inline::C
Also a good point - it's usually under the ./_Inline/build directory, but you'll need to configure the Inline::C script with
CLEAN_AFTER_BUILD => 0 to prevent the Makefile being automatically deleted when the compilation successfully completes.
Cheers,
Rob