aboutsummaryrefslogtreecommitdiffstats
path: root/lib/Iurt
diff options
context:
space:
mode:
Diffstat (limited to 'lib/Iurt')
-rw-r--r--lib/Iurt/Config.pm6
-rw-r--r--lib/Iurt/DKMS.pm8
2 files changed, 7 insertions, 7 deletions
diff --git a/lib/Iurt/Config.pm b/lib/Iurt/Config.pm
index c2fbe6d..33d822f 100644
--- a/lib/Iurt/Config.pm
+++ b/lib/Iurt/Config.pm
@@ -137,7 +137,7 @@ sub init_cache {
my $cachefile = "$config->{cache_home}/$program_name.cache";
my $cache;
if (-f $cachefile) {
- $run->{LOG}->("$program_name: loading cache file $cachefile\n");
+ plog('DEBUG', "loading cache file $cachefile");
$cache = eval(cat_($cachefile)) or print "FATAL $program_name: could not load cache $cachefile ($!)\n";
} else {
$cache = $empty;
@@ -166,9 +166,9 @@ sub dump_cache {
$Data::Dumper::Terse = 1;
print $file Data::Dumper->Dump([ $cache ], [ "cache" ]);
# flock does not work on network files and lockf seems to fail too
- $run->{LOG}->("$program_name: locking to dump the cache in $filename\n");
+ plog('DEBUG', "locking to dump the cache in $filename");
if (-f "$filename.lock") {
- $run->{LOG}->("ERROR iurt: manual file lock exist, do not save the cache\n");
+ plog('ERROR', 'ERROR: manual file lock exist, do not save the cache');
} else {
open my $lock, ">$filename.lock";
print $lock $$;
diff --git a/lib/Iurt/DKMS.pm b/lib/Iurt/DKMS.pm
index 535e822..d5613e8 100644
--- a/lib/Iurt/DKMS.pm
+++ b/lib/Iurt/DKMS.pm
@@ -238,7 +238,7 @@ sub dkms_compile {
plog('DEBUG', "symlink from $modules_build_dir to /usr/src/$sourcedir");
if (system("sudo ln -sf /usr/src/$sourcedir $modules_build_dir")) {
- plog('ERROR', "linking failed ($!)");
+ plog('ERROR', "ERROR: linking failed ($!)");
next;
}
}
@@ -282,13 +282,13 @@ sub dkms_compile {
if (system("cp $rpms $dkms_spool/$media/ &>/dev/null") == 0) {
$copied = 1;
sudo($run, $config, '--rm', $rpms)
- or $run->{LOG}->("ERROR: could not delete dkms packages from $rpms ($!)\n");
+ or plog('ERROR', "ERROR: could not delete dkms packages from $rpms ($!)");
last;
}
}
- $run->{LOG}->("ERROR: could not copy dkms packages from " .
+ plog('ERROR', "ERROR: could not copy dkms packages from " .
join(" or ", map { "$chroot_tmp$_/*.rpm" } @dkms_rpm_dirs) .
- " to $dkms_spool/$media ($!)\n") if !$copied;
+ " to $dkms_spool/$media ($!)") if !$copied;
process_dkms_queue($self, 0, 0, $media, "$dkms_spool/$media");
# compile dkms modules