gnash-commit
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Gnash-commit] /srv/bzr/gnash/trunk r12353: rename the generated bzevers


From: Rob Savoye
Subject: [Gnash-commit] /srv/bzr/gnash/trunk r12353: rename the generated bzeversion.h to revno.h
Date: Thu, 05 Aug 2010 10:54:13 -0600
User-agent: Bazaar (2.0.3)

------------------------------------------------------------
revno: 12353
committer: Rob Savoye <address@hidden>
branch nick: trunk
timestamp: Thu 2010-08-05 10:54:13 -0600
message:
  rename the generated bzeversion.h to revno.h
modified:
  Makefile.am
  cygnal/cygnal.cpp
  gui/gnash.cpp
  packaging/buildhost.exp
  packaging/deb.am
  packaging/debian/rules
  packaging/snapshot.am
  packaging/xpi.am
=== modified file 'Makefile.am'
--- a/Makefile.am       2010-07-15 06:18:47 +0000
+++ b/Makefile.am       2010-08-05 16:54:13 +0000
@@ -100,7 +100,7 @@
        packaging/rpm.am \
        packaging/gnash.xpm \
        packaging/klash.xpm \
-       bzrversion.h
+       revno.h
 
 
 # dist-hook:
@@ -116,33 +116,73 @@
 # and when building binary packages from multiple branches.
 # Note that this is only rebuilt after "make clean", if the Makefile
 # has changed, or the source tree gets reconfigured. So unless you do
-# a make clean, or nuke the bzrversion.h file, this can get slightly
+# a make clean, or nuke the revno.h file, this can get slightly
 # behind the current version. Currently Gnash doesn't have this info
 # so it'll be an improvement anyway. Bzr is amazing slow producing
 # the info, which is why we don't want to do it all the time.
 #
-CLEANFILES += bzrversion.h
-BUILT_SOURCES = bzrversion.h
-bzrversion.h: Makefile.in
-       @status=`which bzr 2>&1 | grep -c " no bz"`; \
-       if test x"$${status}" = x"0"; then \
-          echo "Generating bzrversion.h"; \
-          $(RM) -f bzrversion.h; \
-          revno=`(cd $(srcdir) && bzr revno)`; \
-          nick=`basename $(top_srcdir)`; \
+CLEANFILES += revno.h
+BUILT_SOURCES = revno.h
+revno.h: Makefile.in
+       @echo "Generating revno.h"
+       address@hidden test -d $(srcdir)/.bzr; then \
+         status=`which bzr 2>&1 | grep -c " no bzr"`; \
+         if test x"$${status}" = x"0"; then \
+           echo "Generating revno.h"; \
+           $(RM) -f revno.h; \
+           revno=`(cd $(srcdir) && bzr revno)`; \
+           nick=`basename $(top_srcdir)`; \
+         else \
+           revno="${NOW}"; \
+         fi; \
        else \
-          revno="${NOW}"; \
-          nick="none"; \
+         if test -d $(srcdir)/.git; then \
+            status=`which git 2>&1 | grep -c " no git"`; \
+            if test x"$${status}" = x"0"; then \
+              echo "Generating revno.h"; \
+              $(RM) -f revno.h; \
+              revno=`(cd $(srcdir) && git describe --tags | cut -d '-' -f 
2-3)`; \
+              nick=`basename $(top_srcdir)`; \
+           fi; \
+          else \
+            revno="${NOW}"; \
+            nick="none"; \
+         fi; \
        fi; \
-       echo "Generating bzrversion.h"; \
-       echo "static const char *BRANCH_REVNO  = \"$${revno}\";" > 
bzrversion.h; \
-       echo "static const char *BRANCH_NICK = \"$${nick}\";" >> bzrversion.h;
+       echo "static const char *BRANCH_REVNO  = \"$${revno}\";" > revno.h; \
+       echo "static const char *BRANCH_NICK = \"$${nick}\";" >> revno.h;
 
 # The branch nickname and revision number must be set before including
 # the other Makefile fragments used for package building, as they use
 # these values.
-BRANCH_REVNO  := $(shell grep "REVNO" bzrversion.h | cut -d '"' -f 2)
-BRANCH_NICK   := $(shell grep "NICK" bzrversion.h | cut -d '"' -f 2)
+BRANCH_REVNO  := $(shell grep "REVNO" revno.h | cut -d '"' -f 2)
+BRANCH_NICK   := $(shell grep "NICK" revno.h | cut -d '"' -f 2)
+
+
+# Extract info from the repository to include in the build. If
+# GIT (git) isn't installed, just print stubs, as this is only
+# used for display purposes. It's primarily used by the testsuites
+# and when building binary packages from multiple branches.
+# Note that this is only rebuilt after "make clean", if the Makefile
+# has changed, or the source tree gets reconfigured. So unless you do
+# a make clean, or nuke the revno.h file, this can get slightly
+# behind the current version. Currently Gnash doesn't have this info
+# so it'll be an improvement anyway. 
+
+revno.h: Makefile.in
+        @status=`which git 2>&1 | grep -c " no bzr"`; \
+        if test x"$${status}" = x"0"; then \
+           echo "Generating revno.h"; \
+           $(RM) -f revno.h; \
+           revno=`(cd $(srcdir) && git describe --tags | cut -d '-' -f 2-3)`; \
+           nick=`basename $(top_srcdir)`; \
+        else \
+           revno="${NOW}"; \
+           nick="none"; \
+        fi; \
+        echo "Generating revno.h"; \
+        echo "static const char *BRANCH_REVNO  = \"$${revno}\";" > revno.h; \
+        echo "static const char *BRANCH_NICK = \"$${nick}\";" >> revno.h;
 
 #
 # Precompiled header support

