mirror of
https://github.com/Project-OSS-Revival/alien.git
synced 2026-04-24 14:00:17 +00:00
releasing version 8.48
This commit is contained in:
@@ -346,35 +346,23 @@ sub build {
|
|||||||
my $buildcmd=shift || 'rpmbuild';
|
my $buildcmd=shift || 'rpmbuild';
|
||||||
my $dir=$this->unpacked_tree || die "The package must be unpacked first!";
|
my $dir=$this->unpacked_tree || die "The package must be unpacked first!";
|
||||||
|
|
||||||
# Ask rpm how it's set up. We want to know what architecture it
|
# Ask rpm how it's set up. We want to know where it will place rpms.
|
||||||
# will output, and where it will place rpms.
|
my $rpmdir;
|
||||||
my ($rpmarch, $rpmdir);
|
|
||||||
foreach ($this->runpipe("rpm --showrc")) {
|
foreach ($this->runpipe("rpm --showrc")) {
|
||||||
chomp;
|
chomp;
|
||||||
if (/^build arch\s+:\s(.*)$/) {
|
if (/^rpmdir\s+:\s(.*)$/) {
|
||||||
$rpmarch=$1;
|
|
||||||
}
|
|
||||||
elsif (/^rpmdir\s+:\s(.*)$/) {
|
|
||||||
$rpmdir=$1;
|
$rpmdir=$1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (!$rpmarch) {
|
|
||||||
die "rpm --showrc failed";
|
|
||||||
}
|
|
||||||
|
|
||||||
# Debian's "all" architecture is a special case, and the output rpm
|
my $rpm=$this->name."-".$this->version."-".$this->release.".".$this->arch.".rpm";
|
||||||
# will be a noarch rpm.
|
|
||||||
$rpmarch='noarch' if $this->arch eq 'all';
|
|
||||||
|
|
||||||
my $rpm=$this->name."-".$this->version."-".$this->release.".$rpmarch.rpm";
|
|
||||||
my $opts='';
|
my $opts='';
|
||||||
if ($rpmdir) {
|
if ($rpmdir) {
|
||||||
# Old versions of rpm toss it off in the middle of nowhere.
|
# Old versions of rpm toss it off in the middle of nowhere.
|
||||||
$rpm="$rpmdir/$rpmarch/$rpm";
|
$rpm="$rpmdir/".$this->arch."/$rpm";
|
||||||
|
|
||||||
# This is the old command line argument to make noarch
|
# This is the old command line argument to set the arch.
|
||||||
# rpms.
|
$opts="--buildarch ".$this->arch;
|
||||||
$opts="--buildarch noarch" if $rpmarch eq 'noarch';
|
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
# Presumably we're delaing with rpm 3.0 or above, which
|
# Presumably we're delaing with rpm 3.0 or above, which
|
||||||
@@ -384,9 +372,9 @@ sub build {
|
|||||||
# file end up in the directory we started in.
|
# file end up in the directory we started in.
|
||||||
# Anyway, let's assume this is version 3 or above.
|
# Anyway, let's assume this is version 3 or above.
|
||||||
|
|
||||||
# This is the new command line arcgument to make noarch
|
# This is the new command line arcgument to set the arch
|
||||||
# rpms. It appeared in rpm version 3.
|
# rpms. It appeared in rpm version 3.
|
||||||
$opts="--target noarch" if $rpmarch eq 'noarch';
|
$opts="--target ".$this->arch;
|
||||||
}
|
}
|
||||||
|
|
||||||
$opts.=" $ENV{RPMBUILDOPTS}" if exists $ENV{RPMBUILDOPTS};
|
$opts.=" $ENV{RPMBUILDOPTS}" if exists $ENV{RPMBUILDOPTS};
|
||||||
@@ -495,14 +483,17 @@ sub prerm {
|
|||||||
=item arch
|
=item arch
|
||||||
|
|
||||||
Set/get arch field. When the arch field is set, some sanitizing is done
|
Set/get arch field. When the arch field is set, some sanitizing is done
|
||||||
first to convert it to the debian format used internally.
|
first to convert it to the debian format used internally. When it's
|
||||||
|
retreived it's converted back to rpm form from the internal form.
|
||||||
|
|
||||||
=cut
|
=cut
|
||||||
|
|
||||||
sub arch {
|
sub arch {
|
||||||
my $this=shift;
|
my $this=shift;
|
||||||
return $this->{arch} unless @_;
|
|
||||||
my $arch=shift;
|
my $arch;
|
||||||
|
if (@_) {
|
||||||
|
$arch=shift;
|
||||||
|
|
||||||
if ($arch eq 1) {
|
if ($arch eq 1) {
|
||||||
$arch='i386';
|
$arch='i386';
|
||||||
@@ -536,7 +527,23 @@ sub arch {
|
|||||||
$arch='arm';
|
$arch='arm';
|
||||||
}
|
}
|
||||||
|
|
||||||
return $this->{arch}=$arch;
|
$this->{arch}=$arch;
|
||||||
|
}
|
||||||
|
|
||||||
|
$arch=$this->{arch};
|
||||||
|
if ($arch eq 'amd64') {
|
||||||
|
$arch='x86_64';
|
||||||
|
}
|
||||||
|
elsif ($arch eq 'powerpc') {
|
||||||
|
# XXX is this the canonical name for powerpc on rpm
|
||||||
|
# systems?
|
||||||
|
$arch='ppc';
|
||||||
|
}
|
||||||
|
elsif ($arch eq 'all') {
|
||||||
|
$arch='noarch';
|
||||||
|
}
|
||||||
|
|
||||||
|
return $arch
|
||||||
}
|
}
|
||||||
|
|
||||||
=back
|
=back
|
||||||
|
|||||||
7
debian/changelog
vendored
7
debian/changelog
vendored
@@ -1,3 +1,10 @@
|
|||||||
|
alien (8.48) unstable; urgency=low
|
||||||
|
|
||||||
|
* Support cross-building rpms, output rpm should always be same arch as
|
||||||
|
input package now.
|
||||||
|
|
||||||
|
-- Joey Hess <joeyh@debian.org> Wed, 24 Nov 2004 17:35:28 -0500
|
||||||
|
|
||||||
alien (8.47) unstable; urgency=low
|
alien (8.47) unstable; urgency=low
|
||||||
|
|
||||||
* x86_64 rpms become amd64 debs
|
* x86_64 rpms become amd64 debs
|
||||||
|
|||||||
Reference in New Issue
Block a user