automake
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: How to handle data/script files in a VPATH build ?


From: Sylvestre Ledru
Subject: Re: How to handle data/script files in a VPATH build ?
Date: Tue, 09 Feb 2010 19:00:51 +0100

Hello Ralf,

As usual, thanks for your answer.

Le samedi 06 février 2010 à 18:56 +0100, Ralf Wildenhues a écrit : 
> Hello Sylvestre,
> 
> * Sylvestre Ledru wrote on Sat, Feb 06, 2010 at 06:49:38PM CET:
> > Le mercredi 03 février 2010 à 11:27 -0500, Peter Johansson a écrit :
> > > > I cannot change top_builddir by top_srcdir since I need both the data
> > > > and script to be available in the build tree.
> > > 
> > > Are myscript and myData.sci distributed or built? 
> > > Why do you need them in the build tree?
> > Both, I need them at building time: myscript calls the binaries to
> > transform the myData.sci to myData.bin.
> > And they are both needed for my application at runtime.
> 
> Can you let your script use $srcdir/myData.sci instead of myData.sci?
I wish but I can't, I need them within the builddir.


> Typically, there are two ways to get out of the VPATH problem: either
> prefix all paths in your tools with the right ones, (this can usually be
> done more elegantly if the tool has some -I<dir> flag to amend its search
> path, like a preprocessor), or copy all files to the build tree
> somewhere.  If you decide to do the latter, then please use a different
> name from the file name in the source tree (or a different relative
> directory), so that `make' rebuilding rules will not be messed up later
> by looking at the copied file.
> 
> E.g.:
> 
> data-in-build-tree: data-in-source-tree
>         cp $(srcdir)/data-in-source-tree data-in-build-tree
Hmm, I have more than 7000 data files and their names are relevant :/
(Like in java with the name of the object which matches the filename)

It is going to be tricky to handle on such number of files ...

Sylvestre








reply via email to

[Prev in Thread] Current Thread [Next in Thread]