aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFrancois Pons <fpons@mandriva.com>2001-03-12 15:20:41 +0000
committerFrancois Pons <fpons@mandriva.com>2001-03-12 15:20:41 +0000
commitc344baaa1044129fce2c4c5d1e085151c3f47e80 (patch)
tree50200309d48e271da25d226c2e9a54fc8f366b66
parente2f72487d1078e0d7ab6b99233a5fb7afb7765a6 (diff)
downloadrpmtools-c344baaa1044129fce2c4c5d1e085151c3f47e80.tar
rpmtools-c344baaa1044129fce2c4c5d1e085151c3f47e80.tar.gz
rpmtools-c344baaa1044129fce2c4c5d1e085151c3f47e80.tar.bz2
rpmtools-c344baaa1044129fce2c4c5d1e085151c3f47e80.tar.xz
rpmtools-c344baaa1044129fce2c4c5d1e085151c3f47e80.zip
*** empty log message ***
-rw-r--r--packdrake.pm11
-rw-r--r--parsehdlist.c12
-rw-r--r--rpmtools.spec11
3 files changed, 21 insertions, 13 deletions
diff --git a/packdrake.pm b/packdrake.pm
index 5c720a1..9db7ee1 100644
--- a/packdrake.pm
+++ b/packdrake.pm
@@ -214,7 +214,8 @@ sub catsksz {
sub cat_compress {
my ($packer, $srcdir, @filenames) = @_;
local *F;
- open F, "| $packer->{compress} >$packer->{tmpz}" or die "packdrake: cannot start \"$packer->{compress}\"\n";
+ open F, "| $ENV{LD_LOADER} $packer->{compress} >$packer->{tmpz}"
+ or die "packdrake: cannot start \"$packer->{compress}\"\n";
foreach (@filenames) {
my $srcfile = $srcdir ? "$srcdir/$_" : $_;
my ($buf, $siz, $sz);
@@ -327,7 +328,7 @@ sub cat_archive {
open STDIN, "<$_" or die "packdrake: unable to open archive $_\n";
open STDERR, ">/dev/null" or die "packdrake: unable to open /dev/null\n";
- exec split " ", $packer->{uncompress};
+ exec (($ENV{LD_LOADER} ? ($ENV{LD_LOADER}) : ()), split " ", $packer->{uncompress});
die "packdrake: unable to cat the archive with $packer->{uncompress}\n";
}
@@ -398,7 +399,7 @@ sub extract_archive {
close FILE;
} else {
local *BUNZIP2;
- open BUNZIP2, "| $packer->{uncompress}";
+ open BUNZIP2, "| $ENV{LD_LOADER} $packer->{uncompress}";
local *ARCHIVE;
open ARCHIVE, "<$packer->{archive}" or die "packdrake: cannot open archive $packer->{archive}\n";
catsksz(\*ARCHIVE, $_, $extract_table{$_}[0], \*BUNZIP2);
@@ -448,7 +449,7 @@ sub build_archive {
$packer->{data}{$_} = [ 'f', $off1, $siz1, $packer->{data}{$_}[3], $packer->{data}{$_}[4] ];
}
- system "cat '$packer->{tmpz}' >>'$packer->{archive}'";
+ system "$ENV{LD_LOADER} cat '$packer->{tmpz}' >>'$packer->{archive}'";
$off1 += $siz1;
$off2 = 0; $siz2 = 0;
@filelist = ();
@@ -463,7 +464,7 @@ sub build_archive {
$packer->{data}{$_} = [ 'f', $off1, $siz1, $packer->{data}{$_}[3], $packer->{data}{$_}[4] ];
}
- system "cat '$packer->{tmpz}' >>'$packer->{archive}'";
+ system "$ENV{LD_LOADER} cat '$packer->{tmpz}' >>'$packer->{archive}'";
$off1 += $siz1;
}
print STDERR "real archive size of $packer->{archive} is $off1\n";
diff --git a/parsehdlist.c b/parsehdlist.c
index 46bfe6b..6514db2 100644
--- a/parsehdlist.c
+++ b/parsehdlist.c
@@ -245,7 +245,6 @@ int main(int argc, char **argv)
close(fdno[0]);
close(fdno[1]);
} else {
-#if 1
int fda, fdn;
struct {
char header[4];
@@ -256,9 +255,14 @@ int main(int argc, char **argv)
char uncompress[40];
char trailer[4];
} buf;
- char *unpacker[21]; /* enough for 40 bytes above to never overbuf */
+ char *unpacker[22]; /* enough for 40 bytes above to never overbuf */
char *p = buf.uncompress;
int ip = 0;
+ char *ld_loader = getenv("LD_LOADER");
+
+ if (ld_loader && *ld_loader) {
+ unpacker[ip++] = ld_loader;
+ }
dup2(fdno[1], STDOUT_FILENO);
fda = open(argv[i], O_RDONLY);
@@ -285,10 +289,6 @@ int main(int argc, char **argv)
fdn = open("/dev/null", O_WRONLY);
dup2(fdn, STDERR_FILENO);
execvp(unpacker[0], unpacker);
-#else
- dup2(fdno[1], STDOUT_FILENO);
- execlp("packdrake", "packdrake", "-c", argv[i], NULL);
-#endif
exit(2);
}
} else {
diff --git a/rpmtools.spec b/rpmtools.spec
index 80932cc..65b8968 100644
--- a/rpmtools.spec
+++ b/rpmtools.spec
@@ -1,5 +1,5 @@
%define name rpmtools
-%define release 10mdk
+%define release 12mdk
# do not modify here, see Makefile in the CVS
%define version 2.3
@@ -16,7 +16,7 @@ Group: System/Configuration/Packaging
BuildRoot: %{_tmppath}/%{name}-buildroot
Prefix: %{_prefix}
BuildRequires: rpm-devel >= 4.0 bzip2 popt-devel zlib-devel
-Requires: /usr/bin/perl rpm >= 4.0 bzip2 >= 1.0 db2 db3
+Requires: /usr/bin/perl rpm >= 4.0 bzip2 >= 1.0
Obsoletes: rpmtools-compat <= 2.0 rpmtools-devel <= 2.0
%description
@@ -51,6 +51,13 @@ rm -rf $RPM_BUILD_ROOT
%{_libdir}/perl5/man/*/*
%changelog
+* Mon Mar 12 2001 François Pons <fpons@mandrakesoft.com> 2.3-12mdk
+- added support for LD_LOADER in packdrake module.
+- removed explicit requires of db2 and db3.
+
+* Mon Mar 12 2001 François Pons <fpons@mandrakesoft.com> 2.3-11mdk
+-
+
* Thu Mar 8 2001 François Pons <fpons@mandrakesoft.com> 2.3-10mdk
- fixed duplicate choices in depslist.ordered file.
- fixed missing choices on some deps.