Silverfrost Forums

Welcome to our forums

Multiple Symbols

8 May 2017 1:18 #19589

Running a large program using Plato. When I do a build, the system responds with Multiple references to symbol _XXXXXX. I do not know where to look to eliminate the multiple references, I assume that they are in the built routine but how can I access or where would they be. I looked at all of the subroutines but there is no reference twice to the same routine? Sid Kraft

8 May 2017 5:51 #19590

Two possibilities: Could you be including a file twice in the build list ? Can you produce a load map xxx.map ? This will list the symbols and the file where they are located, although not sure if this happens for a duplicate.

John

8 May 2017 10:34 #19596

Quoted from stfark1 Running a large program using Plato. When I do a build, the system responds with Multiple references to symbol _XXXXXX.

Multiple references are never a problem, and are very common. You probably mean multiple definitions.

My preference is that, by default, the linker should not produce an EXE or DLL when when the input object files and libraries contain one or more instances of multiply defined or undefined symbols. In other words, there should be one and only one definition of each symbol.

It is also preferable if the linker does not place routines into the EXE that are never called. When building a DLL, of course, that preference does not apply.

As far as your build error is concerned, I suggest that you look at the linker command arguments in full. If that does not help, then you could generate and examine a map file.

Please login to reply.