Re: builddir vs. srcdir

2005-03-21 Thread Stepan Kasal
Hello, On Fri, Mar 18, 2005 at 09:34:15PM +0200, Paul Pogonyshev wrote: > Sorry, but I'll stick with my setup. My parser depends on my lowest- > level library (`libutils') and almost the whole build-tree depends on > the generated files. So, when I touched my `libutils' in any way, I > would get

Re: builddir vs. srcdir

2005-03-18 Thread Paul Pogonyshev
> Hello, > > On Sat, Mar 12, 2005 at 06:56:20PM +0200, Paul Pogonyshev wrote: > > Everything seems to work just fine and as expected, > > your code, which is in whole cited below, doesn't actually know > about the dependency > foo.c foo.h: foo.list > > So if you change the .list file, the other fi

Re: builddir vs. srcdir

2005-03-16 Thread Stepan Kasal
Hello, On Sat, Mar 12, 2005 at 06:56:20PM +0200, Paul Pogonyshev wrote: > Everything seems to work just fine and as expected, your code, which is in whole cited below, doesn't actually know about the dependency foo.c foo.h: foo.list So if you change the .list file, the other files won't be rebui

Re: builddir vs. srcdir

2005-03-12 Thread Paul Pogonyshev
Stepan Kasal wrote: > About the side topic of suffixes: > [...] I finally decided that suffixes are good and ``are worth it'', mostly because I use generated files in 4 different directories (with two files in one of them), so rewriting the rule 5 times is kinda nasty. Based on your suggestions, s

Re: builddir vs. srcdir

2005-03-11 Thread Stepan Kasal
Hello, On Thu, Mar 10, 2005 at 10:05:51PM +0200, Paul Pogonyshev wrote: > I'm not sure which one comes first. [...] I can just do > > foo.c : foo.h > foo.c foo.h : ... > if $(BUILD_THEM_FILES) foo.list foo.h foo.c; then \ > touch foo.c;

Re: builddir vs. srcdir

2005-03-10 Thread Paul Pogonyshev
> Hi, > > On Wed, Mar 09, 2005 at 11:21:35PM +0200, Paul Pogonyshev wrote: > > > And I'd like to suggest that you use SUFFIXES to handle the .list > > > source. Please look at the following example: > > > > Well, my generator is even more non-standard, since I need to pass an > > additional comma

Re: builddir vs. srcdir

2005-03-10 Thread Paul Pogonyshev
Alexandre Duret-Lutz wrote: > >>> "Paul" == Paul Pogonyshev <[EMAIL PROTECTED]> writes: > > Paul> Stepan Kasal wrote: > >> Hello, > >> > >> On Tue, Mar 08, 2005 at 11:56:56PM +0200, Paul Pogonyshev wrote: > >> > because the generated sources are placed into the build directory, > >> > while `

Re: builddir vs. srcdir

2005-03-10 Thread Alexandre Duret-Lutz
>>> "Harald" == Harald Dunkel <[EMAIL PROTECTED]> writes: Harald> Whats about a more general case http://sources.redhat.com/automake/automake.html#Multiple-Outputs -- Alexandre Duret-Lutz

Re: builddir vs. srcdir

2005-03-10 Thread Stepan Kasal
Hi, On Wed, Mar 09, 2005 at 11:21:35PM +0200, Paul Pogonyshev wrote: > > And I'd like to suggest that you use SUFFIXES to handle the .list > > source. Please look at the following example: > > Well, my generator is even more non-standard, since I need to pass an > additional command-line paramet

Re: builddir vs. srcdir

2005-03-10 Thread Ralf Wildenhues
* Harald Dunkel wrote on Thu, Mar 10, 2005 at 09:27:34AM CET: > Stepan Kasal wrote: > >On Tue, Mar 08, 2005 at 11:56:56PM +0200, Paul Pogonyshev wrote: > > > >>foo.c foo.h : $(srcdir)/foo.list $(PARSE_LIST) > >>$(PARSE_LIST) $(srcdir)/foo.list foo.h foo.c\ > >> || (rm -f foo.c foo.h ;

Re: builddir vs. srcdir

2005-03-10 Thread Harald Dunkel
Stepan Kasal wrote: Hello, On Tue, Mar 08, 2005 at 11:56:56PM +0200, Paul Pogonyshev wrote: foo.c foo.h : $(srcdir)/foo.list $(PARSE_LIST) $(PARSE_LIST) $(srcdir)/foo.list foo.h foo.c\ || (rm -f foo.c foo.h ; exit 1) This rule can break with parallel make. You can solve the

Re: builddir vs. srcdir

2005-03-09 Thread Alexandre Duret-Lutz
>>> "Paul" == Paul Pogonyshev <[EMAIL PROTECTED]> writes: Paul> Stepan Kasal wrote: >> Hello, >> >> On Tue, Mar 08, 2005 at 11:56:56PM +0200, Paul Pogonyshev wrote: >> > because the generated sources are placed into the build directory, >> > while `make' looks for them in the source directo

Re: builddir vs. srcdir

2005-03-09 Thread Paul Pogonyshev
Stepan Kasal wrote: > Hello, > > On Tue, Mar 08, 2005 at 11:56:56PM +0200, Paul Pogonyshev wrote: > > because the generated sources are placed into the build directory, > > while `make' looks for them in the source directory. > > generally, make should look for them in both places. Yes, and it doe

Re: builddir vs. srcdir

2005-03-09 Thread Stepan Kasal
Hello, On Tue, Mar 08, 2005 at 11:56:56PM +0200, Paul Pogonyshev wrote: > because the generated sources are placed into the build directory, > while `make' looks for them in the source directory. generally, make should look for them in both places. Let me point out several problems: > BUILT_SOU

builddir vs. srcdir

2005-03-09 Thread Paul Pogonyshev
Hi. I'm currently massaging my `Makefile.am's to allow building in a separate directory. However, I have a problem which I cannot find how to solve. I have a few source (`.c' and `.h') files which are generated at build time from another source using a custom utility. When the build directory i