[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

extra flags for linker on GNU

From: Robert Millan
Subject: extra flags for linker on GNU
Date: Tue, 22 Apr 2003 13:09:11 +0200
User-agent: Mutt/1.5.4i


I've been observating that linking objects against a library on
GNU requires more linker flags than on other platforms. the
extra flags correspond to the dependencies of the library you're
linking against, and so recursively.

so, for example, supose we have library "libfoo" and program "bar".
libfoo is written in C++ and depends on libstdc++, but bar is
pure C and doesn't need libstdc++ directly.

well, on GNU/Linux linking bar against libfoo won't need -lstdc++,
but this flag is a must on GNU. is that the expected behaviour?

you can see examples in lots of places, like in
xfree86/programs/glxinfo C++ linking mess, or debian bug 186760 [1]

are we suposed to add the extra flags or is there a bug that needs


Robert Millan

make: *** No rule to make target `war'.  Stop.

Another world is possible - Just say no to genocide

reply via email to

[Prev in Thread] Current Thread [Next in Thread]