the3dfxdude / 7kaa

Seven Kingdoms: Ancient Adversaries - Go to the main source repository at https://sourceforge.net/projects/skfans/ for source code and builds
https://7kfans.com
Other
253 stars 71 forks source link

Make error: "mv: cannot stat 't-de.gmo': No such file or directory" #269

Closed J-Moravec closed 1 year ago

J-Moravec commented 1 year ago

The critical part of the PO makefile is about here:

.po.gmo:
    @lang=`echo $* | sed -e 's,.*/,,'`; \
    test "$(srcdir)" = . && cdcmd="" || cdcmd="cd $(srcdir) && "; \
    echo "$${cdcmd}rm -f $${lang}.gmo && $(GMSGFMT) -c --statistics --verbose -o $${lang}.gmo $${lang}.po"; \
    cd $(srcdir) && rm -f $${lang}.gmo && $(GMSGFMT) -c --statistics --verbose -o t-$${lang}.gmo $${lang}.po && mv t-$${lang}.gmo $${lang}.gmo

where .po.gmo is an old style suffix rule, modern (and IMHO much more readable) is %.gmo : %.po. Maybe I can update it?

Reading the rule, there are few things that don't match. The echo variables do not correspond to the variables in the actual commands (cdcmd instead of srcdir), and GMSGFMT evaluates to :, which is again an old style of True.

But True -c --statistics --verbose -o ... doesn't do anything. I does not create t-$${lang}.gmo.

the3dfxdude commented 1 year ago

GMSGFMT is supposed to evaluate to /usr/bin/msgfmt. Check you gettext-tools installation.

As far as cleanup, you can speak with the gettext team. The Makefile comes out of a templated Makefile.in.in provided in their distribution. I'll be sticking with what comes from upstream. (see /usr/share/gettext/po/Makefile.in.in or get a copy in gettext-tools source distribution)

J-Moravec commented 1 year ago

Solved. I didn't have autoconf-archive installed