From 04e2b14c395ede7933addb7c4c68e1eca35468c8 Mon Sep 17 00:00:00 2001 From: Martin Whitaker Date: Thu, 4 Jan 2018 12:30:38 +0000 Subject: Improved documentation and error messages. --- lib/MGA/DrakISO/BuildMedia.pm | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'lib/MGA/DrakISO/BuildMedia.pm') diff --git a/lib/MGA/DrakISO/BuildMedia.pm b/lib/MGA/DrakISO/BuildMedia.pm index 31b1f1c..8fe59bd 100644 --- a/lib/MGA/DrakISO/BuildMedia.pm +++ b/lib/MGA/DrakISO/BuildMedia.pm @@ -17,7 +17,7 @@ # SYNOPSIS # -------- -# This module provides functions to create the installation media that will +# This package provides a function to create the installation media that will # be used by the classic installer and to collect together the various other # files that are needed on the installer ISO. @@ -70,6 +70,10 @@ my @excluded; # Main Code ############################################################################### +# This is the top-level function called to prepare the installation media +# and other files required by the installer. It is independent of any other +# preparatory step. +# sub prepare_media { my ($build) = @_; @@ -104,6 +108,8 @@ sub prepare_media { create_product_id($build, $arch_dir . '/product.id'); create_index($build, $arch_dir . '/pkg-' . $version . '-' . $tag . '.idx'); + # We don't expect this function to be called twice, but clean up + # nonetheless. undef $urpm; undef %package; undef @excluded; @@ -481,7 +487,7 @@ sub build_installer_media { my $silent = $::verbose < 3 ? ' -s' : ''; print "-- messages from gendistrib -----------------------\n" if !$silent; system("gendistrib $silent $arch_dir\n") == 0 - or die "ERROR: gendistrib failed to generate the media info.\n"; + or die "ERROR: gendistrib failed to generate the media info\n"; print "---------------------------------------------------\n" if !$silent; } -- cgit v1.2.1