summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorMartin Whitaker <mageia@martin-whitaker.me.uk>2018-01-13 20:25:42 +0000
committerMartin Whitaker <mageia@martin-whitaker.me.uk>2018-01-14 22:41:13 +0000
commitacc95dd9395e6dcb6f99d65e1e064d6f0f7cd407 (patch)
tree9b760d2f4f4d0efc0e3e2f8c24d8444fdb24f2a0 /lib
parent81a42ed35e61de32d82ac0e8c406841d5f37d53f (diff)
downloaddrakiso-acc95dd9395e6dcb6f99d65e1e064d6f0f7cd407.tar
drakiso-acc95dd9395e6dcb6f99d65e1e064d6f0f7cd407.tar.gz
drakiso-acc95dd9395e6dcb6f99d65e1e064d6f0f7cd407.tar.bz2
drakiso-acc95dd9395e6dcb6f99d65e1e064d6f0f7cd407.tar.xz
drakiso-acc95dd9395e6dcb6f99d65e1e064d6f0f7cd407.zip
draklive: add pubkey to local repo.
Diffstat (limited to 'lib')
-rw-r--r--lib/MGA/DrakISO/BuildRoot.pm7
1 files changed, 6 insertions, 1 deletions
diff --git a/lib/MGA/DrakISO/BuildRoot.pm b/lib/MGA/DrakISO/BuildRoot.pm
index 1ee471a..65e3a0b 100644
--- a/lib/MGA/DrakISO/BuildRoot.pm
+++ b/lib/MGA/DrakISO/BuildRoot.pm
@@ -437,7 +437,6 @@ sub build_local_repo {
my $class = $path_parts[-3];
my $dst_dir = $local_repo_dir . $class;
mkdir_in_root($root, $dst_dir) if ! -d "$root$dst_dir";
- # TODO: support remote repositories
copy_to_root($root, $dst_dir, undef, $src_path);
$classes{$class} = 1;
}
@@ -445,6 +444,10 @@ sub build_local_repo {
print "..generating media info\n" if $::verbose > 1;
foreach my $class (keys %classes) {
+ my $media_info_dir = $local_repo_dir . $class . '/media_info';
+ mkdir_in_root($root, $media_info_dir);
+ my $pubkey = $arch_repository . '/media/' . $class . '/release/media_info/pubkey';
+ copy_to_root($root, $media_info_dir, undef, $pubkey);
run_in_root($root, $arch, 'genhdlist2', if_($::verbose < 2, '-q'), $local_repo_dir . $class)
or die "ERROR: failed to generate hdlists for '$class' local repository\n";
}
@@ -691,6 +694,8 @@ sub mkdir_in_root {
sub copy_to_root {
my ($root, $dest, $mode, @files) = @_;
+ # TODO: support source files in remote repositories
+
run_as_root('cp', '-af', @files, $root . $dest)
or die "ERROR: failed to copy file to $dest in Live system root\n";