Re: gmake/make dependency problem
Harlan, On Wed, 21 Sep 2005, Harlan Stenn wrote: HS>It is ugly to add $(srcdir) to the targets (and perhaps dependencies), HS>but that may have to happen. For the 'foreseeable future' - yes. HS>If I say: HS> HS>srcdir=wherever HS>VPATH: $(srcdir) HS> HS>a: b HS> HS>b: c HS> cd $(srcdir) && script c > b HS> HS>then it is Strange that make will correctly see that for 'a', the HS>dependency is 'b' and 'b' is found in $(srcdir)/b, yet for the 2nd HS>rule, 'b' is expected to be in the current directory. Are you sure that make sees a? Try make -dm and you'll see that it doesn't see a, nor b for the seconds rule. harti ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to "[EMAIL PROTECTED]"
Re: gmake/make dependency problem
Harti, It is ugly to add $(srcdir) to the targets (and perhaps dependencies), but that may have to happen. If I say: srcdir=wherever VPATH: $(srcdir) a: b b: c cd $(srcdir) && script c > b then it is Strange that make will correctly see that for 'a', the dependency is 'b' and 'b' is found in $(srcdir)/b, yet for the 2nd rule, 'b' is expected to be in the current directory. H ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to "[EMAIL PROTECTED]"
Re: gmake/make dependency problem
Hi Harlan, On Tue, 20 Sep 2005, Harlan Stenn wrote: HS>I guess it depends on your definition of a "source" file. That's fairly easy: what's left of the ':' is the target, what's right of it is the source. This is just the terminology make is using. HS>I think of a Makefile in terms of "target" and "dependency" files. HS> HS>Automake makes it easy to build a package in the source tree (in which HS>case the "source" file is in the same directory as the object files) or HS>in a separate build/object tree. 'Source' in make-speak is not the same as source code for the program you're going to compile. Posix make as such has no support for compiling in separate build/object trees. HS> HS>Under gmake the behavior is consistent. HS> HS>Under (at least FreeBSD's) (p)make, the behavior is not consistent. That just depends on what one thinks is consistent. It works either way around. Just look at how easy you can build FreeBSD under /usr/obj - you don't need any cd commands in Makefiles usually. HS>The example I face is no different that a system that uses lex and yacc HS>(in the case where the distribution provides generated .c and .h files). This is not the problem. The problem is, that you don't have a clear cut between the source and the build directory. With BSD make files you never write into the source directory. Your Makefile tries to do this, when it updates ntpd-opts.c. This seems not too lucky too me. The ntpd-opts.c file is a build-file, not a source file and so it should reside in the build directory. If you want to distribute it, then copy or link it from the source directory to the build directory if the one in the source directory is up-to-date, if not just build a new one in the build directory. (this probably requires some thinking to get it right). The build process should never try to write to the source directory except when the user explicitely asks it to do so. HS>Does a POSIX spec cover this case? As I said POSIX make does not directly support .PATH or VPATH. If you work in another directory you need to specify the path on both target and source sides of the rules. A simple fix in your case is specifying files on the target side of rules with the prefix to the source directory and relying on VPATH to find source files. This is in fact easy - I build my own Makefiles this way. A better fix is not to make the build process write to the source directory altogether. While it would surely be possible to make BSD make work like GNU/Sun make, this would be a huge undertaking with regard to testing. harti ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to "[EMAIL PROTECTED]"
Re: gmake/make dependency problem
Harti, I guess it depends on your definition of a "source" file. I think of a Makefile in terms of "target" and "dependency" files. Automake makes it easy to build a package in the source tree (in which case the "source" file is in the same directory as the object files) or in a separate build/object tree. Under gmake the behavior is consistent. Under (at least FreeBSD's) (p)make, the behavior is not consistent. The example I face is no different that a system that uses lex and yacc (in the case where the distribution provides generated .c and .h files). Does a POSIX spec cover this case? Thanks... H ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to "[EMAIL PROTECTED]"
Re: gmake/make dependency problem
[I answer to this mail; because I did not see the original one] On Tue, 20 Sep 2005, Giorgos Keramidas wrote: GK>On 2005-09-19 19:00, Harlan Stenn <[EMAIL PROTECTED]> wrote: GK>> I'm confused. GK>> GK>> I believe that: GK>> GK>> a: b GK>> GK>> means that 'a' depends on 'b', and if 'b' has a later timestamp than 'a' GK>> then the rule will be invoked to produce a new 'a' from whatever is GK>> done with 'b'. GK>> GK>> In this case, 'a' is ntpd-opts.c, and 'b' is ntpd-opts.def. GK>> GK>> As can be seen on your system and mine: GK>> GK>> > It seems that ntpd-opts.c has a timestamp 1 minute after ntpd-opts.def, GK>> GK>> which means it is up-to-date with respect to its dependencies. GK> GK>True. I was confused when I posted my previous reply. With the tarball GK>you posted, I can run make(1) with -ddm and see what you mean: GK> GK> 1 % flame:/home/keramida/ws/ntp/obj/ntpq$ make -ddm GK> 2 % Caching done GK> 3 % Caching /usr/share/mk...done GK> 4 % expanding "sys.mk".../usr/share/mk/sys.mk GK> 5 % Searching for /etc/make.conf...Looking for "/etc/make.conf"...Caching 18:38:48 Sep 12, 2005 for /etc/make.conf GK> 6 % Searching for /etc/make.conf...Looking for "/etc/make.conf"...got it (in mtime cache) GK> 7 % Searching for bsd.compat.mk...failed. GK> 8 % Searching for bsd.compat.mk...failed. GK> 9 % Searching for bsd.compat.mk.../usr/share/mk...here...returning /usr/share/mk/bsd.compat.mk GK> 10 % Searching for bsd.cpu.mk...failed. GK> 11 % Searching for bsd.cpu.mk...failed. GK> 12 % Searching for bsd.cpu.mk.../usr/share/mk...here...returning /usr/share/mk/bsd.cpu.mk GK> 13 % Searching for BSDmakefile...failed. GK> 14 % Searching for BSDmakefile.../usr/share/mk...failed. GK> 15 % Searching for makefile...failed. GK> 16 % Searching for makefile.../usr/share/mk...failed. GK> 17 % Searching for ./.deps/ntpq.Po...failed. Trying subdirectories...failed. Looking for "./.deps/ntpq.Po"...Caching 01:09:41 Sep 20, 2005 for ./.deps/ntpq.Po GK> 18 % Searching for ./.deps/ntpq-opts.Po...failed. Trying subdirectories...failed. Looking for "./.deps/ntpq-opts.Po"...Caching 01:09:42 Sep 20, 2005 for ./.deps/ntpq-opts.Po GK> 19 % Searching for ./.deps/ntpq-subs.Po...failed. Trying subdirectories...failed. Looking for "./.deps/ntpq-subs.Po"...Caching 01:09:41 Sep 20, 2005 for ./.deps/ntpq-subs.Po GK> 20 % Searching for .depend...failed. GK> 21 % Searching for .depend.../usr/share/mk...failed. GK> 22 % Caching ../../ntp-4.2.0b/ntpq...done GK> 23 % Searching for ntpq-opts.def.c./../ntp-4.2.0b/ntpq...failed. GK> 24 % Searching for ntpq-opts.def...failed. GK> 25 % Examining ntpq-opts.def...Searching for ntpq-opts.def./../ntp-4.2.0b/ntpq...here...returning ../../ntp-4.2.0b/ntpq/ntpq-opts.def GK> 26 % modified 11:02:16 Aug 30, 2005...up-to-date. GK> 27 % Examining ntpq-opts.c...non-existent...modified before source...out-of-date. GK> 28 % cd ../../ntp-4.2.0b/ntpq && autogen ntpq-opts.def GK> 29 % autogen: not found GK> 30 % *** Error code 127 GK> 31 % GK> 32 % Stop in /home/keramida/ws/ntp/obj/ntpq. GK> 33 % flame:/home/keramida/ws/ntp/obj/ntpq$ GK> GK>At line 27 I see that ntpq-opts.c isn't looked up in VPATH. This may be GK>a make(1) bug, sorry for the initial confusion. GK> GK>I've Cc'ed Harti who's been working on make(1) lately. Ok. The following Makefile reproduces this problem: VPATH = foo .SUFFIXES: .SUFFIXES: .c .o x: b.c echo x-b >x b.c : a.def cd foo; echo b-a >b.c .c.o: cc -c $< # Then do: mkdir foo touch foo/a.def (wait a little bit) touch foo/b.c make # I'm not sure that this is really a bug. The man page for make(1) says: VPATH Makefiles may assign a colon-delimited list of directo- ries to VPATH. These directories will be searched for source files by make after it has finished parsing all input makefiles. Note, that it says 'sources'. That is, make(1) will not find foo/b.c when processing the dependency b.c : a.def. gmake on the other hand applies VPATH also to targets. If you change the Makefile like: VPATH= foo .SUFFIXES: .SUFFIXES: .c .o x: b.c echo x-b foo/b.c : a.def echo b-a >foo/b.c .c.o: cc -c $< It seems to work. harti ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to "[EMAIL PROTECTED]"
Re: gmake/make dependency problem
Thanks very much, Harti! H ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to "[EMAIL PROTECTED]"
Re: gmake/make dependency problem
On Tue, 20 Sep 2005, Giorgos Keramidas wrote: GK>On 2005-09-19 19:00, Harlan Stenn <[EMAIL PROTECTED]> wrote: GK>> I'm confused. GK>> GK>> I believe that: GK>> GK>> a: b GK>> GK>> means that 'a' depends on 'b', and if 'b' has a later timestamp than 'a' GK>> then the rule will be invoked to produce a new 'a' from whatever is GK>> done with 'b'. GK>> GK>> In this case, 'a' is ntpd-opts.c, and 'b' is ntpd-opts.def. GK>> GK>> As can be seen on your system and mine: GK>> GK>> > It seems that ntpd-opts.c has a timestamp 1 minute after ntpd-opts.def, GK>> GK>> which means it is up-to-date with respect to its dependencies. GK> GK>True. I was confused when I posted my previous reply. With the tarball GK>you posted, I can run make(1) with -ddm and see what you mean: GK> GK> 1 % flame:/home/keramida/ws/ntp/obj/ntpq$ make -ddm GK> 2 % Caching done GK> 3 % Caching /usr/share/mk...done GK> 4 % expanding "sys.mk".../usr/share/mk/sys.mk GK> 5 % Searching for /etc/make.conf...Looking for "/etc/make.conf"...Caching 18:38:48 Sep 12, 2005 for /etc/make.conf GK> 6 % Searching for /etc/make.conf...Looking for "/etc/make.conf"...got it (in mtime cache) GK> 7 % Searching for bsd.compat.mk...failed. GK> 8 % Searching for bsd.compat.mk...failed. GK> 9 % Searching for bsd.compat.mk.../usr/share/mk...here...returning /usr/share/mk/bsd.compat.mk GK> 10 % Searching for bsd.cpu.mk...failed. GK> 11 % Searching for bsd.cpu.mk...failed. GK> 12 % Searching for bsd.cpu.mk.../usr/share/mk...here...returning /usr/share/mk/bsd.cpu.mk GK> 13 % Searching for BSDmakefile...failed. GK> 14 % Searching for BSDmakefile.../usr/share/mk...failed. GK> 15 % Searching for makefile...failed. GK> 16 % Searching for makefile.../usr/share/mk...failed. GK> 17 % Searching for ./.deps/ntpq.Po...failed. Trying subdirectories...failed. Looking for "./.deps/ntpq.Po"...Caching 01:09:41 Sep 20, 2005 for ./.deps/ntpq.Po GK> 18 % Searching for ./.deps/ntpq-opts.Po...failed. Trying subdirectories...failed. Looking for "./.deps/ntpq-opts.Po"...Caching 01:09:42 Sep 20, 2005 for ./.deps/ntpq-opts.Po GK> 19 % Searching for ./.deps/ntpq-subs.Po...failed. Trying subdirectories...failed. Looking for "./.deps/ntpq-subs.Po"...Caching 01:09:41 Sep 20, 2005 for ./.deps/ntpq-subs.Po GK> 20 % Searching for .depend...failed. GK> 21 % Searching for .depend.../usr/share/mk...failed. GK> 22 % Caching ../../ntp-4.2.0b/ntpq...done GK> 23 % Searching for ntpq-opts.def.c./../ntp-4.2.0b/ntpq...failed. GK> 24 % Searching for ntpq-opts.def...failed. GK> 25 % Examining ntpq-opts.def...Searching for ntpq-opts.def./../ntp-4.2.0b/ntpq...here...returning ../../ntp-4.2.0b/ntpq/ntpq-opts.def GK> 26 % modified 11:02:16 Aug 30, 2005...up-to-date. GK> 27 % Examining ntpq-opts.c...non-existent...modified before source...out-of-date. GK> 28 % cd ../../ntp-4.2.0b/ntpq && autogen ntpq-opts.def GK> 29 % autogen: not found GK> 30 % *** Error code 127 GK> 31 % GK> 32 % Stop in /home/keramida/ws/ntp/obj/ntpq. GK> 33 % flame:/home/keramida/ws/ntp/obj/ntpq$ GK> GK>At line 27 I see that ntpq-opts.c isn't looked up in VPATH. This may be GK>a make(1) bug, sorry for the initial confusion. GK> GK>I've Cc'ed Harti who's been working on make(1) lately. That seems to be a subtile bug in the suffix module (which I, it seems, now have to try to understand :-) For some reason that module decides that it doesn't need to look for the .c file actually. I look into this. harti ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to "[EMAIL PROTECTED]"
Re: gmake/make dependency problem
Thanks very much! H ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to "[EMAIL PROTECTED]"
Re: gmake/make dependency problem
On 2005-09-19 19:00, Harlan Stenn <[EMAIL PROTECTED]> wrote: > I'm confused. > > I believe that: > > a: b > > means that 'a' depends on 'b', and if 'b' has a later timestamp than 'a' > then the rule will be invoked to produce a new 'a' from whatever is > done with 'b'. > > In this case, 'a' is ntpd-opts.c, and 'b' is ntpd-opts.def. > > As can be seen on your system and mine: > > > It seems that ntpd-opts.c has a timestamp 1 minute after ntpd-opts.def, > > which means it is up-to-date with respect to its dependencies. True. I was confused when I posted my previous reply. With the tarball you posted, I can run make(1) with -ddm and see what you mean: 1 % flame:/home/keramida/ws/ntp/obj/ntpq$ make -ddm 2 % Caching done 3 % Caching /usr/share/mk...done 4 % expanding "sys.mk".../usr/share/mk/sys.mk 5 % Searching for /etc/make.conf...Looking for "/etc/make.conf"...Caching 18:38:48 Sep 12, 2005 for /etc/make.conf 6 % Searching for /etc/make.conf...Looking for "/etc/make.conf"...got it (in mtime cache) 7 % Searching for bsd.compat.mk...failed. 8 % Searching for bsd.compat.mk...failed. 9 % Searching for bsd.compat.mk.../usr/share/mk...here...returning /usr/share/mk/bsd.compat.mk 10 % Searching for bsd.cpu.mk...failed. 11 % Searching for bsd.cpu.mk...failed. 12 % Searching for bsd.cpu.mk.../usr/share/mk...here...returning /usr/share/mk/bsd.cpu.mk 13 % Searching for BSDmakefile...failed. 14 % Searching for BSDmakefile.../usr/share/mk...failed. 15 % Searching for makefile...failed. 16 % Searching for makefile.../usr/share/mk...failed. 17 % Searching for ./.deps/ntpq.Po...failed. Trying subdirectories...failed. Looking for "./.deps/ntpq.Po"...Caching 01:09:41 Sep 20, 2005 for ./.deps/ntpq.Po 18 % Searching for ./.deps/ntpq-opts.Po...failed. Trying subdirectories...failed. Looking for "./.deps/ntpq-opts.Po"...Caching 01:09:42 Sep 20, 2005 for ./.deps/ntpq-opts.Po 19 % Searching for ./.deps/ntpq-subs.Po...failed. Trying subdirectories...failed. Looking for "./.deps/ntpq-subs.Po"...Caching 01:09:41 Sep 20, 2005 for ./.deps/ntpq-subs.Po 20 % Searching for .depend...failed. 21 % Searching for .depend.../usr/share/mk...failed. 22 % Caching ../../ntp-4.2.0b/ntpq...done 23 % Searching for ntpq-opts.def.c./../ntp-4.2.0b/ntpq...failed. 24 % Searching for ntpq-opts.def...failed. 25 % Examining ntpq-opts.def...Searching for ntpq-opts.def./../ntp-4.2.0b/ntpq...here...returning ../../ntp-4.2.0b/ntpq/ntpq-opts.def 26 % modified 11:02:16 Aug 30, 2005...up-to-date. 27 % Examining ntpq-opts.c...non-existent...modified before source...out-of-date. 28 % cd ../../ntp-4.2.0b/ntpq && autogen ntpq-opts.def 29 % autogen: not found 30 % *** Error code 127 31 % 32 % Stop in /home/keramida/ws/ntp/obj/ntpq. 33 % flame:/home/keramida/ws/ntp/obj/ntpq$ At line 27 I see that ntpq-opts.c isn't looked up in VPATH. This may be a make(1) bug, sorry for the initial confusion. I've Cc'ed Harti who's been working on make(1) lately. - Giorgos ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to "[EMAIL PROTECTED]"
Re: gmake/make dependency problem
I'm confused. I believe that: a: b means that 'a' depends on 'b', and if 'b' has a later timestamp than 'a' then the rule will be invoked to produce a new 'a' from whatever is done with 'b'. In this case, 'a' is ntpd-opts.c, and 'b' is ntpd-opts.def. As can be seen on your system and mine: > It seems that ntpd-opts.c has a timestamp 1 minute after ntpd-opts.def, which means it is up-to-date with respect to its dependencies. You will also note the VPATH in the Makefile includes the source directory. I believe this is a VPATH issues. Am I missing something? I appreciate your working with me on this issue. H -- > > > > should show it trying to run autogen to produce ../../ntpd/ntpd-opts.c > > (which exists and should have "proper" timestamps with respect to its > > dependencies), and: > > It doesn't though. ntpd-opts.c depends on ntpd-opts.def, and their > timestamps are: > > % flame:/home/keramida/ws/ntp/ntp-4.2.0b/obj/ntpd$ make -ndm > % Examining ntpd-opts.def...modified 11:01:00 Aug 30, 2005...up-to-date. > % Examining ntpdbase-opts.def...modified 10:57:02 Aug 26, 2005...up-to-date. > % Examining ntpd-opts.c...non-existent...modified before source...out-of-date > . > % cd ../../ntpd && autogen ntpd-opts.def % update time: 17:38:09 Sep 19, 2005 > % [...] > % flame:/home/keramida/ws/ntp/ntp-4.2.0b/obj/ntpd$ ls -ld ../../ntpd/ntpd-opt > s.c ../../ntpd/ntpd-opts.def > % -r--r--r-- 1 keramida keramida - 32849 Aug 30 11:02 ../../ntpd/ntpd-opts > .c > % -rw-rw-r-- 1 keramida keramida - 1255 Aug 30 11:01 ../../ntpd/ntpd-opts > .def > > It seems that ntpd-opts.c has a timestamp 1 minute after ntpd-opts.def, > and this is what triggers the autogen run. > > > % gmake ntpd-opts.c > > > > should say the target is up-to-date. > > I don't think this is correct. The obj/ntpd/Makefile file contains: > > % flame:/home/keramida/ws/ntp/ntp-4.2.0b/obj/ntpd$ grep ntpd-opts.def * | cat > -n > % 1 EXTRA_DIST = ntpd-opts.def ntpdbase-opts.def ntpdsim-opts.def $(BUI > LT_SOURCES) > % 2 ntpd-opts.c: ntpd-opts.def ntpdbase-opts.def > % 3 cd $(srcdir) && autogen ntpd-opts.def > % 4 ntpd.1: ntpd-opts.def ntpdbase-opts.def > % 5 cd $(srcdir) && autogen -Tagman1.tpl -bntpd ntpd-opts.def > % 6 ntpd-opts.texi ntpd-opts.menu: ntpd-opts.def > % 7 -Taginfo.tpl -DLEVEL=section ntpd-opts.def > % flame:/home/keramida/ws/ntp/ntp-4.2.0b/obj/ntpd$ > > The second matched line clearly states that ntpd-opts.c depends on > ntpd-opts.def and their timestamps are backwards. make(1) is right in > this case, IMHO > ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to "[EMAIL PROTECTED]"
Re: gmake/make dependency problem
On 2005-09-19 01:54, Harlan Stenn <[EMAIL PROTECTED]> wrote: > I could try and post fragments, but I'd probably mess it up. > > The full tarball is at: > > http://ntp.isc.org/~stenn/ntp-4.2.0b.tar.gz > > and I to duplicate the problem I recommend: > > % tar xzf ... > % cd ntp-4.2.0b > % mkdir A.foo > % cd A.foo > % ../configure > % make > > and it will soon die in ntpd/, at which point: > > % cd ntpd > % make -n ntpd-opts.c > > should show it trying to run autogen to produce ../../ntpd/ntpd-opts.c > (which exists and should have "proper" timestamps with respect to its > dependencies), and: It doesn't though. ntpd-opts.c depends on ntpd-opts.def, and their timestamps are: % flame:/home/keramida/ws/ntp/ntp-4.2.0b/obj/ntpd$ make -ndm % Examining ntpd-opts.def...modified 11:01:00 Aug 30, 2005...up-to-date. % Examining ntpdbase-opts.def...modified 10:57:02 Aug 26, 2005...up-to-date. % Examining ntpd-opts.c...non-existent...modified before source...out-of-date. % cd ../../ntpd && autogen ntpd-opts.def % update time: 17:38:09 Sep 19, 2005 % [...] % flame:/home/keramida/ws/ntp/ntp-4.2.0b/obj/ntpd$ ls -ld ../../ntpd/ntpd-opts.c ../../ntpd/ntpd-opts.def % -r--r--r-- 1 keramida keramida - 32849 Aug 30 11:02 ../../ntpd/ntpd-opts.c % -rw-rw-r-- 1 keramida keramida - 1255 Aug 30 11:01 ../../ntpd/ntpd-opts.def It seems that ntpd-opts.c has a timestamp 1 minute after ntpd-opts.def, and this is what triggers the autogen run. > % gmake ntpd-opts.c > > should say the target is up-to-date. I don't think this is correct. The obj/ntpd/Makefile file contains: % flame:/home/keramida/ws/ntp/ntp-4.2.0b/obj/ntpd$ grep ntpd-opts.def * | cat -n % 1 EXTRA_DIST = ntpd-opts.def ntpdbase-opts.def ntpdsim-opts.def $(BUILT_SOURCES) % 2 ntpd-opts.c: ntpd-opts.def ntpdbase-opts.def % 3 cd $(srcdir) && autogen ntpd-opts.def % 4 ntpd.1: ntpd-opts.def ntpdbase-opts.def % 5 cd $(srcdir) && autogen -Tagman1.tpl -bntpd ntpd-opts.def % 6 ntpd-opts.texi ntpd-opts.menu: ntpd-opts.def % 7 -Taginfo.tpl -DLEVEL=section ntpd-opts.def % flame:/home/keramida/ws/ntp/ntp-4.2.0b/obj/ntpd$ The second matched line clearly states that ntpd-opts.c depends on ntpd-opts.def and their timestamps are backwards. make(1) is right in this case, IMHO ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to "[EMAIL PROTECTED]"
Re: gmake/make dependency problem
This may help: [EMAIL PROTECTED]> make -ndm ntpd-opts.c Examining ntpd-opts.def...modified 04:01:00 Aug 30, 2005...up-to-date. Examining ntpdbase-opts.def...modified 03:57:02 Aug 26, 2005...up-to-date. Examining ntpd-opts.c...non-existent...modified before source...out-of-date. cd ../../ntpd && autogen ntpd-opts.def update time: 23:06:28 Sep 18, 2005 [EMAIL PROTECTED]> At least several of those are not true... H ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to "[EMAIL PROTECTED]"
Re: gmake/make dependency problem
I could try and post fragments, but I'd probably mess it up. The full tarball is at: http://ntp.isc.org/~stenn/ntp-4.2.0b.tar.gz and I to duplicate the problem I recommend: % tar xzf ... % cd ntp-4.2.0b % mkdir A.foo % cd A.foo % ../configure % make and it will soon die in ntpd/, at which point: % cd ntpd % make -n ntpd-opts.c should show it trying to run autogen to produce ../../ntpd/ntpd-opts.c (which exists and should have "proper" timestamps with respect to its dependencies), and: % gmake ntpd-opts.c should say the target is up-to-date. If you want me to try and help debug this another way I would be happy to do so. Thanks a bunch... H ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to "[EMAIL PROTECTED]"
Re: gmake/make dependency problem
On 2005-09-19 00:45, Harlan Stenn <[EMAIL PROTECTED]> wrote: > Here's what I am seeing: > > [EMAIL PROTECTED]> gmake -n ntpd-opts.c > gmake: `../../ntpd/ntpd-opts.c' is up to date. > [EMAIL PROTECTED]> make -n ntpd-opts.c > cd ../../ntpd && autogen ntpd-opts.def > [EMAIL PROTECTED]> Hmmm, without seeing the makefile, it seems that some of the targets ends up depending on nothing at all, which re-builds it every time make runs. I'd have to see at least the makefiles to be sure though :-( ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to "[EMAIL PROTECTED]"
Re: gmake/make dependency problem
Here's what I am seeing: [EMAIL PROTECTED]> gmake -n ntpd-opts.c gmake: `../../ntpd/ntpd-opts.c' is up to date. [EMAIL PROTECTED]> make -n ntpd-opts.c cd ../../ntpd && autogen ntpd-opts.def [EMAIL PROTECTED]> H ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to "[EMAIL PROTECTED]"
Re: gmake/make dependency problem
Yes, ntp is running on that machine and the clocks are OK! On that machine, gmake does not try and build this target, but 'make' does. Automake supports the BSD and GNU versions of 'make' and this is one of the things I am trying to check. I'm checking now to see if I have a tarball of the code that will duplicate the problem 'outside' of my development environment. H ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to "[EMAIL PROTECTED]"
Re: gmake/make dependency problem
On 2005-09-18 10:07, Harlan Stenn <[EMAIL PROTECTED]> wrote: > I have a package that uses automake and autoconf. > > I have a single copy of the source code, and I build in machine-specific > subdirectories (using NFS). > > I have a "master machine" which has all of the tools I need; I build > there first and then build on the other machines. > > One these other machines is an x86 FreeBSD-5.4 machine, and it has the > stock 'make' on it. > > When I try to build on this machine (after a successful build on the > master machine) make says that there is an out-of-date source file > and tries to run some tools to produce the source file. > > This source file is present in the VPATH. The timestamps on all of > the files are "correct". make says a file cannot be found and the file > is clearly there. > > I'm open to suggestions on how to find/fix this problem. Does the system-clock of the NFS client machine agree with the one on the NFS server system? I've had problems with 'outdated' targets in the past whenever an NFS server's ntpd died (and the system-clock started going off). Now, I know that posting what seems like an NTP-related to someone with an email address at ntp.isc.org is as close as I can get to 'herecy', but I have to ask :) ___ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to "[EMAIL PROTECTED]"