docs-common Makefile.common,1.61,1.62

Tommy Reynolds (jtr) fedora-docs-commits at redhat.com
Mon Feb 20 08:45:04 UTC 2006


Author: jtr

Update of /cvs/docs/docs-common
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv31347

Modified Files:
	Makefile.common 
Log Message:
Added "make targets" to see a list of all targets for the current 
"Makefile".  It looks much better if you sort the output:

make targets | sort

Needs some entries fleshed out.



Index: Makefile.common
===================================================================
RCS file: /cvs/docs/docs-common/Makefile.common,v
retrieving revision 1.61
retrieving revision 1.62
diff -u -r1.61 -r1.62
--- Makefile.common	17 Feb 2006 03:36:48 -0000	1.61
+++ Makefile.common	20 Feb 2006 08:44:56 -0000	1.62
@@ -157,12 +157,16 @@
 #########################################################################
 
 #########################################################################
+TFMT="%-31s -- %s\n"
+#########################################################################
+
+#########################################################################
 # PUT NO TARGETS BEFORE THIS ONE, not even in your base Makefile
 # In a properly-constructed Makefile, this will be the default target
 
 TARGETS=all clean distclean fdp-info html html-nochunks pdf po showvars \
         tarball rpm rpm-common noarch srpm package-prep package-post	\
-	src-tarball txt text
+	src-tarball txt text targets
 
 # FIXME: add the .PHONY attribute where the actual target is defined
 
@@ -173,6 +177,28 @@
 
 all::	html html-nochunks tarball # pdf
 
+targets::
+	@printf ${TFMT} 'targets' 'Outputs target summaries'
+	@printf ${TFMT} 'text' 'Same as "txt" target'
+	@printf ${TFMT} 'txt' 'Renders XML into ASCII text file'
+	@printf ${TFMT} 'src-tarball' 'FIXME'
+	@printf ${TFMT} 'package-post' 'FIXME'
+	@printf ${TFMT} 'package-prep' 'FIXME'
+	@printf ${TFMT} 'srpm' 'FIXME'
+	@printf ${TFMT} 'noarch' 'FIXME'
+	@printf ${TFMT} 'rpm-common' 'FIXME'
+	@printf ${TFMT} 'rpm' 'Builds RPM packages'
+	@printf ${TFMT} 'tarball' 'Packages HTML files into tar(1) archive'
+	@printf ${TFMT} 'clean'	'Removes temporary files'
+	@printf ${TFMT} 'distclean' 'Removes product files and temporaries'
+	@printf ${TFMT} 'fdp-info' 'Produces all $${LANG}/fdp-info.xml'
+	@printf ${TFMT} 'all'	'Builds html, html-nochunks, and tarball'
+	@printf ${TFMT} 'html'	'Renders XML into chunked HTML'
+	@printf ${TFMT} 'html-nochunks'	'Renders XML into one big HTML file'
+	@printf ${TFMT} 'pdf'	'Renders XML into one PDF file'
+	@printf ${TFMT} 'po'	'Updates .PO files for all $${OTHERS} locales'
+	@printf ${TFMT} 'showvars'	'Displays convenient make(1) variables'
+
 ${TARGETS}::
 
 #########################################################################
@@ -209,6 +235,10 @@
 
 distclean::
 	${RM} -r ${DOCBASE}-${1}
+
+targets::
+	@printf ${TFMT} 'html-${1}' 'Renders XML into locale ${1}'
+	@printf ${TFMT} '${1}/index.html' 'Renders XML into locale ${1}'
 endef
 
 $(foreach L,${LANGUAGES},$(eval $(call HTML_template,${L})))
@@ -239,6 +269,10 @@
 	${RM} -r stylesheet-images
 	${RM} fedora.css
 	${RM} watermark.png
+
+targets::
+	@printf ${TFMT} 'html-nochunks-${1}' 'Renders XML into locale ${1} HTML'
+	@printf ${TFMT} '${DOCBASE}-${1}.html' 'Renders XML into locale ${1} HTML'
 endef
 
 $(foreach L,${LANGUAGES},$(eval $(call HTMLNOCHUNK_template,${L})))
@@ -259,6 +293,9 @@
 
 distclean::
 	${RM} ${DOCBASE}-${1}.tar.gz
+
+targets::
+	@printf ${TFMT} '${DOCBASE}-${1}.tar.gz' 'Tar archive of HTML and images'
 endef
 
 $(foreach L,${LANGUAGES},$(eval $(call HTMLTAR_template,${L})))
@@ -280,6 +317,11 @@
 
 distclean::
 	${RM} ${DOCBASE}-${1}.pdf
