Add --epoch option.
This commit is contained in:
1 parent
972c700e29
commit
2ccb07fad3
2 files changed
+15
-1
No files matched your search
@@ -2,6 +2,7 @@
|
|||||||
|
|
||||||
* Fix $summary modification.
|
* Fix $summary modification.
|
||||||
* Strip leading [Vv]\.? from spec Version.
|
* Strip leading [Vv]\.? from spec Version.
|
||||||
|
* Add --epoch option.
|
||||||
|
|
||||||
1.65 2006-04-26
|
1.65 2006-04-26
|
||||||
|
|
||||||
|
|||||||
@@ -10,7 +10,7 @@
|
|||||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
||||||
#
|
#
|
||||||
# $Id: cpanspec,v 1.24 2006/05/05 22:01:04 stevenpritchard Exp $
|
# $Id: cpanspec,v 1.25 2006/05/15 23:32:46 stevenpritchard Exp $
|
||||||
|
|
||||||
our $NAME="cpanspec";
|
our $NAME="cpanspec";
|
||||||
our $VERSION='1.66';
|
our $VERSION='1.66';
|
||||||
@@ -31,6 +31,7 @@ cpanspec [options] [file [...]]
|
|||||||
--force -f Force overwriting existing spec
|
--force -f Force overwriting existing spec
|
||||||
--packager -p Name and email address of packager (for changelog)
|
--packager -p Name and email address of packager (for changelog)
|
||||||
--release -r Release of package (defaults to 1)
|
--release -r Release of package (defaults to 1)
|
||||||
|
--epoch -e Epoch of package
|
||||||
--disttag -d Disttag (defaults to %{?dist})
|
--disttag -d Disttag (defaults to %{?dist})
|
||||||
--srpm -s Build a source rpm
|
--srpm -s Build a source rpm
|
||||||
--build -b Build source and binary rpms
|
--build -b Build source and binary rpms
|
||||||
@@ -109,6 +110,11 @@ macro in C<~/.rpmmacros>.
|
|||||||
|
|
||||||
The release number of the package. Defaults to 1.
|
The release number of the package. Defaults to 1.
|
||||||
|
|
||||||
|
=item B<-e>, B<--epoch>
|
||||||
|
|
||||||
|
The epoch number of the package. By default, this is undefined, so
|
||||||
|
no epoch will be used in the generated spec.
|
||||||
|
|
||||||
=item B<-d>, B<--disttag>
|
=item B<-d>, B<--disttag>
|
||||||
|
|
||||||
Disttag (a string to append to the release number), used to
|
Disttag (a string to append to the release number), used to
|
||||||
@@ -200,6 +206,7 @@ our $noprefix=0;
|
|||||||
our $force=0;
|
our $force=0;
|
||||||
our $packager;
|
our $packager;
|
||||||
our $release=1;
|
our $release=1;
|
||||||
|
our $epoch;
|
||||||
our $disttag='%{?dist}';
|
our $disttag='%{?dist}';
|
||||||
our $buildsrpm=0;
|
our $buildsrpm=0;
|
||||||
our $buildrpm=0;
|
our $buildrpm=0;
|
||||||
@@ -443,6 +450,7 @@ GetOptions(
|
|||||||
'force|f' => \$force,
|
'force|f' => \$force,
|
||||||
'packager|p=s' => \$packager,
|
'packager|p=s' => \$packager,
|
||||||
'release|r=i' => \$release,
|
'release|r=i' => \$release,
|
||||||
|
'epoch|e=i' => \$epoch,
|
||||||
'disttag|d=s' => \$disttag,
|
'disttag|d=s' => \$disttag,
|
||||||
'srpm|s' => \$buildsrpm,
|
'srpm|s' => \$buildsrpm,
|
||||||
'build|b' => \$buildrpm,
|
'build|b' => \$buildrpm,
|
||||||
@@ -788,6 +796,11 @@ for my $file (@ARGV) {
|
|||||||
Name: $prefix$name
|
Name: $prefix$name
|
||||||
Version: $packageversion
|
Version: $packageversion
|
||||||
Release: $release$disttag
|
Release: $release$disttag
|
||||||
|
END
|
||||||
|
|
||||||
|
print $spec "Epoch: $epoch\n" if (defined($epoch));
|
||||||
|
|
||||||
|
print $spec <<END;
|
||||||
Summary: $summary
|
Summary: $summary
|
||||||
License: $license
|
License: $license
|
||||||
Group: Development/Libraries
|
Group: Development/Libraries
|
||||||
|
|||||||
Reference in new issue
Block a user