Nested projects

View: New views
3 Messages — Rating Filter:   Alert me  

Nested projects

by Brian Ravnsgaard Riis :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hi,

Is it currently possible to nest a complete, seperately compilable
project inside a boost.build project. Say I have a library, foo, that
can be seperately compiled using boost.build. I use a "externals"
facility to get a given revision of foo into a nested externals or
vendor folder under a project that uses foo.

<~/dev/bar>
   + jamroot.jam
   + src
   |  + jamfile.jam
   |  + *.cpp
   |  - *.hpp
   - externals
      - foo
         + jamroot.jam
         - src
            + jamfile.jam
            + *.cpp
            - *.hpp

How would you do this with Boost.Build? I tried the naïve approach and
get bitten by an error along the lines of "warning: rulename
$($(project).attributes).get expands to empty string".

Ideas?

 /Brian
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.12 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAkquk+IACgkQk1tAOprY6QFCmgCdENWmUntkfwVc6xKW7G9FvPCz
LMMAnRSbOOwXCb3ORhItLjPiUSB7D4V/
=I/a+
-----END PGP SIGNATURE-----
_______________________________________________
Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost-build

Re: Nested projects

by Johan Nilsson-4 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Brian Ravnsgaard Riis wrote:

> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> Hi,
>
> Is it currently possible to nest a complete, seperately compilable
> project inside a boost.build project. Say I have a library, foo, that
> can be seperately compiled using boost.build. I use a "externals"
> facility to get a given revision of foo into a nested externals or
> vendor folder under a project that uses foo.
>
> <~/dev/bar>
>    + jamroot.jam
>    + src
>    |  + jamfile.jam
>    |  + *.cpp
>    |  - *.hpp
>    - externals
>       - foo
>          + jamroot.jam
>          - src
>             + jamfile.jam
>             + *.cpp
>             - *.hpp
>
> How would you do this with Boost.Build? I tried the naïve approach and
> get bitten by an error along the lines of "warning: rulename
> $($(project).attributes).get expands to empty string".

I'm not really sure what the "naive" approach boils down to, but did you try
e.g.:

-- dev/bar/externals/foo/jamroot.jam --

...
use-project src : src ;

-- dev/bar/jamroot.jam --

...
use-project /foo : externals/foo ;
alias foo-src : /foo//src ;

[caveat: not tested]

HTH / Johan


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

Re: Nested projects

by Brian Ravnsgaard Riis :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Johan Nilsson skrev:

> I'm not really sure what the "naive" approach boils down to, but did you
> try e.g.:
>
> -- dev/bar/externals/foo/jamroot.jam --
>
> ...
> use-project src : src ;
>
> -- dev/bar/jamroot.jam --
>
> ...
> use-project /foo : externals/foo ;
> alias foo-src : /foo//src ;
>
> [caveat: not tested]

My problem turned out to be a case of name clashes. So in the end, I
guess, this cleanup of the jamfiles turned out to be a good thing. I got
my setup working now, using a variation of your approach above. Thanks a
lot!

 /Brian

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.12 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAkqwtpkACgkQk1tAOprY6QH5xACgld2ezrGTIDgOGNu53L3+AsK4
b2IAoMOERcCJPdlTSxJhd7Ka6wRqwFqn
=MH8N
-----END PGP SIGNATURE-----
_______________________________________________
Unsubscribe & other changes: http://lists.boost.org/mailman/listinfo.cgi/boost-build