[Box Backup-dev] make clean

Ben Summers boxbackup-dev@fluffy.co.uk
Sat, 11 Feb 2006 08:52:33 +0000


On 11 Feb 2006, at 00:54, Martin Ebourne wrote:

> On Fri, 2006-02-03 at 09:45 +0000, Ben Summers wrote:
>> I never use make in the top level while developing. If you make in a
>> test/* directory, it all works as you need. make in the top level is
>> really just for people compiling it ready to actually use.
>
> Yes the build system is rather unusual and takes a while to get  
> used to.
> I now work the way Ben does because it's easier than fighting it,  
> and it
> does work that way. (Although the dependencies still aren't 100%,  
> though
> I haven't ever attempted to track down the problem.)

Unusual? Maybe... Unfortunately other build systems didn't quite work  
the way I needed for some other stuff I was doing.

>
> I would like to be able to build and rebuild with dependencies from  
> the
> top level though, it's one of the things I'd like to fix one day. Also
> I'd prefer the release/debug split to be a flag or target passed to
> make, rather than depending on the directory you are in.

Are you sure? In one of the test/* (or bin/* or whatever), you pass a  
flag to make it build the release version.

With BSD make, do

   make -D RELEASE

and with GNU make do

   make RELEASE=1

Of course, the object files and executables are made within the  
release/ tree to keep them separate from the debug versions.

Ben