News:

When registered with our forums, feel free to send a "here I am" post here to differ human beings from SPAM bots.

Main Menu

Relative path to libraries does not link [SOLVED]

Started by Edis Krad, August 01, 2006, 08:49:51 AM

Previous topic - Next topic

kingfox

Quote from: mandrav on October 24, 2006, 03:50:15 PM
QuoteMay I think these two options can add the project's top directory and current compiled file's path into compiler and link path automatically ?

Adds the dirs to the compiler's search paths, not the linker's. Does it make sense to add them to the linker's too?

Yes, I think it's useful for me. But no matter even if it doesn't add them to the linker's. May be I didn't express my idea clearly. Actually, I want to know if I don't specify the path to every item (these items are in current project's directory) in "link libraires" listbox, where will C::B look up this item? In others word, where will C::B think these no-path-specified item should be?

When I add the ".\", the command line will be "mingw32-g++.exe -L..\gccdll -LD:\CodeBlocks\lib  -o .\usedll.exe obj\Debug\main.o    .\gccdll.a" (gccdll.a is the item in the "link libraries" listbox and this file is in current project's directory). And when I remove the ".\" of the items in "link libraries" list, the command line will be "mingw32-g++.exe -L..\gccdll -LD:\CodeBlocks\lib  -o .\usedll.exe obj\Debug\main.o  -lgccdll.a". Why C::B add a "-l" before "gccdll.a" ?