Code::Blocks Forums

User forums => Using Code::Blocks => Topic started by: G-Shadow on October 05, 2014, 04:50:51 pm

Title: Platform-depended libraries set
Post by: G-Shadow on October 05, 2014, 04:50:51 pm
Hi.
I have a cross-platform project that should build under Linux and Windows.
I have Debug and Release targets now and planning add one or two more.
All options are the same for both Lin/Win platforms with exception of linked libraries list.
Is there are any way to make libraries link platform-depended to prevent creating Debug-Win, Debug-Lin, Releas-Win, Release-Lin targets (and maintaining its future changes)?
Thanks!
Title: Re: Platform-depended libraries set
Post by: stahta01 on October 05, 2014, 08:25:51 pm
Might see if scripting will do this. I have no idea if it will or will not do it.

Anyone know, if CB scripting can test for Operating System?

If not, I think it is a good feature to add.

Tim S.

Title: Re: Platform-depended libraries set
Post by: oBFusCATed on October 05, 2014, 08:45:57 pm
Yes it can but it will look a bit ugly.

Generally it depends on the differences between the options you're trying to pass.
Title: Re: Platform-depended libraries set
Post by: G-Shadow on October 06, 2014, 06:04:48 pm
I had found this solution (http://forums.codeblocks.org/index.php/topic,8643.msg63221.html#msg63221) with scripting before creating this post.
But I hope some new features appears since 2008 year.
Title: Re: Platform-depended libraries set
Post by: stahta01 on October 06, 2014, 06:45:56 pm
I had found this solution (http://forums.codeblocks.org/index.php/topic,8643.msg63221.html#msg63221) with scripting before creating this post.
But I hope some new features appears since 2008 year.

That looks ugly; I think I would make a OS script/batch file that returns the values needed like wx-config does for wxWidgets.

Note: That will be more work in the beginning; but, I think it might pay off if used often enough.

Edit: I have never used a Project Script; maybe it would hide some of the looks.

Tim S.