Different options for debug and release in a toolset jam file

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Different options for debug and release in a toolset jam file

Boost - Build mailing list
How do I tell Boost Build to use different compiler or linker options,
depending on whether the end-user is building some target in debug or
release mode, in a compiler toolset's jam file ? The compiler toolset I
am trying to create needs to specify, in particular, different library
directories to search depending on whether the end-user is building a
debug mode or release mode target. I know what those library directories
should be for either for debug mode or release mode, and I understand
how to pass the library directories as a variable to the compile or link
action, but I do not understand how I tell Boost Build that when the
action is building a target in release mode it should use the sequence
of library directories for release mode and when the action is building
a target in debug mode it should use the sequence of library directories
for debug mode. Something tells me I have to create different
conditions, one for release mode and one for debug mode, with the
appropriate library directories, but I am not sure how this is done. Any
help would be appreciated.

_______________________________________________
Unsubscribe & other changes: https://lists.boost.org/mailman/listinfo.cgi/boost-build
Reply | Threaded
Open this post in threaded view
|

Re: Different options for debug and release in a toolset jam file

Boost - Build mailing list
On Sat, Mar 7, 2020 at 3:29 AM Edward Diener via Boost-build <[hidden email]> wrote:
How do I tell Boost Build to use different compiler or linker options,
depending on whether the end-user is building some target in debug or
release mode, in a compiler toolset's jam file ? The compiler toolset I
am trying to create needs to specify, in particular, different library
directories to search depending on whether the end-user is building a
debug mode or release mode target. I know what those library directories
should be for either for debug mode or release mode, and I understand
how to pass the library directories as a variable to the compile or link
action, but I do not understand how I tell Boost Build that when the
action is building a target in release mode it should use the sequence
of library directories for release mode and when the action is building
a target in debug mode it should use the sequence of library directories
for debug mode. Something tells me I have to create different
conditions, one for release mode and one for debug mode, with the
appropriate library directories, but I am not sure how this is done. Any
help would be appreciated.

The usual way is to add "<variant>debug:<???>???" conditional properties to a target. But I suspect this is not exactly what you are looking for :-\

--
-- Rene Rivera
-- Grafik - Don't Assume Anything
-- Robot Dreams - http://robot-dreams.net


_______________________________________________
Unsubscribe & other changes: https://lists.boost.org/mailman/listinfo.cgi/boost-build
Reply | Threaded
Open this post in threaded view
|

Re: Different options for debug and release in a toolset jam file

Boost - Build mailing list
On 3/7/2020 7:56 AM, Rene Rivera via Boost-build wrote:

> On Sat, Mar 7, 2020 at 3:29 AM Edward Diener via Boost-build
> <[hidden email] <mailto:[hidden email]>> wrote:
>
>     How do I tell Boost Build to use different compiler or linker options,
>     depending on whether the end-user is building some target in debug or
>     release mode, in a compiler toolset's jam file ? The compiler toolset I
>     am trying to create needs to specify, in particular, different library
>     directories to search depending on whether the end-user is building a
>     debug mode or release mode target. I know what those library
>     directories
>     should be for either for debug mode or release mode, and I understand
>     how to pass the library directories as a variable to the compile or
>     link
>     action, but I do not understand how I tell Boost Build that when the
>     action is building a target in release mode it should use the sequence
>     of library directories for release mode and when the action is building
>     a target in debug mode it should use the sequence of library
>     directories
>     for debug mode. Something tells me I have to create different
>     conditions, one for release mode and one for debug mode, with the
>     appropriate library directories, but I am not sure how this is done.
>     Any
>     help would be appreciated.
>
>
> The usual way is to add "<variant>debug:<???>???" conditional properties
> to a target. But I suspect this is not exactly what you are looking for :-\

That is what I wanted. Thanks !

_______________________________________________
Unsubscribe & other changes: https://lists.boost.org/mailman/listinfo.cgi/boost-build