Benno Schulenberg <bensb...@justemail.net> writes:

> I've tried it in grep: I've added nl.gmo as a prerequisite of 'make all',
> and have very bluntly added this in po/Makefile:
>
> nl.gmo: nl.po
>         msgfmt -cv nl.po
>         mv messages.mo nl.gmo
>
> When I then run 'make', nl.gmo gets updated when I've touched nl.po,

With that setting, I guess you also see weird side effects, for example:

  $ cd grep/po
  $ rm *.pot stamp-po
  $ make
  ...
  /usr/bin/msgmerge --update  --lang=nb nb.po grep.pot
  ............. done.
  /usr/bin/msgmerge --update  --lang=nl nl.po grep.pot
  ............. done.
  /usr/bin/msgmerge --update  --lang=pa pa.po grep.pot
  ............. done.
  ...
  $ make
  /usr/bin/msgmerge --update  --lang=nl nl.po grep.pot
  ............. done.
  $ make
  /usr/bin/msgmerge --update  --lang=nl nl.po grep.pot
  ............. done.

This happens because nl.gmo depends on nl.po, and the timestamp of nl.po
is behind grep.pot.  Actually, nl.po is not updated on each 'make' run
above (because the '.nop.po-update' rule checks if the file content has
changed), but it's not good to run 'msgmerge' every time, especially
when one compiles a package from a tarball.

> changed a string in src/grep.c, which should trigger a POT update if
> this were automatic.

I was talking about the update of .po files (with 'msgmerge'), not a POT
file (though the above example has nothing to do with version control,
sorry; this stuff is really complex to understand :-)

Regards,
-- 
Daiki Ueno

Reply via email to