+
+targets::
+	@printf ${TFMT} 'pdf-${1}' 'Renders XML into PDF file for locale ${1}'
+	@printf ${TFMT} '${DOCBASE}-${1}.pdf' 'Renders XML into PDF file'
+
 endef
 
 $(foreach L,${LANGUAGES},$(eval $(call PDF_template,${L})))
@@ -303,6 +345,12 @@
 
 distclean::
 	${RM} ${DOCBASE}-${1}.txt
+
+targets::
+	@printf ${TFMT} 'txt-${1}' 'Renders XML into ASCII text for locale ${1}'
+	@printf ${TFMT} 'text-${1}' 'Renders XML into ASCII text for locale ${1}'
+	@printf ${TFMT} '${DOCBASE}-${1}.txt' 'Renders XML into ASCII text for locale ${1}'
+
 endef
 
 $(foreach L,${LANGUAGES},$(eval $(call TXT_template,${L})))
@@ -323,6 +371,10 @@
 	[ -d po ] || (echo ADD po/ TO CVS >&2; exit 1)
 	${XML2PO} -o $@ $^
 
+targets::
+	@printf ${TFMT} 'po' 'Writes one ${PRI_LANG} PO file for all XML'
+	@printf ${TFMT} 'po/${DOCBASE}.pot' 'Writes one PO file for all XML'
+
 .PHONY:	pot
 
 pot::	po/${DOCBASE}.pot
@@ -335,6 +387,10 @@
 
 distclean::
 	${RM} -r ${1}
+
+targets::
+	@printf ${TFMT} '${1}' 'Creates translated XML working directory'
+
 endef
 
 $(foreach L,${OTHERS},$(eval $(call DIR_template,${L})))
@@ -357,18 +413,28 @@
 
 distclean::
 	${RM} -r ${1}
+
+targets::
+	@printf ${TFMT} 'xml-${1}' 'Produces translated XML for locale ${1}'
+
 endef
 
 .PHONY:	xml-${PRI_LANG}
 
 xml-${PRI_LANG}:: ${XMLFILES-${PRI_LANG}}
 
+targets::
+	@printf ${TFMT} 'xml-${PRI_LANG}' 'Comfirms primary language XML files.'
+
 $(foreach L,${OTHERS},$(eval $(call XMLTARGET_template,${L})))
 
 .PHONY:	xml-all
 
 xml-all:: $(foreach L,${LANGUAGES},xml-${L})
 
+targets::
+	@printf ${TFMT} 'xml-all' 'Creates all XML locale files'
+
 distclean::
 	$(foreach L,${OTHERS},${RM} -r ${L})
 #########################################################################
@@ -386,6 +452,11 @@
 
 .PHONY:	po-${1}
 po-${1}:: po/${1}.po
+
+targets::
+	@printf ${TFMT} 'po-${1}' 'Creates or updates locale ${1} .PO file'
+	@printf ${TFMT} 'po/${1}.po' 'Creates or updates locale ${1} .PO file'
+
 endef
 
 $(foreach L,${OTHERS},$(eval $(call PO_template,${L})))
@@ -416,6 +487,10 @@
 
 diff::
 	xmldiff ${DIFFS} ${OLD} ${NEW}
+
+targets::
+	@printf ${TFMT} 'diff' 'Compares XML files'
+
 #
 #########################################################################
 
@@ -436,6 +511,10 @@
 
 clean::
 	${RM} ${1}/fdp-info.xml
+
+targets::
+	@printf ${TFMT} '${1}/fdp-info.xml' 'Locale ${1} packaging information'
+
 endef
 
 $(foreach L,${LANGUAGES},$(eval $(call fdp-info_template,${L})))
@@ -443,6 +522,10 @@
 .PHONY:	fdp-info
 
 fdp-info::  $(foreach LANG,${LANGUAGES},$(LANG)/fdp-info.xml)
+
+targets::
+	@printf ${TFMT} 'fdp-info' 'Outputs all locale-specific packaging info'
+
 #
 #########################################################################
 
@@ -457,6 +540,9 @@
 	insert-changelog $(RPMINFO).tmp && 	\
 		move-if-change $(RPMINFO).tmp $(RPMINFO)
 
+targets::
+	@printf ${TFMT} 'clog' 'Adds changelog entry to rpm-info.xml file'
+
 #
 #########################################################################
 # Make a new colophon entry for an existing rpm-info.xml file.
@@ -465,6 +551,8 @@
 	insert-colophon $(RPMINFO).tmp && 	\
 		move-if-change $(RPMINFO).tmp $(RPMINFO)
 
+targets::
+	@printf ${TFMT} 'colophon' 'Adds colophon entry to rpm-info.xml file'
 
 #########################################################################
 .PHONY:	${DOCBASE}-${1}-distclean
@@ -473,6 +561,10 @@
 ${DOCBASE}-$(1)-distclean::
 	${RM} *-$(1).omf
 	${RM} *-$(1).desktop
