diff options
author | Justin Davis <jrcd83@gmail.com> | 2012-01-17 17:30:28 +0100 |
---|---|---|
committer | Justin Davis <jrcd83@gmail.com> | 2012-01-17 17:38:36 +0100 |
commit | 6a64f1e970411510c51165da83fdece602649f1c (patch) | |
tree | 581170a31465e45e5a5fba8ad528169fa8c9da3e /metas | |
parent | df7d6667e5c016faacde7fb78d232016d5f39339 (diff) | |
download | genpkg-6a64f1e970411510c51165da83fdece602649f1c.tar.gz genpkg-6a64f1e970411510c51165da83fdece602649f1c.tar.xz |
Better error check/report in genpkg and perl-dist.
metas/perl was not returning the right error. metas/perl.d/perl-dist now
reports a better error when ~/.genpkg/var/corelist is missing. genpkg
was also not examining the right error code.
Diffstat (limited to 'metas')
-rwxr-xr-x | metas/perl | 2 | ||||
-rwxr-xr-x | metas/perl.d/perl-dist | 11 |
2 files changed, 11 insertions, 2 deletions
@@ -100,7 +100,7 @@ END_META my $file = $cpath; $file =~ s{.*/}{}; system 'perl-dist' => $file; - return $?; + return $? >> 8; } exit main(@ARGV); diff --git a/metas/perl.d/perl-dist b/metas/perl.d/perl-dist index 3259fd8..297d052 100755 --- a/metas/perl.d/perl-dist +++ b/metas/perl.d/perl-dist @@ -3,7 +3,7 @@ use warnings 'FATAL' => 'all'; use strict; -my $PROG = 'perl-dist'; +my $PROG = 'metas/perl.d/perl-dist'; package Convert; @@ -312,6 +312,15 @@ sub _nocore my (@mods) = @_; my $path = _vardir() . '/coremods'; + unless(-f $path){ + print STDERR "$PROG: error: $path is missing. +****************************************************************************** + You must generate it with genpkg's metas/perl.d/scrapecore script. Run it + against the source distribution of perl that is currently being packaged. +****************************************************************************** +"; + exit 1; + } open(my $if, '<', $path) or die "$PROG: open $path: $!"; my %mods = map { ($_ => 1) } @mods; |