mirror of
https://github.com/Project-OSS-Revival/alien.git
synced 2026-04-24 14:00:17 +00:00
* Corrected return code of system check.
* Corrected logic error in relocatable rpm handling that was making
converting such rpms not work. (Closes: #71155)
This commit is contained in:
@@ -293,8 +293,8 @@ sub DESTROY {
|
|||||||
if ($this->unpacked_tree eq '/') {
|
if ($this->unpacked_tree eq '/') {
|
||||||
die "alien internal error: unpacked_tree is set to `/'. Please file a bug report!";
|
die "alien internal error: unpacked_tree is set to `/'. Please file a bug report!";
|
||||||
}
|
}
|
||||||
system ('rm', '-rf', $this->unpacked_tree) &&
|
system('rm', '-rf', $this->unpacked_tree) == 0
|
||||||
die "unable to delete temporary directory `".$this->unpacked_tree."`: $!";
|
or die "unable to delete temporary directory `".$this->unpacked_tree."`: $!";
|
||||||
$this->unpacked_tree('');
|
$this->unpacked_tree('');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -73,8 +73,8 @@ sub install {
|
|||||||
my $this=shift;
|
my $this=shift;
|
||||||
my $deb=shift;
|
my $deb=shift;
|
||||||
|
|
||||||
system("dpkg --no-force-overwrite -i $deb") &&
|
system("dpkg --no-force-overwrite -i $deb") == 0
|
||||||
die "Unable to install";
|
or die "Unable to install";
|
||||||
}
|
}
|
||||||
|
|
||||||
=item getcontrolfile
|
=item getcontrolfile
|
||||||
@@ -190,12 +190,12 @@ sub unpack {
|
|||||||
my $file=$this->filename;
|
my $file=$this->filename;
|
||||||
|
|
||||||
if ($this->have_dpkg_deb) {
|
if ($this->have_dpkg_deb) {
|
||||||
system("dpkg-deb -x $file ".$this->unpacked_tree) &&
|
system("dpkg-deb -x $file ".$this->unpacked_tree) == 0
|
||||||
die "Unpacking of `$file' failed: $!";
|
or die "Unpacking of `$file' failed: $!";
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
system ("ar p $file data.tar.gz | (cd ".$this->unpacked_tree."; tar zxpf -)") &&
|
system("ar p $file data.tar.gz | (cd ".$this->unpacked_tree."; tar zxpf -)") == 0
|
||||||
die "Unpacking of `$file' failed: $!";
|
or die "Unpacking of `$file' failed: $!";
|
||||||
}
|
}
|
||||||
|
|
||||||
return 1;
|
return 1;
|
||||||
@@ -252,8 +252,8 @@ sub prep {
|
|||||||
if (defined $this->patchfile) {
|
if (defined $this->patchfile) {
|
||||||
# The -f passed to zcat makes it pass uncompressed files
|
# The -f passed to zcat makes it pass uncompressed files
|
||||||
# through without error.
|
# through without error.
|
||||||
system("zcat -f ".$this->patchfile." | (cd $dir; patch -p1)") &&
|
system("zcat -f ".$this->patchfile." | (cd $dir; patch -p1)") == 0
|
||||||
die "patch error: $!";
|
or die "patch error: $!";
|
||||||
# Look for .rej files.
|
# Look for .rej files.
|
||||||
die "patch failed with .rej files; giving up"
|
die "patch failed with .rej files; giving up"
|
||||||
if `find $dir -name "*.rej"`;
|
if `find $dir -name "*.rej"`;
|
||||||
@@ -379,7 +379,8 @@ sub build {
|
|||||||
my $this=shift;
|
my $this=shift;
|
||||||
|
|
||||||
chdir $this->unpacked_tree;
|
chdir $this->unpacked_tree;
|
||||||
system("debian/rules binary >/dev/null") && die "package build failed: $!";
|
system("debian/rules binary >/dev/null") == 0
|
||||||
|
or die "package build failed: $!";
|
||||||
chdir "..";
|
chdir "..";
|
||||||
|
|
||||||
return $this->name."_".$this->version."-".$this->release."_".$this->arch.".deb";
|
return $this->name."_".$this->version."-".$this->release."_".$this->arch.".deb";
|
||||||
|
|||||||
@@ -52,8 +52,8 @@ sub install {
|
|||||||
my $this=shift;
|
my $this=shift;
|
||||||
my $rpm=shift;
|
my $rpm=shift;
|
||||||
|
|
||||||
system("rpm -ivh ".(exists $ENV{RPMINSTALLOPT} ? $ENV{RPMINSTALLOPT} : '').$rpm) &&
|
system("rpm -ivh ".(exists $ENV{RPMINSTALLOPT} ? $ENV{RPMINSTALLOPT} : '').$rpm) == 0
|
||||||
die "Unable to install";
|
or die "Unable to install";
|
||||||
}
|
}
|
||||||
|
|
||||||
=item scan
|
=item scan
|
||||||
@@ -138,8 +138,8 @@ sub unpack {
|
|||||||
$this->SUPER::unpack(@_);
|
$this->SUPER::unpack(@_);
|
||||||
my $workdir=$this->unpacked_tree;
|
my $workdir=$this->unpacked_tree;
|
||||||
|
|
||||||
system ("rpm2cpio ".$this->filename." | (cd $workdir; cpio --extract --make-directories --no-absolute-filenames --preserve-modification-time) 2>/dev/null") &&
|
system("rpm2cpio ".$this->filename." | (cd $workdir; cpio --extract --make-directories --no-absolute-filenames --preserve-modification-time) 2>/dev/null") == 0
|
||||||
die "Unpacking of `".$this->filename."' failed";
|
or die "Unpacking of `".$this->filename."' failed";
|
||||||
|
|
||||||
# If the package is relocatable. We'd like to move it to be under
|
# If the package is relocatable. We'd like to move it to be under
|
||||||
# the $this->prefixes directory. However, it's possible that that
|
# the $this->prefixes directory. However, it's possible that that
|
||||||
@@ -160,13 +160,13 @@ sub unpack {
|
|||||||
my $collect=$workdir;
|
my $collect=$workdir;
|
||||||
foreach (split m:/:, $this->prefixes) {
|
foreach (split m:/:, $this->prefixes) {
|
||||||
if ($_ ne '') { # this keeps us from using anything but relative paths.
|
if ($_ ne '') { # this keeps us from using anything but relative paths.
|
||||||
$collect.="$_/";
|
$collect.="/$_";
|
||||||
mkdir $collect,0755 || die "unable to mkdir $collect: $!";
|
mkdir $collect,0755 || die "unable to mkdir $collect: $!";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
# Now move all files in the package to the directory we made.
|
# Now move all files in the package to the directory we made.
|
||||||
system "mv", @filelist, "$workdir/".$this->prefixes &&
|
system("mv", @filelist, "$workdir/".$this->prefixes) == 0
|
||||||
die "error moving unpacked files into the default prefix directory: $!";
|
or die "error moving unpacked files into the default prefix directory: $!";
|
||||||
}
|
}
|
||||||
|
|
||||||
# When cpio extracts the file, any child directories that are
|
# When cpio extracts the file, any child directories that are
|
||||||
@@ -345,8 +345,8 @@ sub build {
|
|||||||
}
|
}
|
||||||
|
|
||||||
$opts.=" $ENV{RPMBUILDOPTS}" if exists $ENV{RPMBUILDOPTS};
|
$opts.=" $ENV{RPMBUILDOPTS}" if exists $ENV{RPMBUILDOPTS};
|
||||||
system("cd $dir; rpm $opts -bb ".$this->name."-".$this->version."-".$this->release.".spec >/dev/null") &&
|
system("cd $dir; rpm $opts -bb ".$this->name."-".$this->version."-".$this->release.".spec >/dev/null") == 0
|
||||||
die "package build failed";
|
or die "package build failed";
|
||||||
|
|
||||||
return $rpm;
|
return $rpm;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -115,7 +115,8 @@ sub install {
|
|||||||
my $this=shift;
|
my $this=shift;
|
||||||
my $slp=shift;
|
my $slp=shift;
|
||||||
|
|
||||||
system("slpi $slp") && die "Unable to install";
|
system("slpi $slp") == 0
|
||||||
|
or die "Unable to install";
|
||||||
}
|
}
|
||||||
|
|
||||||
=item getfooter
|
=item getfooter
|
||||||
@@ -251,8 +252,8 @@ sub build {
|
|||||||
# something like that, becuase it results in a tar file where all
|
# something like that, becuase it results in a tar file where all
|
||||||
# the files in it start with "./", which is consitent with how
|
# the files in it start with "./", which is consitent with how
|
||||||
# normal stampede files look.
|
# normal stampede files look.
|
||||||
system("(cd ".$this->unpacked_tree."; tar cf - ./*) | bzip2 - > $slp") &&
|
system("(cd ".$this->unpacked_tree."; tar cf - ./*) | bzip2 - > $slp") == 0
|
||||||
die "package build failed: $!";
|
or die "package build failed: $!";
|
||||||
|
|
||||||
# Now append the footer.
|
# Now append the footer.
|
||||||
open (OUT,">>$slp") || die "$slp: $!";
|
open (OUT,">>$slp") || die "$slp: $!";
|
||||||
|
|||||||
@@ -67,8 +67,8 @@ sub install {
|
|||||||
my $tgz=shift;
|
my $tgz=shift;
|
||||||
|
|
||||||
if (-x "/sbin/installpkg") {
|
if (-x "/sbin/installpkg") {
|
||||||
system("/sbin/installpkg $tgz") &&
|
system("/sbin/installpkg $tgz") == 0
|
||||||
die "Unable to install";
|
or die "Unable to install";
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
die "Sorry, I cannot install the generated .tgz file because /sbin/installpkg is not present. You can use tar to install it yourself.\n"
|
die "Sorry, I cannot install the generated .tgz file because /sbin/installpkg is not present. You can use tar to install it yourself.\n"
|
||||||
@@ -163,8 +163,8 @@ sub unpack {
|
|||||||
$this->SUPER::unpack(@_);
|
$this->SUPER::unpack(@_);
|
||||||
my $file=$this->filename;
|
my $file=$this->filename;
|
||||||
|
|
||||||
system("cat $file | (cd ".$this->unpacked_tree."; tar zxpf -)") &&
|
system("cat $file | (cd ".$this->unpacked_tree."; tar zxpf -)") == 0
|
||||||
die "Unpacking of `$file' failed: $!";
|
or die "Unpacking of `$file' failed: $!";
|
||||||
# Delete the install directory that has slackware info in it.
|
# Delete the install directory that has slackware info in it.
|
||||||
system("cd ".$this->unpacked_tree."; rm -rf ./install");
|
system("cd ".$this->unpacked_tree."; rm -rf ./install");
|
||||||
|
|
||||||
@@ -207,8 +207,8 @@ sub build {
|
|||||||
my $this=shift;
|
my $this=shift;
|
||||||
my $tgz=$this->name."-".$this->version.".tgz";
|
my $tgz=$this->name."-".$this->version.".tgz";
|
||||||
|
|
||||||
system("cd ".$this->unpacked_tree."; tar czf ../$tgz .") &&
|
system("cd ".$this->unpacked_tree."; tar czf ../$tgz .") == 0
|
||||||
die "Package build failed";
|
or die "Package build failed";
|
||||||
|
|
||||||
return $tgz;
|
return $tgz;
|
||||||
}
|
}
|
||||||
|
|||||||
5
README
5
README
@@ -32,8 +32,9 @@ Other things you'll need:
|
|||||||
Attention, Slackware, Red Hat, and Stampede users: Bruce S. Babcock
|
Attention, Slackware, Red Hat, and Stampede users: Bruce S. Babcock
|
||||||
<babcock@math.psu.edu> has put together an "alien-extra"
|
<babcock@math.psu.edu> has put together an "alien-extra"
|
||||||
package of all the extra files you need to use alien on
|
package of all the extra files you need to use alien on
|
||||||
a Red Hat or Slackware system. (Debian systems automatically have the
|
a Red Hat or Slackware system. (Debian systems automatically have all
|
||||||
required files.)
|
required files.)
|
||||||
|
|
||||||
The Slackware version is at
|
The Slackware version is at
|
||||||
ftp://ykbsb2.yk.psu.edu/pub/alien/alien-extra.tgz
|
ftp://ykbsb2.yk.psu.edu/pub/alien/alien-extra.tgz
|
||||||
The RedHat version is at
|
The RedHat version is at
|
||||||
@@ -60,6 +61,8 @@ Programs that use alien:
|
|||||||
package viewer that can convert between package formats by using alien. Its
|
package viewer that can convert between package formats by using alien. Its
|
||||||
homepage is at http://www.momentus.com.br/users/hook/kpackviewer.html
|
homepage is at http://www.momentus.com.br/users/hook/kpackviewer.html
|
||||||
|
|
||||||
|
Corel also appears to have something in Corel linux that uses alien.
|
||||||
|
|
||||||
Please report any bugs in alien to the author:
|
Please report any bugs in alien to the author:
|
||||||
|
|
||||||
Joey Hess <joeyh@debian.org>
|
Joey Hess <joeyh@debian.org>
|
||||||
|
|||||||
4
alien.pl
4
alien.pl
@@ -364,8 +364,8 @@ foreach my $file (@ARGV) {
|
|||||||
# Make .orig.tar.gz directory?
|
# Make .orig.tar.gz directory?
|
||||||
if ($format eq 'deb' && ! $single && $generate) {
|
if ($format eq 'deb' && ! $single && $generate) {
|
||||||
# Make .orig.tar.gz directory.
|
# Make .orig.tar.gz directory.
|
||||||
system("cp -fa ".$package->unpacked_tree." ".$package->unpacked_tree.".orig") &&
|
system("cp -fa ".$package->unpacked_tree." ".$package->unpacked_tree.".orig") == 0
|
||||||
die "cp -fa failed";
|
or die "cp -fa failed";
|
||||||
}
|
}
|
||||||
|
|
||||||
# See if a patch file should be used.
|
# See if a patch file should be used.
|
||||||
|
|||||||
9
debian/changelog
vendored
9
debian/changelog
vendored
@@ -1,3 +1,11 @@
|
|||||||
|
alien (7.7) unstable; urgency=low
|
||||||
|
|
||||||
|
* Corrected return code of system check.
|
||||||
|
* Corrected logic error in relocatable rpm handling that was making
|
||||||
|
converting such rpms not work. (Closes: #71155)
|
||||||
|
|
||||||
|
-- Joey Hess <joeyh@debian.org> Mon, 11 Sep 2000 16:19:22 -0700
|
||||||
|
|
||||||
alien (7.6) unstable; urgency=low
|
alien (7.6) unstable; urgency=low
|
||||||
|
|
||||||
* Added a note about a sticky library dependancy issue that I can't fix.
|
* Added a note about a sticky library dependancy issue that I can't fix.
|
||||||
@@ -5,6 +13,7 @@ alien (7.6) unstable; urgency=low
|
|||||||
names, spaces in conffile names (!!), and accented characters
|
names, spaces in conffile names (!!), and accented characters
|
||||||
everywhere in deb -> rpm conversions.
|
everywhere in deb -> rpm conversions.
|
||||||
* Fixed numerous problems when converting from .deb w/o dpkg installed.
|
* Fixed numerous problems when converting from .deb w/o dpkg installed.
|
||||||
|
* Fixed "2 files on 1 line" error when converting deb -> rpm.
|
||||||
|
|
||||||
-- Joey Hess <joeyh@debian.org> Thu, 20 Jul 2000 15:12:08 -0700
|
-- Joey Hess <joeyh@debian.org> Thu, 20 Jul 2000 15:12:08 -0700
|
||||||
|
|
||||||
|
|||||||
2
debian/control
vendored
2
debian/control
vendored
@@ -3,7 +3,7 @@ Section: admin
|
|||||||
Priority: optional
|
Priority: optional
|
||||||
Build-Depends-Indep: debhelper
|
Build-Depends-Indep: debhelper
|
||||||
Maintainer: Joey Hess <joeyh@debian.org>
|
Maintainer: Joey Hess <joeyh@debian.org>
|
||||||
Standards-Version: 3.1.1.1
|
Standards-Version: 3.2.1.0
|
||||||
|
|
||||||
Package: alien
|
Package: alien
|
||||||
Architecture: all
|
Architecture: all
|
||||||
|
|||||||
Reference in New Issue
Block a user