Boost logo

Boost-Build :

From: eds_2 (eds_2_at_[hidden])
Date: 2005-10-25 13:45:38


I am new to both Jam and boost-jam, being eager to find a decent
make(1) replacement. However, I've run into a trivial problem with
boost.build and scanning headers.

I have a trivial project with the following Jamfile:

# Jamfile
exe test : test.c extra.c ;

This is the contents of test.c:

#include <stdio.h>
#include "extra.h"

int main() {
printf("myFunc(3) = %d\n", myFunc(3));
return 0;
}

This is extra.h:

#ifndef EXTRA_H
#define EXTRA_H

int myFunc(int x);

#endif

And this is extra.c:

#include "extra.h"

int myFunc(int x) {
return x + 2;
}

How do I enable automatic scanning of dependency checking. This
works as expected:

% touch test.c
% bjam
...found 9 targets...
...updating 2 targets...
gcc.compile.c bin/gcc/debug/test.o
gcc.link bin/gcc/debug/test
...updated 2 targets...

But when I touch extra.h (which should force a recompile of both
source files, nothing happens):

% touch extra.h
% bjam
...found 9 targets...

If I convert this to use plain jam (not bjam), it works. What am I
doing wrong in the bjam case?

Thanks,

-Eric

 


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