summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xtools/draklive9
1 files changed, 7 insertions, 2 deletions
diff --git a/tools/draklive b/tools/draklive
index 75697349d..955d23f27 100755
--- a/tools/draklive
+++ b/tools/draklive
@@ -540,12 +540,17 @@ live <kernel options>
}
}
+sub get_cdrom_master_path {
+ my ($live, $media, $opts) = @_;
+ $live->{workdir} . $live->{prefix}{images} . '/' . ($opts->{boot_only} ? 'boot' : 'live') . '.iso';
+}
+
sub create_cdrom_master {
my ($live, $media, $opts) = @_;
my $label = get_media_label($media) or die "the source device must be described by a label";
my @dest;
unless ($opts->{onthefly}) {
- @dest = ('-o', $live->{workdir} . $live->{prefix}{images} . '/live.iso');
+ @dest = ('-o', get_cdrom_master_path($live, $media, $opts));
mkdir_p(dirname($dest[1]));
}
run_('mkisofs', '-pad', '-l', '-R', '-J', '-v', '-v',
@@ -611,7 +616,7 @@ sub format_device {
sub record_cdrom_master {
my ($live, $media, $opts) = @_;
$media->{device} or die "no device defined in media configuration";
- my $src = $opts->{onthefly} ? '-' : $live->{workdir} . $live->{prefix}{images} . '/live.iso';
+ my $src = $opts->{onthefly} ? '-' : get_cdrom_master_path($live, $media, $opts);
run_('cdrecord', '-v', 'dev=' . $media->{device}, $src);
}