Boost logo

Boost-Build :

From: Vladimir Prus (ghost_at_[hidden])
Date: 2007-04-03 02:56:10


On Tuesday 03 April 2007 10:17, Dave Rahardja wrote:
> How come path.glob works from the path of the Jamfile that is used from the
> command line, instead of from the path of the Jamfile it is in?

Because path.glob works from the current directory, which is the directory
where you invoke bjam. That's reasonable, because path.glob is low-level
feature.

You can use 'glob' rule (unqualified), in Jamfile context, to glob
relatively to Jamfile. Please see:

        http://boost.org/boost-build2/doc/html/bbv2/reference/rules.html

> import path : glob ;

Just remove this line....

>
> local SOURCE_DIR = source ;
> local SOURCES = [ glob SOURCE_DIR : *.c *.cpp ] ;

and use

        [ glob *.c *cpp ]

- Volodya


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