User forums > Using Code::Blocks

Project to build BOTH shared and static library

(1/1)

StormByte:
Hi there, I have several C::B projects which are shared libraries, but I wanted to know if there are some way to have only one project which could build up the two versions: shared and static libraries in same project.
I know it may force C::B to recompile because of -shared option which it passes to gcc to make static one, but it could be usefull sometimes.

Is there any way to do this, or do I have to have 2 different projects for any library?

Thanks

Jenna:
It should work, if you create two targets, one for shared and one for static and a virtual target that includes both of them.

You can copy, modify and create virtual targets in "Project -> Properties".

StormByte:
THank you! I've never looked at virtual targets, it worked :)

Navigation

[0] Message Index

Go to full version