diff options
author | Tommy Reynolds <Tommy.Reynolds@MegaCoder.com> | 2006-03-03 00:13:18 +0000 |
---|---|---|
committer | Tommy Reynolds <Tommy.Reynolds@MegaCoder.com> | 2006-03-03 00:13:18 +0000 |
commit | d226661fa5b6620b4012b3157d839e99c7125351 (patch) | |
tree | 0e872c8e0d5eb9bd61241f278cfc07b6c5f236ff /common/entities/Makefile | |
parent | 32e1656ffdc1d2a5023849275e41303739f7cd17 (diff) | |
download | fedora-doc-utils-d226661fa5b6620b4012b3157d839e99c7125351.tar.gz fedora-doc-utils-d226661fa5b6620b4012b3157d839e99c7125351.tar.xz fedora-doc-utils-d226661fa5b6620b4012b3157d839e99c7125351.zip |
Stupid %.ent:%.xml form didn't allow for additional dependancies and the
.ent file may not be regenerated when necesssary. This has been fixed
by adding a template. All hail the template!
Diffstat (limited to 'common/entities/Makefile')
-rw-r--r-- | common/entities/Makefile | 36 |
1 files changed, 13 insertions, 23 deletions
diff --git a/common/entities/Makefile b/common/entities/Makefile index d146271..bcff8f2 100644 --- a/common/entities/Makefile +++ b/common/entities/Makefile @@ -1,5 +1,5 @@ PRI_LANG=en_US -OTHERS =en it pt_BR ru zh_CN +OTHERS =de en it pt_BR ru zh_CN ####################################################################### # PLEASE: @@ -25,16 +25,6 @@ ENTFILES=$(foreach L,${PRI_LANG} ${OTHERS},entities-${L}.ent) ####################################################################### ####################################################################### -# Rule: Apply stylesheet to transform XML into locale-specific ".ent" -# entities file -# -%.ent: %.xml - xsltproc -o $@ --stringparam FDPCOMMONDIR "${FDPCOMMONDIR}" \ - entities.xsl $< -# -####################################################################### - -####################################################################### # Printf(1) format string for describing targets by "make help". HELPFMT ="%-23s\t| %s.\n" # @@ -63,7 +53,7 @@ help:: ####################################################################### ####################################################################### -# Target 'entities.pot' makes a TEMPORARY seed translation file. We +# Target 'entities.pot' makes a seed translation file. We # use the original-language entities XML file as the source. # .PHONY: pot @@ -71,6 +61,9 @@ help:: pot entities.pot:: entities-${PRI_LANG}.xml xml2po -o entities.pot $< +distclean:: + ${RM} entities.pot + help:: @printf ${HELPFMT} "make pot" "Create template PO file" @printf ${HELPFMT} "make entities.pot" "Create template PO file" @@ -174,19 +167,16 @@ distclean clobber:: clean ${RM} ${ENTFILES} help:: - @printf ${HELPFMT} "make distclean" "Delete all generated files" - @printf ${HELPFMT} "make clobber" "Delete all generated files" + @printf ${HELPFMT} "make distclean" "Delete all generated files" + @printf ${HELPFMT} "make clobber" "Delete all generated files" # ####################################################################### ####################################################################### -# We create EXACTLY one .POT file, and treat is as a temporary file. -# Do NOT EDIT the .POT file if you are sharing this directory! -# -entities.pot:: entities-${PRI_LANG}.xml - xml2po -o $@ $< - -help:: - @printf ${HELPFMT} "make entities.pot" "Create template .PO file" -# +define ENT_template +entities-${1}.ent:: entities-${1}.xml entities.pot + xsltproc -o @$@ --stringparam FDPCOMMONDIR "${FDPCOMMONDIR}" \ + entities.xsl entities-${1}.xml +endef +$(foreach L,${PRI_LANG} ${OTHERS},$(eval $(call ENT_template,${L}))) ####################################################################### |