aboutsummaryrefslogtreecommitdiffstats
path: root/make-version.pl
diff options
context:
space:
mode:
authorGerald Combs <gerald@wireshark.org>2006-07-17 18:53:40 +0000
committerGerald Combs <gerald@wireshark.org>2006-07-17 18:53:40 +0000
commit28ee8850214bb3410cacd8844b5a2323cfce79ce (patch)
treee5c7499c2a9bdcdb6d4929953a9583be120fa02c /make-version.pl
parent147ac8b09420ec017256e3c1048c199e65cb1aaf (diff)
Copy over changes from the 0.99.2 branch.
svn path=/trunk/; revision=18752
Diffstat (limited to 'make-version.pl')
-rwxr-xr-xmake-version.pl9
1 files changed, 8 insertions, 1 deletions
diff --git a/make-version.pl b/make-version.pl
index 8a9ce17d12..1b1e439d46 100755
--- a/make-version.pl
+++ b/make-version.pl
@@ -32,6 +32,7 @@
# format - A strftime() formatted string to use as a template for
# the version string. The sequence "%#" will substitute
# the SVN revision number.
+# pkg_enable - Enable or disable package versioning.
# pkg_format - Like "format", but used for the package version.
#
# If run with the "-p" or "--package-version" argument, the
@@ -44,6 +45,7 @@
#
# enable: 1
# format: SVN %Y%m%d%H%M%S
+# pkg_enable: 1
# pkg_format: -SVN-%#
# am_init: 0
@@ -65,6 +67,7 @@ my $pkg_version = 0;
my %version_pref = (
"enable" => 1,
"format" => "SVN %Y%m%d%H%M%S",
+ "pkg_enable" => 1,
"pkg_format" => "-SVN-%#",
);
my $srcdir = ".";
@@ -75,10 +78,14 @@ my $srcdir = ".";
sub read_svn_info {
my $line;
my $version_format = $version_pref{"format"};
- my $package_format = $version_pref{"pkg_format"};
+ my $package_format = "";
my $in_entries = 0;
my $svn_name;
+ if ($version_pref{"pkg_enable"}) {
+ $package_format = $version_pref{"pkg_format"};
+ }
+
if (! open (ENTRIES, "< $srcdir/.svn/entries")) {
print ("Unable to get SVN info.\n");
return;