X Strike Force X.Org X11 SVN commit: r839 - trunk/xsfbs
Author: dnusinow
Date: 2005-11-04 17:15:28 -0500 (Fri, 04 Nov 2005)
New Revision: 839
Modified:
trunk/xsfbs/xsfbs.mk
Log:
Fix up xsfbs make-orig-tar-gz to properly hack off the epoch
Modified: trunk/xsfbs/xsfbs.mk
===================================================================
--- trunk/xsfbs/xsfbs.mk 2005-11-04 05:18:02 UTC (rev 838)
+++ trunk/xsfbs/xsfbs.mk 2005-11-04 22:15:28 UTC (rev 839)
@@ -35,6 +35,9 @@
# Determine upstream version number.
UPSTREAM_VERSION:=$(shell echo $(SOURCE_VERSION) | sed 's/-.*//')
+# Determine the source version without the epoch for make-orig-tar-gz
+NO_EPOCH_VER:=$(shell echo $(UPSTREAM_VERSION) | sed 's/^.://')
+
# Figure out who's building this package.
BUILDER:=$(shell echo $${DEBEMAIL:-$${EMAIL:-$$(echo $$LOGNAME@$$(cat /etc/mailname 2>/dev/null))}})
@@ -43,6 +46,9 @@
# version number. Anything else indicates an unofficial build.
OFFICIAL_BUILD:=$(shell VERSION=$(SOURCE_VERSION); if ! expr "$$(echo $${VERSION\#\#*-} | sed 's/\(woody\|sarge\)//g')" : ".*[^0-9.].*" >/dev/null 2>&1; then echo yes; fi)
+# Figure out where we're building the package for make-orig-tar-gz target
+CURDIR:=$(shell basename `pwd`)
+
# Set up parameters for the Debian build environment.
# Determine our architecture.
@@ -163,31 +169,9 @@
echo "nothing to do."; \
fi
-# Populate the source tree $(SOURCE_TREE) and do other housekeeping to prepare
-# for the upstream build.
-.PHONY: setup
-stampdir_targets+=setup
-setup: $(STAMP_DIR)/setup
-$(STAMP_DIR)/setup: $(STAMP_DIR)/patch
- mkdir -p $(SOURCE_DIR)
- find . -maxdepth 1 -mindepth 1 ! -name $(SOURCE_DIR) \
- -a ! -name debian -a ! -name patches -a ! -name .pc \
- -a ! -name stampdir | xargs -i{} cp -al {} $(SOURCE_DIR)
- >$@
-
-# Clean the generated maintainer scripts.
-.PHONY: cleanscripts
-cleanscripts:
- rm -f $(STAMP_DIR)/genscripts
- rm -f debian/*.config \
- debian/*.postinst \
- debian/*.postrm \
- debian/*.preinst \
- debian/*.prerm
-
# Clean the package build tree.
.PHONY: xsfclean
-xsfclean: unpatch cleanscripts
+xsfclean: unpatch
dh_testdir
rm -f .pc patches
rm -rf $(STAMP_DIR) $(SOURCE_DIR)
@@ -196,41 +180,6 @@
debian/MANIFEST.$(ARCH) debian/MANIFEST.$(ARCH).new \
debian/po/pothead
-# Generate the maintainer scripts.
-.PHONY: genscripts
-stampdir_targets+=genscripts
-genscripts: $(STAMP_DIR)/genscripts
-$(STAMP_DIR)/genscripts: $(STAMP_DIR)/stampdir
- for FILE in debian/*.config.in \
- debian/*.postinst.in \
- debian/*.postrm.in \
- debian/*.preinst.in \
- debian/*.prerm.in; do \
- if [ -e "$$FILE" ]; then \
- MAINTSCRIPT=$$(echo $$FILE | sed 's/.in$$//'); \
- sed -n '1,/^#INCLUDE_SHELL_LIB#$$/p' <$$FILE \
- | sed -e '/^#INCLUDE_SHELL_LIB#$$/d' >$$MAINTSCRIPT.tmp; \
- cat debian/shell-lib.sh >>$$MAINTSCRIPT.tmp; \
- sed -n '/^#INCLUDE_SHELL_LIB#$$/,$$p' <$$FILE \
- | sed -e '/^#INCLUDE_SHELL_LIB#$$/d' >>$$MAINTSCRIPT.tmp; \
- sed -e 's/@SOURCE_VERSION@/$(SOURCE_VERSION)/' \
- -e 's/@OFFICIAL_BUILD@/$(OFFICIAL_BUILD)/' \
- <$$MAINTSCRIPT.tmp >$$MAINTSCRIPT; \
- rm $$MAINTSCRIPT.tmp; \
- fi; \
- done
- # Validate syntax of generated shell scripts.
- sh debian/scripts/validate-posix-sh debian/*.config \
- debian/*.postinst \
- debian/*.postrm \
- debian/*.preinst \
- debian/*.prerm
- >$@
-
-# Generate the shlibs.local file.
-debian/shlibs.local:
- cat debian/*.shlibs >$@
-
# Generate the debconf templates POT file header.
debian/po/pothead: debian/po/pothead.in
sed -e 's/SOURCE_VERSION/$(SOURCE_VERSION)/' \
@@ -316,16 +265,15 @@
# for the rare situations when one is needed.
.PHONY: make-orig-tar-gz
make-orig-tar-gz: clean prune-upstream-tree
- CURDIR=$(shell basename `pwd`)
( cd .. \
- && if [ $(CURDIR) != $(SOURCE_NAME)-$(UPSTREAM_VERSION) ]; then \
+ && if [ $(CURDIR) != $(SOURCE_NAME)-$(NO_EPOCH_VER) ]; then \
echo "Our current working directory has the wrong name. Renaming..." >&2; \
- mv $(CURDIR) $(SOURCE_NAME)-$(UPSTREAM_VERSION); \
+ mv $(CURDIR) $(SOURCE_NAME)-$(NO_EPOCH_VER); \
fi; \
tar --exclude=debian --exclude=debian/* \
--exclude=.svn --exclude=.svn/* \
- -cf - $(SOURCE_NAME)-$(UPSTREAM_VERSION) \
- | gzip -9 >$(SOURCE_NAME)_$(UPSTREAM_VERSION).orig.tar.gz; \
+ -cf - $(SOURCE_NAME)-$(NO_EPOCH_VER) \
+ | gzip -9 >$(SOURCE_NAME)_$(NO_EPOCH_VER).orig.tar.gz; \
)
# Verify that there are no offsets or fuzz in the patches we apply.
Reply to: