mirror of
https://github.com/Project-OSS-Revival/alien.git
synced 2026-04-24 14:00:17 +00:00
Compare commits
18 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
ee792cb76c | ||
|
|
ecabe240bc | ||
|
|
b2421b584a | ||
|
|
7893ffb4ed | ||
|
|
5e1d2c9fa4 | ||
|
|
3c8631f8fd | ||
|
|
17bcd710f7 | ||
|
|
ac38739a74 | ||
|
|
dbf7fdfa5b | ||
|
|
15b2f7ff92 | ||
|
|
7a06220ed7 | ||
|
|
d39d884f1b | ||
|
|
9edefc1c48 | ||
|
|
13b74f3141 | ||
|
|
6230493dfe | ||
|
|
cfc242e886 | ||
|
|
ffcb91fa04 | ||
|
|
f0c859c1c4 |
2
.gitignore
vendored
Normal file
2
.gitignore
vendored
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
alien.lsm
|
||||||
|
alien.spec
|
||||||
@@ -87,8 +87,11 @@ sub install {
|
|||||||
my $this=shift;
|
my $this=shift;
|
||||||
my $deb=shift;
|
my $deb=shift;
|
||||||
|
|
||||||
|
my $v=$Alien::Package::verbose;
|
||||||
|
$Alien::Package::verbose=2;
|
||||||
$this->do("dpkg", "--no-force-overwrite", "-i", $deb)
|
$this->do("dpkg", "--no-force-overwrite", "-i", $deb)
|
||||||
or die "Unable to install";
|
or die "Unable to install";
|
||||||
|
$Alien::Package::verbose=$v;
|
||||||
}
|
}
|
||||||
|
|
||||||
=item test
|
=item test
|
||||||
@@ -331,10 +334,14 @@ sub prep {
|
|||||||
print OUT $this->name." (".$this->version."-".$this->release.") experimental; urgency=low\n";
|
print OUT $this->name." (".$this->version."-".$this->release.") experimental; urgency=low\n";
|
||||||
print OUT "\n";
|
print OUT "\n";
|
||||||
print OUT " * Converted from .".$this->origformat." format to .deb by alien version $Alien::Version\n";
|
print OUT " * Converted from .".$this->origformat." format to .deb by alien version $Alien::Version\n";
|
||||||
|
print OUT " \n";
|
||||||
|
if (defined $this->changelogtext) {
|
||||||
|
my $ct=$this->changelogtext;
|
||||||
|
$ct=~s/^/ /gm;
|
||||||
|
print OUT $ct."\n";
|
||||||
|
}
|
||||||
print OUT "\n";
|
print OUT "\n";
|
||||||
print OUT " -- ".$this->username." <".$this->email."> ".$this->date."\n";
|
print OUT " -- ".$this->username." <".$this->email."> ".$this->date."\n";
|
||||||
print OUT "\n";
|
|
||||||
print OUT $this->changelogtext."\n" if defined $this->changelogtext;
|
|
||||||
close OUT;
|
close OUT;
|
||||||
|
|
||||||
# Control file.
|
# Control file.
|
||||||
|
|||||||
@@ -106,8 +106,11 @@ sub install {
|
|||||||
my $pkg=shift;
|
my $pkg=shift;
|
||||||
|
|
||||||
if (-x "/usr/sbin/pkgadd") {
|
if (-x "/usr/sbin/pkgadd") {
|
||||||
|
my $v=$Alien::Package::verbose;
|
||||||
|
$Alien::Package::verbose=2;
|
||||||
$this->do("/usr/sbin/pkgadd", "-d .", "$pkg")
|
$this->do("/usr/sbin/pkgadd", "-d .", "$pkg")
|
||||||
or die "Unable to install";
|
or die "Unable to install";
|
||||||
|
$Alien::Package::verbose=$v;
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
die "Sorry, I cannot install the generated .pkg file because /usr/sbin/pkgadd is not present.\n";
|
die "Sorry, I cannot install the generated .pkg file because /usr/sbin/pkgadd is not present.\n";
|
||||||
|
|||||||
@@ -53,8 +53,11 @@ sub install {
|
|||||||
my $this=shift;
|
my $this=shift;
|
||||||
my $rpm=shift;
|
my $rpm=shift;
|
||||||
|
|
||||||
|
my $v=$Alien::Package::verbose;
|
||||||
|
$Alien::Package::verbose=2;
|
||||||
$this->do("rpm -ivh ".(exists $ENV{RPMINSTALLOPT} ? $ENV{RPMINSTALLOPT} : '').$rpm)
|
$this->do("rpm -ivh ".(exists $ENV{RPMINSTALLOPT} ? $ENV{RPMINSTALLOPT} : '').$rpm)
|
||||||
or die "Unable to install";
|
or die "Unable to install";
|
||||||
|
$Alien::Package::verbose=$v;
|
||||||
}
|
}
|
||||||
|
|
||||||
=item scan
|
=item scan
|
||||||
@@ -75,18 +78,20 @@ sub scan {
|
|||||||
POSTUN => 'postrm',
|
POSTUN => 'postrm',
|
||||||
);
|
);
|
||||||
|
|
||||||
# These fields need no translation except case.
|
|
||||||
foreach (qw{name version release arch changelogtext summary
|
|
||||||
description copyright prefixes}) {
|
|
||||||
$fieldtrans{uc $_}=$_;
|
|
||||||
}
|
|
||||||
|
|
||||||
# Use --queryformat to pull out all the fields we need.
|
# Use --queryformat to pull out all the fields we need.
|
||||||
foreach my $field (keys(%fieldtrans)) {
|
foreach my $field (qw{NAME VERSION RELEASE ARCH CHANGELOGTEXT
|
||||||
$_=$this->runpipe(0, "LANG=C rpm -qp --queryformat \%{$field} $file");
|
SUMMARY DESCRIPTION COPYRIGHT PREFIXES},
|
||||||
$field=$fieldtrans{$field};
|
keys(%fieldtrans)) {
|
||||||
$_='' if $_ eq '(none)';
|
my $value=$this->runpipe(0, "LANG=C rpm -qp --queryformat \%{$field} $file");
|
||||||
$this->$field($_);
|
my $key;
|
||||||
|
if (exists $fieldtrans{$field}) {
|
||||||
|
$key=$fieldtrans{$field};
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
$key=lc($field);
|
||||||
|
}
|
||||||
|
$value='' if $value eq '(none)';
|
||||||
|
$this->$key($value);
|
||||||
}
|
}
|
||||||
|
|
||||||
# Get the conffiles list.
|
# Get the conffiles list.
|
||||||
@@ -182,6 +187,8 @@ sub unpack {
|
|||||||
#
|
#
|
||||||
# Test to see if the package contains the prefix directory already.
|
# Test to see if the package contains the prefix directory already.
|
||||||
if (defined $this->prefixes && ! -e "$workdir/".$this->prefixes) {
|
if (defined $this->prefixes && ! -e "$workdir/".$this->prefixes) {
|
||||||
|
my $relocate=1;
|
||||||
|
|
||||||
# Get the files to move.
|
# Get the files to move.
|
||||||
my @filelist=glob("$workdir/*");
|
my @filelist=glob("$workdir/*");
|
||||||
|
|
||||||
@@ -190,9 +197,21 @@ sub unpack {
|
|||||||
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.="/$_";
|
||||||
|
if (-d $collect) {
|
||||||
|
# The package contains a parent
|
||||||
|
# directory of the relocation
|
||||||
|
# directory. Since it's impossible
|
||||||
|
# to move a parent directory into
|
||||||
|
# its child, bail out and do
|
||||||
|
# nothing.
|
||||||
|
$relocate=0;
|
||||||
|
last;
|
||||||
|
}
|
||||||
$this->do("mkdir", $collect) || die "unable to mkdir $collect: $!";
|
$this->do("mkdir", $collect) || die "unable to mkdir $collect: $!";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if ($relocate) {
|
||||||
# Now move all files in the package to the directory we made.
|
# Now move all files in the package to the directory we made.
|
||||||
if (@filelist) {
|
if (@filelist) {
|
||||||
$this->do("mv", @filelist, "$workdir/".$this->prefixes)
|
$this->do("mv", @filelist, "$workdir/".$this->prefixes)
|
||||||
@@ -207,6 +226,7 @@ sub unpack {
|
|||||||
}
|
}
|
||||||
$this->conffiles([@cf]);
|
$this->conffiles([@cf]);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
# rpm files have two sets of permissions; the set in the cpio
|
# rpm files have two sets of permissions; the set in the cpio
|
||||||
# archive, and the set in the control data; which override them.
|
# archive, and the set in the control data; which override them.
|
||||||
|
|||||||
@@ -114,8 +114,11 @@ sub install {
|
|||||||
my $this=shift;
|
my $this=shift;
|
||||||
my $slp=shift;
|
my $slp=shift;
|
||||||
|
|
||||||
|
my $v=$Alien::Package::verbose;
|
||||||
|
$Alien::Package::verbose=2;
|
||||||
$this->do("slpi", $slp)
|
$this->do("slpi", $slp)
|
||||||
or die "Unable to install";
|
or die "Unable to install";
|
||||||
|
$Alien::Package::verbose=$v;
|
||||||
}
|
}
|
||||||
|
|
||||||
=item getfooter
|
=item getfooter
|
||||||
|
|||||||
@@ -66,8 +66,11 @@ sub install {
|
|||||||
my $tgz=shift;
|
my $tgz=shift;
|
||||||
|
|
||||||
if (-x "/sbin/installpkg") {
|
if (-x "/sbin/installpkg") {
|
||||||
|
my $v=$Alien::Package::verbose;
|
||||||
|
$Alien::Package::verbose=2;
|
||||||
$this->do("/sbin/installpkg", "$tgz")
|
$this->do("/sbin/installpkg", "$tgz")
|
||||||
or die "Unable to install";
|
or die "Unable to install";
|
||||||
|
$Alien::Package::verbose=$v;
|
||||||
}
|
}
|
||||||
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"
|
||||||
@@ -92,7 +95,7 @@ sub scan {
|
|||||||
# Strip out any tar extentions.
|
# Strip out any tar extentions.
|
||||||
$basename=~s/\.(tgz|tar\.(gz|Z))$//;
|
$basename=~s/\.(tgz|tar\.(gz|Z))$//;
|
||||||
|
|
||||||
if ($basename=~m/(.*)-(.*?[0-9]+.*)/) {
|
if ($basename=~m/([\w-]+)-([0-9\.?]+).*/) {
|
||||||
$this->name($1);
|
$this->name($1);
|
||||||
$this->version($2);
|
$this->version($2);
|
||||||
}
|
}
|
||||||
|
|||||||
4
alien.pl
4
alien.pl
@@ -137,7 +137,7 @@ built.
|
|||||||
|
|
||||||
Be less strict about which patch file is used, perhaps attempting to use a patch
|
Be less strict about which patch file is used, perhaps attempting to use a patch
|
||||||
file for an older verson of the package. This is not guaranteed to always work;
|
file for an older verson of the package. This is not guaranteed to always work;
|
||||||
older patches may necessarily not work with newer packages.
|
older patches may not necessarily work with newer packages.
|
||||||
|
|
||||||
=item B<--nopatch>
|
=item B<--nopatch>
|
||||||
|
|
||||||
@@ -159,7 +159,7 @@ Note that without an argument, this displays the version of B<alien> instead.
|
|||||||
=item B<-c>, B<--scripts>
|
=item B<-c>, B<--scripts>
|
||||||
|
|
||||||
Try to convert the scripts that are meant to be run when the
|
Try to convert the scripts that are meant to be run when the
|
||||||
package is installed and removed. Use this with caution, becuase these
|
package is installed and removed. Use this with caution, because these
|
||||||
scripts might be designed to work on a system unlike your own, and could
|
scripts might be designed to work on a system unlike your own, and could
|
||||||
cause problems. It is recommended that you examine the scripts by hand
|
cause problems. It is recommended that you examine the scripts by hand
|
||||||
and check to see what they do before using this option.
|
and check to see what they do before using this option.
|
||||||
|
|||||||
40
debian/changelog
vendored
40
debian/changelog
vendored
@@ -1,3 +1,43 @@
|
|||||||
|
alien (8.72) unstable; urgency=low
|
||||||
|
|
||||||
|
* Use debhelper 7, rules file minimisation.
|
||||||
|
* Improve parsing of tgz filenames, to avoid confusion when the filename
|
||||||
|
includes the package type (ie, "noarch"). Patch from Andrej Ricnik-Bay.
|
||||||
|
* When generating a debian changelog file, work around bug #478925 by
|
||||||
|
including the alien changelog text inside the debian changelog entry.
|
||||||
|
|
||||||
|
-- Joey Hess <joeyh@debian.org> Thu, 01 May 2008 15:40:34 -0400
|
||||||
|
|
||||||
|
alien (8.71) unstable; urgency=low
|
||||||
|
|
||||||
|
* Deal with rpms that relocate ie, /usr into /usr/local, and don't
|
||||||
|
try to move /usr into /usr/local in this case. Closes: #470905
|
||||||
|
|
||||||
|
-- Joey Hess <joeyh@debian.org> Fri, 14 Mar 2008 13:35:33 -0400
|
||||||
|
|
||||||
|
alien (8.70) unstable; urgency=low
|
||||||
|
|
||||||
|
* Extract prefixes field before extracting scripts so that
|
||||||
|
RPM_INSTALL_PREFIX gets set.
|
||||||
|
|
||||||
|
-- Joey Hess <joeyh@debian.org> Wed, 12 Mar 2008 11:05:40 -0400
|
||||||
|
|
||||||
|
alien (8.69) unstable; urgency=low
|
||||||
|
|
||||||
|
* Alien's repository has moved from subversion to git.
|
||||||
|
* Minor improvement to debian/rules clean.
|
||||||
|
* Improve the short description.
|
||||||
|
|
||||||
|
-- Joey Hess <joeyh@debian.org> Fri, 19 Oct 2007 20:27:53 -0400
|
||||||
|
|
||||||
|
alien (8.68) unstable; urgency=low
|
||||||
|
|
||||||
|
* Show output of installation of package with -i, since some packages
|
||||||
|
install scripts may have important output or even be interactive.
|
||||||
|
Closes: #425732
|
||||||
|
|
||||||
|
-- Joey Hess <joeyh@debian.org> Thu, 24 May 2007 14:08:39 -0400
|
||||||
|
|
||||||
alien (8.67) unstable; urgency=low
|
alien (8.67) unstable; urgency=low
|
||||||
|
|
||||||
* Update the url to the web page, and remove several other broken urls from
|
* Update the url to the web page, and remove several other broken urls from
|
||||||
|
|||||||
2
debian/compat
vendored
2
debian/compat
vendored
@@ -1 +1 @@
|
|||||||
4
|
7
|
||||||
|
|||||||
9
debian/control
vendored
9
debian/control
vendored
@@ -1,17 +1,18 @@
|
|||||||
Source: alien
|
Source: alien
|
||||||
Section: admin
|
Section: admin
|
||||||
Priority: optional
|
Priority: optional
|
||||||
Build-Depends: debhelper (>= 4), dpkg-dev (>= 1.9.0)
|
Build-Depends: debhelper (>= 7)
|
||||||
Maintainer: Joey Hess <joeyh@debian.org>
|
Maintainer: Joey Hess <joeyh@debian.org>
|
||||||
Standards-Version: 3.7.2
|
Standards-Version: 3.7.3
|
||||||
XS-Vcs-Svn: svn://svn.kitenet.net/joey/trunk/src/packages/alien
|
Vcs-Git: git://git.kitenet.net/alien
|
||||||
|
Homepage: http://kitenet.net/~joey/code/alien/
|
||||||
|
|
||||||
Package: alien
|
Package: alien
|
||||||
Architecture: all
|
Architecture: all
|
||||||
Section: admin
|
Section: admin
|
||||||
Depends: debhelper (>= 3), ${misc:Depends}, ${perl:Depends}, rpm (>= 2.4.4-2), dpkg-dev, make, cpio
|
Depends: debhelper (>= 3), ${misc:Depends}, ${perl:Depends}, rpm (>= 2.4.4-2), dpkg-dev, make, cpio
|
||||||
Suggests: patch, bzip2, lsb-rpm, lintian
|
Suggests: patch, bzip2, lsb-rpm, lintian
|
||||||
Description: install non-native packages with dpkg
|
Description: convert and install rpm and other packages
|
||||||
Alien allows you to convert LSB, Red Hat, Stampede and Slackware Packages
|
Alien allows you to convert LSB, Red Hat, Stampede and Slackware Packages
|
||||||
into Debian packages, which can be installed with dpkg.
|
into Debian packages, which can be installed with dpkg.
|
||||||
.
|
.
|
||||||
|
|||||||
2
debian/docs
vendored
Normal file
2
debian/docs
vendored
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
README
|
||||||
|
gendiff.txt
|
||||||
38
debian/rules
vendored
38
debian/rules
vendored
@@ -1,47 +1,21 @@
|
|||||||
#!/usr/bin/make -f
|
#!/usr/bin/make -f
|
||||||
|
%:
|
||||||
|
dh $@
|
||||||
|
|
||||||
build: build-stamp
|
build:
|
||||||
build-stamp:
|
dh build
|
||||||
dh_testdir
|
|
||||||
perl Makefile.PL
|
|
||||||
$(MAKE)
|
|
||||||
# simple smoke test
|
# simple smoke test
|
||||||
./alien.pl -V
|
./alien.pl -V
|
||||||
touch build-stamp
|
|
||||||
|
|
||||||
clean:
|
|
||||||
dh_testdir
|
|
||||||
dh_testroot
|
|
||||||
rm -f build-stamp
|
|
||||||
perl Makefile.PL
|
|
||||||
-$(MAKE) realclean
|
|
||||||
dh_clean
|
|
||||||
|
|
||||||
binary-arch: build
|
|
||||||
|
|
||||||
binary-indep: build
|
binary-indep: build
|
||||||
dh_testdir
|
dh install --before dh_auto_install
|
||||||
dh_testroot
|
|
||||||
dh_clean -k
|
|
||||||
$(MAKE) pure_install INSTALLDIRS=vendor \
|
$(MAKE) pure_install INSTALLDIRS=vendor \
|
||||||
PREFIX=$(shell pwd)/debian/alien/$(shell perl -MConfig -e 'print $$Config{prefix}') \
|
PREFIX=$(shell pwd)/debian/alien/$(shell perl -MConfig -e 'print $$Config{prefix}') \
|
||||||
VARPREFIX=$(shell pwd)/debian/alien
|
VARPREFIX=$(shell pwd)/debian/alien
|
||||||
# Why does it make this empty directory? Sigh.
|
dh install --after dh_auto_install
|
||||||
rm -rf debian/alien/usr/lib
|
|
||||||
dh_installdocs README gendiff.txt
|
|
||||||
dh_installexamples
|
|
||||||
dh_installchangelogs
|
|
||||||
dh_compress
|
|
||||||
dh_fixperms
|
|
||||||
dh_perl
|
|
||||||
dh_installdeb
|
|
||||||
dh_gencontrol
|
|
||||||
dh_md5sums
|
|
||||||
dh_builddeb
|
|
||||||
|
|
||||||
# Not intended for use by anyone except the author.
|
# Not intended for use by anyone except the author.
|
||||||
announcedir:
|
announcedir:
|
||||||
@echo ${HOME}/src/joeywiki/code/alien/news
|
@echo ${HOME}/src/joeywiki/code/alien/news
|
||||||
|
|
||||||
binary: binary-indep binary-arch
|
binary: binary-indep binary-arch
|
||||||
.PHONY: build clean binary-indep binary-arch binary
|
|
||||||
|
|||||||
Reference in New Issue
Block a user