On Sun, 26 May 2013, Beno?t Minisini wrote:
> Le 26/05/2013 11:47, Beno?t Minisini a ?crit :
> > Le 26/05/2013 11:13, Tobias Boege a ?crit :
> >>
> >> One thing: trunk_version.h is always up to date since it's .PHONY.
> >
> > This is not what the 'make' documentation says.
> >
> > If a source file depends on a phony target like 'trunk_version.h' (which
> > is the case as soon as the file is explicitely included), then the phony
> > targer is always run.
> >
> > At least it behaves like that on my machine. Did you really check?
> >
> >> But gbx.c
> >> and friends don't depend on trunk_version.h
> >
> > They do, as they include the 'trunk_version.h' file.
> >
> 
> Maybe I see your problem; you have to run 'make' from /trunk/main so 
> that 'trunk_version.h' is automatically regenerated.
> 

Ah, got it. make does not detect these dependencies of included files
automatically[0]. The generated Makefiles use the gcc -M class of switches
to generate .deps/*.Po files which contain this information and are then
pulled in by the Makefiles.

I didn't know this was possible so I felt to add the dependencies by hand.
Will save me some work in other projects :-)

I'll go and revert that commit.

Regards,
Tobi

[0] http://scottmcpeak.com/autodepend/autodepend.html

------------------------------------------------------------------------------
Try New Relic Now & We'll Send You this Cool Shirt
New Relic is the only SaaS-based application performance monitoring service 
that delivers powerful full stack analytics. Optimize and monitor your
browser, app, & servers with just a few lines of code. Try New Relic
and get this awesome Nerd Life shirt! http://p.sf.net/sfu/newrelic_d2d_may
_______________________________________________
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user

Reply via email to