i'm using code::blocks and my every project, linking libraries like libole32 by right clicking project and properties, build options and linker, adding libraries everytime...

is there any way for me to add linked libraries this by a script, maybe makefile? i never used it before.

in visual c++, there is a directive

Code:
#pragma comment(lib,"d3d9.lib")
like this, easy to implement a class that automatically links required libraries, but i could not find an easy way by using code::blocks, this directive does not work.

thanks in advance, waiting replies.