]> granicus.if.org Git - shadow/commitdiff
* man/po/Makefile.in.in: xml2po cannot exclude one entity for
authornekral-guest <nekral-guest@5a98b0ae-9ef6-0310-add3-de5d479b70d7>
Sat, 14 Mar 2009 16:18:06 +0000 (16:18 +0000)
committernekral-guest <nekral-guest@5a98b0ae-9ef6-0310-add3-de5d479b70d7>
Sat, 14 Mar 2009 16:18:06 +0000 (16:18 +0000)
expansion. Make sure config.xml does not exist when the POT file
is created in order to keep the configurations in the POT file
* man/generate_translations.mak: make sure config.xml does not
exist neither when the translated XML is generated. Add the
missing %config; (strip out by xml2po). and make sure config.xml
is present when the translated manpage is generated.
* man/generate_mans.mak: config.xml is needed for the generation
of manpages (already in the .deps for the English manpages, but
needed for the translations).
* man/Makefile.am: Added missing CREATE_HOME.xml.

ChangeLog
man/Makefile.am
man/generate_mans.mak
man/generate_translations.mak
man/po/Makefile.in.in

index 88407190ffae59c77f491c1f0e877d4923733053..5d9473e6d5e4f6ecb623a10064e217ee97a930d7 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,17 @@
+2009-03-14  Nicolas François  <nicolas.francois@centraliens.net>
+
+       * man/po/Makefile.in.in: xml2po cannot exclude one entity for
+       expansion. Make sure config.xml does not exist when the POT file
+       is created in order to keep the configurations in the POT file
+       * man/generate_translations.mak: make sure config.xml does not
+       exist neither when the translated XML is generated. Add the
+       missing %config; (strip out by xml2po). and make sure config.xml
+       is present when the translated manpage is generated.
+       * man/generate_mans.mak: config.xml is needed for the generation
+       of manpages (already in the .deps for the English manpages, but
+       needed for the translations).
+       * man/Makefile.am: Added missing CREATE_HOME.xml.
+
 2009-03-14  Nicolas François  <nicolas.francois@centraliens.net>
 
        * etc/login.defs: Added note for PAM enabled configurations.
index 3ef7b9de850af80ece6a81dd546b70d16650b12e..a8e9a5a659e4c7e9b40fdd6dcb48aa47a7ae9818 100644 (file)
@@ -105,6 +105,7 @@ login_defs_v = \
        CHSH_AUTH.xml \
        CONSOLE.xml \
        CONSOLE_GROUPS.xml \
+       CREATE_HOME.xml \
        DEFAULT_HOME.xml \
        ENCRYPT_METHOD.xml \
        ENV_HZ.xml \
index 4977d11d78fc92689b0b2664a90454b68af0b4b8..ec3f6d76fe53a767e93d1e7056f1ef52136450e5 100644 (file)
@@ -17,7 +17,7 @@ else
 SHA_CRYPT_COND=no_sha_crypt
 endif
 
-%: %.xml Makefile
+%: %.xml Makefile config.xml
        $(XSLTPROC) --stringparam profile.condition "$(PAM_COND);$(SHADOWGRP_COND);$(SHA_CRYPT_COND)" \
                    -nonet http://docbook.sourceforge.net/release/xsl/current/manpages/profile-docbook.xsl $<
 
index c4dbc2e9b54d0da0190dffe4b29b40865aa7e0b0..b3b671e89a46295c19c3f2c7670893a581420d0b 100644 (file)
@@ -3,8 +3,15 @@ if ENABLE_REGENERATE_MAN
 LANG=$(notdir $(CURDIR))
 
 %.xml: ../%.xml ../po/$(LANG).po
+       [ ! -f ../config.xml ] || mv ../config.xml ../config.xml.bak
        xml2po --expand-all-entities -l $(LANG) -p ../po/$(LANG).po -o $@ ../$@
        sed -i 's:\(^<refentry .*\)>:\1 lang="$(LANG)">:' $@
+       [ ! -f ../config.xml.bak ] || mv ../config.xml.bak ../config.xml
+       sed -i 's/config SYSTEM "config.xml">/config SYSTEM "config.xml">\%config;/' $@
+
+config.xml: ../config.xml.in
+       make -C .. config.xml
+       cp ../config.xml $@
 
 include ../generate_mans.mak
 
index 9de17f05be302ef61fced8b4a14752a6142ec177..93b4b7578e5acc5a8ff1e588da916468215b0538 100644 (file)
@@ -91,11 +91,15 @@ stamp-po: $(srcdir)/$(DOMAIN).pot
 # Note that $(DOMAIN).pot is not touched if it doesn't need to be changed.
 # TODO: set MSGID_BUGS_ADDRESS, COPYRIGHT_HOLDER
 $(DOMAIN).pot-update: $(POTFILES) $(srcdir)/POTFILES.in remove-potcdate.sed
-       @tmpdir=`pwd`; \
-       echo -n "cd $(top_srcdir)/man && "; \
-       echo "xml2po --expand-all-entities -o $(tmpdir)/$(DOMAIN).po $(notdir $(POTFILES))"; \
+       @set -e; tmpdir=`pwd`; \
+       echo "cd $(top_srcdir)/man"; \
        cd $(top_srcdir)/man; \
+       echo "[ ! -f config.xml ] || mv config.xml config.xml.bak"; \
+       [ ! -f config.xml ] || mv config.xml config.xml.bak; \
+       echo "xml2po --expand-all-entities -o $$tmpdir/$(DOMAIN).po $(notdir $(POTFILES))"; \
        xml2po --expand-all-entities -o $$tmpdir/$(DOMAIN).po $(notdir $(POTFILES)); \
+       echo "[ ! -f config.xml.bak ] || mv config.xml.bak config.xml"; \
+       [ ! -f config.xml.bak ] || mv config.xml.bak config.xml; \
        cd $$tmpdir
        test ! -f $(DOMAIN).po || { \
          if test -f $(srcdir)/$(DOMAIN).pot; then \