Boost logo

Boost-Build :

Subject: Re: [Boost-build] hierarchical install ?
From: Avi Bahra (avibahra_at_[hidden])
Date: 2009-09-01 04:14:06


> I have a directory hierarchy. In some of my sub directories I have exe
> that i want to install. In the jam file I have:
>
> install install : client : <location>$SMS_INSTALL_DIR ;
> explicit install ;
>
> So if I am in that directory I do:
> bjam install
>
> hey presto, everything works.
>
> However I now want to do the same thing at the top level.
> If I do bjam install at the top level, i get:
>
> notice: could not find main target install
> notice: assuming it is a name of file to create.
> don't know how to make <e>install
> ...found 1 target...
> ...can't find 1 target...
>
> Is there an easy way to get bjam to install hierarchically ?
>

Steve wrote:

>Each Jamfile needs to list the subprojects to install.
>
>alias install : subdirectory1//install subdirectory2//install ;
>explicit install ;

Ok, it did not fail, but it *does not work* as expected.
Running bjam install , now installs relative to subdirectory1/
In my case I have added,

alias install : Server//install Client//install ;
explicit install ;

To my JamRoot.jam file, since I have the following in my Server and Client
sub directories:

install install : server : <location>$SMS_INSTALL_DIR ;
explicit install ;

However when I run bjam install from my root directory; i get:

 bjam -d2 install
...patience...
...patience...
...found 6768 targets...
...updating 4 targets...
common.mkdir Server/$SMS_INSTALL_DIR

        mkdir -p "Server/$SMS_INSTALL_DIR"

gcc.link Server/$SMS_INSTALL_DIR/server

    "g++" -o "Server/$SMS_INSTALL_DIR/server" -Wl,--start-group .......

common.mkdir Client/$SMS_INSTALL_DIR

        mkdir -p "Client/$SMS_INSTALL_DIR"

gcc.link Client/$SMS_INSTALL_DIR/client

    "g++" -o "Client/$SMS_INSTALL_DIR/client" -Wl,--start-group ......

It seems to ignore ignore the <location> and installs relative to the sub
directories Server/Client, and not at the
absolute location defined by the environment $SMS_INSTALL_DIR

  Best regards,
Ta,
   Avi



Boost-Build list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk