apkbuild-cpan.in: find Build.PL using glob() in update_functions sub

this is more consistent with the method we use to
find Build.PL / Makefile.PL in the do_depends sub
This commit is contained in:
Celeste 2024-01-14 15:54:20 +00:00 committed by Timothy Legge
parent 1c771b0d6a
commit 6a8a61f9d8
1 changed files with 2 additions and 3 deletions

View File

@ -260,14 +260,13 @@ sub prepare_tree {
sub update_functions {
my $apkbuild = read_apkbuild;
my $pkgver = $apkbuild->{'pkgver'};
my $metaprefix =
"src/" . $apkbuild->{'_pkgreal'} . "-" . $pkgver . "/";
my $build_pl_found = glob("src/*${pkgver}/Build.PL");
my $build_func;
my $check_func;
my $package_func;
my $text = read_file "APKBUILD";
if ( -e "$metaprefix/Build.PL" ) {
if ( $build_pl_found ) {
$build_func = <<'EOF';
build() {
export CFLAGS=$(perl -MConfig -E 'say $Config{ccflags}')