On 2015/09/28 04:12, Yozo TODA wrote:
> Stuart Henderson writes:
> > On 2015/09/27 13:20, Yozo TODA wrote:
> > > gmake[2]: Entering directory '/usr/ports/pobj/flex-2.5.39/flex-2.5.39/doc'
> > > Updating ./version.texi
> > 
> > I see what the problem is. Please try adding "MAKE_ENV= TZ=UTC" to the port
> > Makefile and let me know if you still see this 'Updating ./version.texi' 
> > line.
> 
> wow, we got it!  now I can do (fake and) package successfully!
> is it the problem of gmake?

Great, thanks for testing - I've committed this fix.

mdate-sh prints the modification date of a file, in a long format
(full month names etc), but it doesn't take timezones into account,
so it prints a different date if the timezone is too far from UTC.

$ TZ=GMT ls -l flex.texi
-rw-r--r--  1 sthen  sthen  293690 Dec  6  2012 flex.texi

$ TZ=GMT-9 ls -l flex.texi
-rw-r--r--  1 sthen  sthen  293690 Dec  7  2012 flex.texi

So the Makefile does this:

$(srcdir)/stamp-vti: flex.texi $(top_srcdir)/configure
        @(dir=.; test -f ./flex.texi || dir=$(srcdir); \
        set `$(SHELL) $(srcdir)/mdate-sh $$dir/flex.texi`; \
        echo "@set UPDATED $$1 $$2 $$3"; \
        echo "@set UPDATED-MONTH $$2 $$3"; \
        echo "@set EDITION $(VERSION)"; \
        echo "@set VERSION $(VERSION)") > vti.tmp
        @cmp -s vti.tmp $(srcdir)/version.texi \
          || (echo "Updating $(srcdir)/version.texi"; \
              cp vti.tmp $(srcdir)/version.texi)
        -@rm -f vti.tmp
        @cp $(srcdir)/version.texi $@

- it tests the timestamp of flex.texi and writes the result into a
temporary file. If this differs from version.texi it moves it into
place as version.texi, triggering a rebuild of the other files.

This is used in a couple of dozen other ports (mostly GNU software,
plus a few others) so depending on the timestamps of the files
involved, you may run into the same problem in other places.

Reply via email to