Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make SQL::Abstract work. #2276

Merged
merged 1 commit into from
Feb 7, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 3 additions & 24 deletions bin/check_modules.pl
Original file line number Diff line number Diff line change
Expand Up @@ -141,6 +141,7 @@ =head1 DESCRIPTION
Scalar::Util
SOAP::Lite
Socket
SQL::Abstract
Statistics::R::IO
String::ShellQuote
SVG
Expand All @@ -166,7 +167,8 @@ =head1 DESCRIPTION
'LWP::Protocol::https' => 6.06,
'Mojolicious' => 9.22,
'Net::SSLeay' => 1.46,
'Perl::Tidy' => 20220613
'Perl::Tidy' => 20220613,
'SQL::Abstract' => 2.000000
);

my ($test_programs, $test_modules, $show_help);
Expand Down Expand Up @@ -249,29 +251,6 @@ sub check_modules {
print " $module found and loaded\n";
}
}
checkSQLabstract();
}

## this is specialized code to check for either SQL::Abstract or SQL::Abstract::Classic

sub checkSQLabstract {
print "\n checking for SQL::Abstract\n\n";
eval "use SQL::Abstract";
my $sql_abstract = not($@);
my $sql_abstract_version = $SQL::Abstract::VERSION if $sql_abstract;

eval "use SQL::Abstract::Classic";
my $sql_abstract_classic = not($@);

if ($sql_abstract_classic) {
print qq/ You have SQL::Abstract::Classic installed. This package will be used if either
the installed version of SQL::Abstract is version > 1.87 or if that package is not installed.\n/;
} elsif ($sql_abstract && $sql_abstract_version <= 1.87) {
print "You have version $sql_abstract_version of SQL::Abstract installed. This will be used\n";
} else {
print qq/You need either SQL::Abstract version <= 1.87 or need to install SQL::Abstract::Classic.
If you are using cpan or cpanm, it is recommended to install SQL::Abstract::Classic.\n/;
}
}

1;
Loading