summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xdraklive12
1 files changed, 8 insertions, 4 deletions
diff --git a/draklive b/draklive
index 87cd822..3277d3e 100755
--- a/draklive
+++ b/draklive
@@ -438,10 +438,9 @@ sub create_media_initrd {
$live->{copy_initrd}) if $live->{copy_initrd};
}
-sub inst_initrd_bin {
- my ($root, $initrd_tree, $bin) = @_;
- cp_f($root . $bin, $initrd_tree . '/bin/');
- foreach my $file (`chroot $root ldd $bin | awk '/\\// {if(\$2 == "=>") {print \$3} else {print \$1}}'`) {
+sub inst_initrd_dso_deps {
+ my ($root, $initrd_tree, $dso) = @_;
+ foreach my $file (`chroot $root ldd $dso | awk '/\\// {if(\$2 == "=>") {print \$3} else {print \$1}}'`) {
chomp $file;
$file =~ s!^(/lib[^/]*)/(?:i686|tls)!$1!;
my ($lib_prefix, $filename) = $file =~ m|(/lib[^/]*).*/([^/]+)$| or next;
@@ -450,6 +449,11 @@ sub inst_initrd_bin {
-f $dest || cp_f($root . $file, $dest) or die "unable to copy $filename from system chroot\n";
}
}
+sub inst_initrd_bin {
+ my ($root, $initrd_tree, $bin) = @_;
+ cp_f($root . $bin, $initrd_tree . '/bin/');
+ inst_initrd_dso_deps($root, $initrd_tree, $bin);
+}
sub create_initrd_for_media {
my ($live, $media) = @_;