=== modified file 'cygnal/cygnal.cpp'
--- a/cygnal/cygnal.cpp 2010-05-27 22:44:28 +0000
+++ b/cygnal/cygnal.cpp 2010-08-05 16:54:13 +0000
@@ -35,7 +35,7 @@
 #include <fcntl.h>
 
 #include "GnashSleep.h"
-#include "bzrversion.h"
+#include "revno.h"
 
 //#include "cvm.h"
 

=== modified file 'gui/gnash.cpp'
--- a/gui/gnash.cpp     2010-07-19 07:03:02 +0000
+++ b/gui/gnash.cpp     2010-08-05 16:54:13 +0000
@@ -40,7 +40,7 @@
 #include "arg_parser.h"
 #include "GnashNumeric.h" // for clamp
 #include "GnashException.h"
-#include "bzrversion.h"
+#include "revno.h"
 #include "MediaHandler.h"
 
 #ifdef HAVE_FFMPEG_AVCODEC_H

=== modified file 'packaging/buildhost.exp'
--- a/packaging/buildhost.exp   2010-02-27 00:42:41 +0000
+++ b/packaging/buildhost.exp   2010-08-05 16:54:13 +0000
@@ -544,7 +544,7 @@
 proc bzr_revno {} {
     global inp outp timeout objdir
     changedir $objdir
-    set ret [local_exec "grep REVNO bzrversion.h" $inp $outp $timeout]
+    set ret [local_exec "grep REVNO revno.h" $inp $outp $timeout]
     set status [lindex $ret 0]
     set output [lindex $ret 1]
 
@@ -565,7 +565,7 @@
 proc bzr_branch {} {
     global inp outp timeout verbose srcdir objdir
     changedir $objdir
-    set ret [local_exec "grep NICK bzrversion.h" $inp $outp $timeout]
+    set ret [local_exec "grep NICK revno.h" $inp $outp $timeout]
     incr verbose
     set status [lindex $ret 0]
     set output [lindex $ret 1]

=== modified file 'packaging/deb.am'
--- a/packaging/deb.am  2010-04-08 22:50:08 +0000
+++ b/packaging/deb.am  2010-08-05 16:54:13 +0000
@@ -17,7 +17,7 @@
 
 # Build a Debian/Ubuntu .deb GNU/Linux package
 
-deb: bzrversion.h snapshot-src setup-deb snapshot-deb
+deb: revno.h snapshot-src setup-deb snapshot-deb
 
 # Build a .deb snapshot, which means we have to munge the release data
 # into the proper files to build a package with the version in

=== modified file 'packaging/debian/rules'
--- a/packaging/debian/rules    2010-07-10 04:01:46 +0000
+++ b/packaging/debian/rules    2010-08-05 16:54:13 +0000
@@ -328,8 +328,8 @@
        dh_builddeb
 
 VERSION_DATE = $(shell /bin/date --utc +%0Y%0m%0d.%0k%0M)
-BRANCH_NICK   = `grep "NICK" $(BUILD_DIRECTORY)/bzrversion.h | cut -d '"' -f 2`
-BRANCH_REVNO  = `grep "REVNO" $(BUILD_DIRECTORY)/bzrversion.h | cut -d '"' -f 
2`
+BRANCH_NICK   = `grep "NICK" $(BUILD_DIRECTORY)/revno.h | cut -d '"' -f 2`
+BRANCH_REVNO  = `grep "REVNO" $(BUILD_DIRECTORY)/revno.h | cut -d '"' -f 2`
 #VERSION_ID = 0.8.8+bzr.trunk$(VERSION_DATE)
 VERSION_ID = 0.8.8+bzr.$(BRANCH_NICK)$(BRANCH_REVNO)
 get-bzr-source:

=== modified file 'packaging/snapshot.am'
--- a/packaging/snapshot.am     2010-07-10 04:01:46 +0000
+++ b/packaging/snapshot.am     2010-08-05 16:54:13 +0000
@@ -47,7 +47,7 @@
 # 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: bzrversion.h distdir
+snapshot-src: revno.h distdir
 
 snapshot-configure:
        address@hidden "+%Y%m%d"`; \

=== modified file 'packaging/xpi.am'
--- a/packaging/xpi.am  2010-01-01 17:48:26 +0000
+++ b/packaging/xpi.am  2010-08-05 16:54:13 +0000
@@ -60,7 +60,7 @@
          --enable-static \
          --disable-shared \
          $(CONFIG_OPTS));
-       -cp bzrversion.h $(SNAPSHOT_BUILD)
+       -cp revno.h $(SNAPSHOT_BUILD)
 
 # build the xpi package bundle. snapshot-build and snapshot-install need to
 # have been run already. If you wish the automatic dependency checking, use


reply via email to

[Prev in Thread] Current Thread [Next in Thread]