+
+targets::
+	@printf ${TFMT} '${DOCBASE}-${1}-distclean' 'Removes locale ${1} product files'
+
 endef
 
 $(foreach L,${LANGUAGES},$(eval $(call DISTCLEAN_template,${L})))
@@ -494,36 +586,58 @@
 	${RM} fedora-doc-$(DOCBASE)*.spec
 	${RM} $(DOCBASE)*.src.tar.gz
 
+targets::
+	@printf ${TFMT} 'spec' 'Creates RPM spec file from rpm-info.xml'
+
 spec::	${SPECFILE}
 
+targets::
+	@printf ${TFMT} '${SPECFILE}' 'Creates RPM spec file from rpm-info.xml'
+
 ${SPECFILE}::	${RPMINFO}
 	$(XSLTPROC) --stringparam docbase "${DOCBASE}"			\
 		${FDPDIR}/docs-common/packaging/spec.xsl ${RPMINFO}	\
 		>$@.tmp && move-if-change $@.tmp $@
 
+targets::
+	@printf ${TFMT} 'gnome-desktop' 'Outputs Gnome desktop description'
 
 gnome.desktop::	fedora-doc-${DOCBASE}-gnome.desktop
 
+targets::
+	@printf ${TFMT} 'fedora-doc-${DOCBASE}-gnome.desktop' 'Gnome Desktop Files'
+
 fedora-doc-${DOCBASE}-gnome.desktop:: ${RPMINFO}
 	$(XSLTPROC) --stringparam docbase "${DOCBASE}"			\
 		${FDPDIR}/docs-common/packaging/gnome-desktop.xsl	\
 		${RPMINFO} >$@.tmp && move-if-change $@.tmp $@
 
+targets::
+	@printf ${TFMT} 'kde.desktop' 'Generates KDE desktop files'
+
 kde.desktop::	fedora-doc-${DOCBASE}-kde.desktop
 
+targets::
+	@printf ${TFMT} 'fedora-doc-${DOCBASE}-kde.desktop' 'KDE desktop files'
+
 fedora-doc-${DOCBASE}-kde.desktop:: ${RPMINFO}
 	$(XSLTPROC) --stringparam docbase "${DOCBASE}"			\
 		${FDPDIR}/docs-common/packaging/kde-desktop.xsl 	\
 		${RPMINFO} >$@.tmp && move-if-change $@.tmp $@
 
+targets::
+	@printf ${TFMT} 'khelp.desktop' 'KDE Help desktop files'
+
 khelp.desktop::		fedora-doc-${DOCBASE}-khelp.desktop
 
+targets::
+	@printf ${TFMT} 'fedora-doc-${DOCBASE}-khelp.desktop' 'KDE Help files'
+
 fedora-doc-${DOCBASE}-khelp.desktop:: ${RPMINFO}
 	$(XSLTPROC) --stringparam docbase "${DOCBASE}"			\
 		${FDPDIR}/docs-common/packaging/khelpcenter-plugin.xsl 	\
 		${RPMINFO} >$@.tmp && move-if-change $@.tmp $@
 
-
 define omf_template
 omf-$(1)::	fedora-doc-${DOCBASE}-$(1).omf
 
@@ -533,15 +647,27 @@
 		${FDPDIR}/docs-common/packaging/omf.xsl ${RPMINFO}    |	\
 	$(XMLFORMAT) $(XMLFOPTS) >fedora-doc-${DOCBASE}-$(1).omf.tmp &&	\
 	move-if-change fedora-doc-${DOCBASE}-$(1).omf.tmp fedora-doc-${DOCBASE}-$(1).omf
+
+targets::
+	@printf ${TFMT} 'omf-${1}' 'OMF file for locale ${1}'
+	@printf ${TFMT} 'fedora-doc-${DOCBASE}-${1}.omf' 'OMF file for locale ${1}'
 endef
 
+targets::
+	@printf ${TFMT} 'fedora-doc-${DOCBASE}-C.omf' 'Locale "EN" not the C locale'
+
 fedora-doc-${DOCBASE}-C.omf::	fedora-doc-${DOCBASE}-en.omf
 	cp fedora-doc-$(DOCBASE)-en.omf $@
 
 $(foreach LANG,${LANGUAGES},$(eval $(call omf_template,${LANG})))
 
+targets::
+	@printf ${TFMT} 'omf' 'Generates the OMF files'
+
 omf::  $(foreach LANG,${LANGUAGES},omf-$(LANG)) fedora-doc-${DOCBASE}-C.omf
 
+targets::
+	@printf ${TFMT} 'src-tarball' 'Builds tar(1) archive of sources & desktop files'
 
 src-tarball $(DOCBASE)-$(VERSION).src.tar.gz::
 	${MAKE} fdp-info




More information about the Fedora-docs-commits mailing list