User forums > Using Code::Blocks

LIB files HowTo

<< < (2/2)

russellman:
Russellman hear.

Hears how it worked. I added #pragma comment(lib,"libwinmm.a")

and removed the link libraries in the project's linker options (on the left side of that dialog).

and it works.

In Borland you only link libraries in the project's linker options. If thay did not come with the compiler. One you made or 3ed party.

Gary thinks.

thomas:

--- Quote ---Not sure exactly what you mean by this
--- End quote ---
What I mean is that this is a non-standard functionality which is a regular source of problems for MS users trying to move to anything else that is not MS. Users are being taught to do something which is not only obscure and error prone, but which effectively prevents them from using another system. I remember at least a dozen people complaining about this very problem in the past.
The point is not whether it accidentially works with one compiler or the other, the point is that it is wrong and evil.


--- Quote ---Hears how it worked. I added #pragma comment(lib,"libwinmm.a")
and removed the link libraries in the project's linker options (on the left side of that dialog).
--- End quote ---
You should do the opposite, even if it appears to work that way. You should specify link libraries in the project options and not in a #pragma.

TDragon:

--- Quote from: thomas on March 29, 2006, 09:17:06 am ---The point is not whether it accidentially works with one compiler or the other, the point is that it is wrong and evil.

--- End quote ---
True dat. I apologize for nitpicking. :)

Navigation

[0] Message Index

[*] Previous page

Go to full version