summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPaul W. Frields <stickster@gmail.com>2006-08-05 04:39:18 +0000
committerPaul W. Frields <stickster@gmail.com>2006-08-05 04:39:18 +0000
commit1c80de2578c8048d4620fc29c8b50c084878a3cb (patch)
treee0ac80321214fcf3c77d7dc99cbefd7c1e851f15
parentfb387afbe60d404c090df24a05d08b6892b2d95a (diff)
downloadfedora-doc-utils-1c80de2578c8048d4620fc29c8b50c084878a3cb.tar.gz
fedora-doc-utils-1c80de2578c8048d4620fc29c8b50c084878a3cb.tar.xz
fedora-doc-utils-1c80de2578c8048d4620fc29c8b50c084878a3cb.zip
The whole section on tagging and assigning NVR stuff should come afterdocs-common-relangify-rpminfo
the first TARGETS assignment. (Just like it says, right there.)
-rw-r--r--Makefile.common125
1 files changed, 63 insertions, 62 deletions
diff --git a/Makefile.common b/Makefile.common
index 020d348..d994019 100644
--- a/Makefile.common
+++ b/Makefile.common
@@ -173,68 +173,6 @@ endif
#########################################################################
#########################################################################
-# Obtain the document version and release info for building RPM's
-SPECFILE=$(firstword $(wildcard *.spec))
-
-ifneq "${SPECFILE}" ""
-# the name of the package
-ifndef NAME
-NAME := $(shell rpm ${RPMFLAGS} ${DISTRPMFLAGS} -q --qf "%{NAME}\n" \
- --specfile ${SPECFILE} | head -1)
-endif
-# the version of the package
-ifndef VERSION
-VERSION := $(shell rpm ${RPMFLAGS} ${DISTRPMFLAGS} -q --qf "%{VERSION}\n" \
- --specfile ${SPECFILE} | head -1)
-endif
-# the release of the package
-ifndef RELEASE
-RELEASE := $(shell rpm ${RPMFLAGS} ${DISTRPMFLAGS} -q --qf "%{RELEASE}\n" \
- --specfile ${SPECFILE} | head -1)
-endif
-
-# CVS-safe version/release -- a package name like 4Suite screws things
-# up, so we have to remove the leaving digits from the name
-TAG_NAME := $(shell echo ${NAME} | sed -e s/\\\./_/g -e s/^[0-9]\\\+//g)
-TAG_VERSION := $(shell echo ${VERSION} | sed s/\\\./_/g)
-TAG_RELEASE := $(shell echo ${RELEASE} | sed s/\\\./_/g)
-
-# tag to export, defaulting to current tag in the spec file
-TAG?=${TAG_NAME}-${TAG_VERSION}-${TAG_RELEASE}
-
-# The rest of this rule is set outside the ifneq
-.PHONY: tag
-tag:: ${SPECFILE}
-
-endif # ifneq "${SPECFILE}" ""
-
-# Only set tag here if not done already (i.e. SPECFILE doesn't exist)
-# Use the FDPSH function to get a current version. Keep in mind this
-# will prevent repetitive tagging without the user making use of
-# TAG_OPTS. I'd say that encourages people to Do The Right Thing by
-# changing version numbers where necessary. (PWF)
-TAG_NAME ?= $(shell echo ${DOCBASE} | sed -e s/\\\./_/g -e s/^[0-9]\\\+//g)
-TAG_VERSION ?= $(shell version doc | sed s/\\\./_/g)
-TAG?=${TAG_NAME}-${TAG_VERSION}
-
-tag::
- cvs tag ${TAG_OPTS} -c ${TAG}
- @echo "Tagged with: ${TAG}"
- @echo
-
-showvars::
- @echo "TAG_NAME=${TAG_NAME}"
- @echo "TAG_VERSION=${TAG_VERSION}"
- @echo "TAG_RELEASE=${TAG_RELEASE}"
- @echo "TAG=${TAG}"
- @echo "### (Tag vars do not necessarily reflect CVS status)"
-
-help::
- @printf ${TFMT} 'tag' 'Tag this directory with the packaging NVR'
-
-#########################################################################
-
-#########################################################################
# Set a provisional ${LANG} value. We'll dynamically change this as
# needed. The "${PRI_LANG}" value is used because that is the original
# language the doc.
@@ -316,6 +254,69 @@ distclean:: clean
#########################################################################
#########################################################################
+# Obtain the document version and release info for building RPM's
+SPECFILE=$(firstword $(wildcard *.spec))
+
+ifneq "${SPECFILE}" ""
+# the name of the package
+ifndef NAME
+NAME := $(shell rpm ${RPMFLAGS} ${DISTRPMFLAGS} -q --qf "%{NAME}\n" \
+ --specfile ${SPECFILE} | head -1)
+endif
+# the version of the package
+ifndef VERSION
+VERSION := $(shell rpm ${RPMFLAGS} ${DISTRPMFLAGS} -q --qf "%{VERSION}\n" \
+ --specfile ${SPECFILE} | head -1)
+endif
+# the release of the package
+ifndef RELEASE
+RELEASE := $(shell rpm ${RPMFLAGS} ${DISTRPMFLAGS} -q --qf "%{RELEASE}\n" \
+ --specfile ${SPECFILE} | head -1)
+endif
+
+# CVS-safe version/release -- a package name like 4Suite screws things
+# up, so we have to remove the leaving digits from the name
+TAG_NAME := $(shell echo ${NAME} | sed -e s/\\\./_/g -e s/^[0-9]\\\+//g)
+TAG_VERSION := $(shell echo ${VERSION} | sed s/\\\./_/g)
+TAG_RELEASE := $(shell echo ${RELEASE} | sed s/\\\./_/g)
+
+# tag to export, defaulting to current tag in the spec file
+TAG?=${TAG_NAME}-${TAG_VERSION}-${TAG_RELEASE}
+
+# The rest of this rule is set outside the ifneq
+.PHONY: tag
+tag:: ${SPECFILE}
+ @:
+
+endif # ifneq "${SPECFILE}" ""
+
+# Only set tag here if not done already (i.e. SPECFILE doesn't exist)
+# Use the FDPSH function to get a current version. Keep in mind this
+# will prevent repetitive tagging without the user making use of
+# TAG_OPTS. I'd say that encourages people to Do The Right Thing by
+# changing version numbers where necessary. (PWF)
+TAG_NAME ?= $(shell echo ${DOCBASE} | sed -e s/\\\./_/g -e s/^[0-9]\\\+//g)
+TAG_VERSION ?= $(shell version doc | sed s/\\\./_/g)
+TAG?=${TAG_NAME}-${TAG_VERSION}
+
+tag::
+ cvs tag ${TAG_OPTS} -c ${TAG}
+ @echo "Tagged with: ${TAG}"
+ @echo
+
+showvars::
+ @echo "TAG_NAME=${TAG_NAME}"
+ @echo "TAG_VERSION=${TAG_VERSION}"
+ @echo "TAG_RELEASE=${TAG_RELEASE}"
+ @echo "TAG=${TAG}"
+ @echo "### (Tag vars do not necessarily reflect CVS status)"
+
+help::
+ @printf ${TFMT} 'tag' 'Tag this directory with the packaging NVR'
+
+#########################################################################
+
+#########################################################################
# Rules to generate the "${LANG}/${DOC_ENTITIES}.ent" file, if used
define DOC_ENTITIES_template