Linking errors because of multiple definitions

BlitzMax Forums/BlitzMax Programming/Linking errors because of multiple definitions

Htbaa(Posted 2012) [#1]
In using the TimelineFX module with rigz.zipstreamloader one of my machines has issues with linking. See error below:

C:\BlitzMax/mod/gman.mod/zipengine.mod/zipengine.debug.win32.x86.a(bmxsupport.c.debug.win32.x86.o):bmxsupport.c:(.text+0x7c): multiple definition of `unzGetCurrentFileSize'
C:\BlitzMax/mod/koriolis.mod/zipstream.mod/zipstream.debug.win32.x86.a(bmxsupport.c.debug.win32.x86.o):bmxsupport.c:(.text+0x0): first defined here
C:\BlitzMax/mod/gman.mod/zipengine.mod/zipengine.debug.win32.x86.a(bmxsupport.c.debug.win32.x86.o):bmxsupport.c:(.text+0xd1): multiple definition of `zipOpenNewFileWithPassword'
C:\BlitzMax/mod/koriolis.mod/zipstream.mod/zipstream.debug.win32.x86.a(bmxsupport.c.debug.win32.x86.o):bmxsupport.c:(.text+0x55): first defined here


I've tried the latest MinGW release, rebuilt all modules, rebuilt my project after cleaning it, but I still keep getting this error. BlitzMax is also at the latest version.

The strange thing is that this only happens on one of my machines, 2 others have no issues with this. Am I missing something?


xlsior(Posted 2012) [#2]
If you have duplicate definitions in the modules, then they can't co-exist... (temporarily) removing the gman and koriolis modules should allow you to recomppile the rigz module, after which it should be able to link properly.


Htbaa(Posted 2012) [#3]
I should clarify, I'm able to compile all the modules. I understand that duplicate definitions give these errors, but how come on 2 out of 3 systems I can compile my project just fine?

Since rigz.zipstreamloader is using koriolis.zipstream and rigz.timelinefx is using gman.zipengine I'll probably move this question up to Pete. But am interested in how come it does work fine on 2 other PC's.


xlsior(Posted 2012) [#4]
Different blitzmax or GCC version?


Htbaa(Posted 2012) [#5]
BlitzMax version is the same, GCC was different though. Changed that, but had no success so far.

Edit: ah, it seems my netbook has issues with it as well. I'm pretty sure that once I do a full rebuild on my desktop that it won't work on it anymore as well. Weird how it did work at first...

Last edited 2012