Skip to content

Commit

Permalink
Makefile.PL fix for missing Test::NoWarnings build requirement.
Browse files Browse the repository at this point in the history
Along with appropriate update to Github Action.

Also we don't care about ExtUtils::MakeMaker version number anymore.

This fixes GH#175.
  • Loading branch information
whindsx committed Jul 22, 2024
1 parent a02c0d9 commit 8ba36f8
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 12 deletions.
3 changes: 2 additions & 1 deletion .github/workflows/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -50,5 +50,6 @@ jobs:
- run: sudo -E maint/scripts/03_install_oracle_instantclient_rpm.bash
- run: . /etc/profile
- run: perl -V
- run: cpanm DBI Test::NoWarnings
- run: cpanm DBI # DBI must be installed before we can build a DBD.
- run: cpanm --installdeps .
- run: perl Makefile.PL && make && make test
19 changes: 8 additions & 11 deletions Makefile.PL
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@ my %opts = (
NAME => 'DBD::Oracle',
VERSION_FROM => 'lib/DBD/Oracle.pm',
PREREQ_PM => { "Test::Simple" => 0.90, # actually Test::More pkg in T::S dist
"Test::NoWarnings" => 1.00,
"DBI" => 1.623},
OBJECT => '$(O_FILES)',
DEFINE => '',
Expand All @@ -59,20 +60,16 @@ my %opts = (
configure_requires => { "DBI" => '1.623' },
build_requires => {"DBI" => '1.623',
"ExtUtils::MakeMaker" => 0,
"Test::Simple" => '0.90'},
"Test::Simple" => '0.90',
"Test::NoWarnings" => "1.00"},
},
);
my $eumm = $ExtUtils::MakeMaker::VERSION;
$eumm =~ tr/_//d;

if ($eumm >= 5.43) {
$opts{AUTHOR} = 'Tim Bunce ([email protected])';
$opts{ABSTRACT_FROM} = 'lib/DBD/Oracle.pm';
$opts{PREREQ_PM} = { DBI => 1.623 };
$opts{CAPI} = 'TRUE' if $Config{archname} =~ /-object\b/i;
}

$opts{LICENSE} = 'perl' if $eumm >= 6.3002;
$opts{AUTHOR} = 'Tim Bunce ([email protected])';
$opts{ABSTRACT_FROM} = 'lib/DBD/Oracle.pm';
$opts{CAPI} = 'TRUE' if $Config{archname} =~ /-object\b/i;

$opts{LICENSE} = 'perl';
$opts{CCFLAGS} = "-P $Config{ccflags}" if $Config{cc} eq 'bcc32'; # force C++
$opts{LINKTYPE} = 'static' if $Config{dlsrc} =~ /dl_none/;

Expand Down

0 comments on commit 8ba36f8

Please sign in to comment.