[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Gnash-commit] /srv/bzr/gnash/trunk r11921: modify the snapshot and rpm
From: |
Rob Savoye |
Subject: |
[Gnash-commit] /srv/bzr/gnash/trunk r11921: modify the snapshot and rpm package building to use a similar versioning scheme as Debian, so upgrades work when comparing versions. |
Date: |
Mon, 08 Feb 2010 10:47:22 -0700 |
User-agent: |
Bazaar (2.0.3) |
------------------------------------------------------------
revno: 11921
committer: Rob Savoye <address@hidden>
branch nick: trunk
timestamp: Mon 2010-02-08 10:47:22 -0700
message:
modify the snapshot and rpm package building to use a similar versioning
scheme as Debian, so upgrades work when comparing versions.
modified:
packaging/deb.am
packaging/debian/rules
packaging/redhat/gnash.spec
packaging/rpm.am
packaging/snapshot.am
=== modified file 'packaging/deb.am'
--- a/packaging/deb.am 2010-02-04 04:39:49 +0000
+++ b/packaging/deb.am 2010-02-08 17:47:22 +0000
@@ -31,8 +31,18 @@
# for the correct browser.
setup-deb:
snapshot_dir="gnash-$(SNAPSHOT_VERSION)"; \
- if test -d $(SNAPSHOT_DIR); then \
- mv $(SNAPSHOT_DIR) $${snapshot_dir}; \
+ if test -d gnash-trunk; then \
+ mv gnash-trunk $${snapshot_dir}; \
+ fi; \
+ if test ! -f $(SNAPSHOT_DIR)/configure.ac.orig; then \
+ mv -f $(SNAPSHOT_DIR)/configure.ac $(SNAPSHOT_DIR)/configure.ac.orig;
\
+ sed -e "s/AC_INIT(gnash, trunk)/AC_INIT(gnash,
$${snapshot_version})/" \
+ $(SNAPSHOT_DIR)/configure.ac.orig > $(SNAPSHOT_DIR)/configure.ac; \
+ fi; \
+ if test ! -f $(SNAPSHOT_DIR)/configure.orig; then \
+ mv -f $(SNAPSHOT_DIR)/configure $(SNAPSHOT_DIR)/configure.orig; \
+ sed -e "s/ VERSION='trunk'/ VERSION='$${snapshot_version}'/" \
+ $(SNAPSHOT_DIR)/configure.orig > $(SNAPSHOT_DIR)/configure; \
fi; \
mkdir -p $${snapshot_dir}/debian; \
cp -rfp $(srcdir)/packaging/debian/* $${snapshot_dir}/debian/; \
=== modified file 'packaging/debian/rules'
--- a/packaging/debian/rules 2010-02-07 22:02:19 +0000
+++ b/packaging/debian/rules 2010-02-08 17:47:22 +0000
@@ -221,4 +221,4 @@
binary: binary-indep binary-arch
-.PHONY: build clean binary-indep binary-arch binary install get-bzr-source
+.PHONY: config build clean binary-indep binary-arch binary install
get-bzr-source patch
\ No newline at end of file
=== modified file 'packaging/redhat/gnash.spec'
--- a/packaging/redhat/gnash.spec 2010-01-21 01:29:33 +0000
+++ b/packaging/redhat/gnash.spec 2010-02-08 17:47:22 +0000
@@ -1,6 +1,6 @@
Name: gnash
-Version: 20100117
-Release: 1
+Version: trunk
+Release: 0
Distribution: fc12
#Distribution: ydl6
Summary: GNU SWF player
@@ -184,7 +184,7 @@
# shell, but sometimes that's what you need to do.
# export CONFIG_SHELL="sh -x"
# sh -x ./configure
-./configure \
+sh ./configure \
$CROSS_OPTS \
$SOUND $GUI \
$RENDERER \
=== modified file 'packaging/rpm.am'
--- a/packaging/rpm.am 2010-02-07 23:26:43 +0000
+++ b/packaging/rpm.am 2010-02-08 17:47:22 +0000
@@ -25,11 +25,10 @@
RPMBUILD_FLAGS = # --clean --rmsource --rmspec
gnash.spec spec: $(srcdir)/packaging/redhat/gnash.spec
- @nick=$(BRANCH_NICK); \
- revno=$(BRANCH_REVNO); \
- version=$${nick}$${revno}; \
- echo "Editing the version in the spec file to be $${version}..."; \
- sed -e "s/Version.*/Version: $${version}/"
$(srcdir)/packaging/redhat/gnash.spec > gnash.spec;
+ snapshot_version="$(SNAPSHOT_VERSION)"; \
+ snapshot_version=`echo $${snapshot_version}|tr "~" "_"`; \
+ echo "Editing the version in the spec file to be
$${snapshot_version}..."; \
+ sed -e "s/Version.*/Version: $${snapshot_version}/"
$(srcdir)/packaging/redhat/gnash.spec > gnash.spec;
# Build an Redhat/Fedora .rpm package
# We do this by using the source snapshot that we know is 'distclean'.
@@ -40,7 +39,7 @@
# instead, so now you don't have to be root to build rpm packages.
# Do the entire process to build an RPM package
-rpm: spec snapshot-src rpm-setup rpm-gnash
+rpm: spec snapshot-src setup-rpm rpm-gnash
# build everything in one pass using rpmbuild
rpm-gnash:
@@ -61,13 +60,33 @@
rpm-install:
rpmbuild -bi --short-circuit $(RPMBUILD_FLAGS) gnash.spec
-rpm-setup:
- cp $(SNAPSHOT_TAR) $${HOME}/rpmbuild/SOURCES/$(SNAPSHOT_DIR).tar.gz
-
-# build klash and the konqueror plugin as a sepaate step.
-rpm-klash:
- rpmbuild -ba $(RPMBUILD_FLAGS) glash.spec
-
-.PHONY : rpm redhat rpm-klash spec rpm-configure rpm-install rpm-build
rpm-setup
-
-
+# After distdir is done, all we have is an empty subdirectory
+# populated from the *_DIST variables used by Automake. RPM and Deb
+# naming conventions are similar, but just different enough that the
+# source directory and tarball names are subtely different, namely
+# Debian uses a '~' character in their version names, which rpmbuild
+# doesn't like, so for an RPM we convert it to a '_' instead. Then we
+# have to rename the subdirectory to match the new version of the
+# snapshot, and edit the configure* files to have the proper version
+# name.
+# Unlike creating a deb, which build their own source tarball, rpm
+# requires we do it ourselves, and copy it to $HOME/rpmbuild/SOURCES
+# before rpmbuild will work.
+setup-rpm:
+ snapshot_version="gnash-$(SNAPSHOT_VERSION)"; \
+ snapshot_version=`echo $${snapshot_version}|tr "~" "_"`; \
+ if test -d gnash-trunk; then \
+ mv gnash-trunk $${snapshot_version}; \
+ if test ! -f $${snapshot_version}/configure.ac.orig; then \
+ mv -f $${snapshot_version}/configure.ac
$${snapshot_version}/configure.ac.orig; \
+ sed -e "s/AC_INIT(gnash, trunk)/AC_INIT(gnash,
$${snapshot_version})/" \
+ $${snapshot_version}/configure.ac.orig >
$${snapshot_version}/configure.ac; \
+ fi; \
+ fi; \
+ tar zcf $${snapshot_version}.tar.gz \
+ --exclude=$${snapshot_version}/autom4te.cache \
+ --exclude=$${snapshot_version}/configure.ac.orig \
+ --exclude=$${snapshot_version}/configure.orig $${snapshot_version}; \
+ cp $${snapshot_version}.tar.gz $${HOME}/rpmbuild/SOURCES/
+
+.PHONY : rpm redhat spec rpm-configure rpm-install rpm-build setup-rpm
=== modified file 'packaging/snapshot.am'
--- a/packaging/snapshot.am 2010-02-04 02:03:00 +0000
+++ b/packaging/snapshot.am 2010-02-08 17:47:22 +0000
@@ -47,27 +47,14 @@
# Do the entire process to build a binary tarball
snapshot: snapshot-src snapshot-configure snapshot-build snapshot-install
snapshot-bundle
-# start by creating the initial tarball using the dist-bzip2 target.
-# This uses the default version for Gnash. which is 'trunk'. So we
-# rename it to the dir we want to stay clear. Then we change the default
-# version from 'trunk' to a date stamped version of trunk.
-snapshot-src: distdir force
- snapshot_tar="$(SNAPSHOT_TAR)"; \
- snapshot_dir="$(SNAPSHOT_DIR)"; \
- if test -d $${snapshot_dir}; then \
- rm -fr $${snapshot_dir}; \
- fi; \
- mv -f gnash-trunk $${snapshot_dir}; \
- if test ! -f $${snapshot_dir}/configure.ac.orig; then \
- mv -f $${snapshot_dir}/configure.ac
$${snapshot_dir}/configure.ac.orig; \
- sed -e "s/AC_INIT(gnash, trunk)/AC_INIT(gnash,
$(BRANCH_NICK)$(BRANCH_REVNO))/" \
- $${snapshot_dir}/configure.ac.orig > $${snapshot_dir}/configure.ac;
\
- fi; \
- tar zcvf $${snapshot_tar} --exclude=$${snapshot_dir}/autom4te.cache \
- --exclude=$${snapshot_dir}/configure.ac.orig $${snapshot_dir}
-# cd $${snapshot_dir} ; ./autogen.sh; cd .. ;
+# start by creating the source tree using the distdir target,
+# which builds a source tree only using what's in the DIST variables
+# from Automake. This uses the default version for Gnash. which is
+# 'trunk'. Then it gets renamed from the default version from 'trunk'
+# to a branch-revno stamped version instead of trunk.
+snapshot-src: distdir
-snapshot-configure: force
+snapshot-configure:
address@hidden "+%Y%m%d"`; \
pkgname="gnash-$(BRANCH_NICK)-${BRANCH_REVNO}"; \
snapshot_dir=$(SNAPSHOT_DIR); \
@@ -125,9 +112,8 @@
strip $${snapshot_tmp}/bin/rtmpget; \
tar zcvCf /tmp $${snapshot_tar} $(SNAPSHOT_NAME)
-
snapshot-clean:
address@hidden -fr snapshot-* $(SNAPSHOT_BUILD) $(SNAPSHOT_TMP)
gnash*$(VERSION)*.ipk
-.PHONY : snapshot snapshot-build snapshot-install snapshot-clean snapshot-src
+.PHONY : snapshot snapshot-build snapshot-install snapshot-clean snapshot-src
snapshot-configure
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Gnash-commit] /srv/bzr/gnash/trunk r11921: modify the snapshot and rpm package building to use a similar versioning scheme as Debian, so upgrades work when comparing versions.,
Rob Savoye <=