diff options
author | Francois Perrad <fperrad@gmail.com> | 2017-08-20 10:03:31 +0200 |
---|---|---|
committer | Thomas Petazzoni <thomas.petazzoni@free-electrons.com> | 2017-08-21 23:41:07 +0200 |
commit | c92612b4b55262dc5c39a7386e725b624f5e1f23 (patch) | |
tree | 6a23b9f4bdd58a9da1b5a195387e2f02212875d2 | |
parent | 2ded88b9cdbb615117ff3a1d3b592c70367e8762 (diff) | |
download | buildroot-c92612b4b55262dc5c39a7386e725b624f5e1f23.tar.gz buildroot-c92612b4b55262dc5c39a7386e725b624f5e1f23.zip |
scancpan: catch exception when MANIFEST is missing
Signed-off-by: Francois Perrad <francois.perrad@gadz.org>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
-rwxr-xr-x | utils/scancpan | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/utils/scancpan b/utils/scancpan index 9ccbac5a41..20bd4c6933 100755 --- a/utils/scancpan +++ b/utils/scancpan @@ -567,11 +567,17 @@ sub fetch { say qq{fetch ${name}} unless $quiet; my $result = $mcpan->release( distribution => $name ); $dist{$name} = $result; - my $manifest = $mcpan->source( author => $result->{author}, - release => $name . q{-} . $result->{version}, - path => 'MANIFEST' ); - $need_dlopen{$name} = is_xs( $manifest ); - $license_files{$name} = find_license_files( $manifest ); + eval { + my $manifest = $mcpan->source( author => $result->{author}, + release => $name . q{-} . $result->{version}, + path => 'MANIFEST' ); + $need_dlopen{$name} = is_xs( $manifest ); + $license_files{$name} = find_license_files( $manifest ); + }; + if ($@) { + warn $@; + $license_files{$name} = []; + } my %build = (); my %runtime = (); my %optional = (); |