-
Notifications
You must be signed in to change notification settings - Fork 603
Maintenance: check for Perl modules #2349
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
Open
yadij
wants to merge
2
commits into
squid-cache:master
Choose a base branch
from
yadij:arc-autoconf-ng-80
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+109
−0
Open
Changes from all commits
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,84 @@ | ||
| dnl Copyright (C) 1996-2026 The Squid Software Foundation and contributors | ||
| dnl | ||
| dnl Squid software is distributed under GPLv2+ license and includes | ||
| dnl contributions from numerous individuals and organizations. | ||
| dnl Please see the COPYING and CONTRIBUTORS files for details. | ||
| dnl | ||
|
|
||
| dnl =========================================================================== | ||
| dnl https://www.gnu.org/software/autoconf-archive/ax_prog_perl_modules.html | ||
| dnl =========================================================================== | ||
| dnl | ||
| dnl SYNOPSIS | ||
| dnl | ||
| dnl AX_PROG_PERL_MODULES([MODULES], [ACTION-IF-TRUE], [ACTION-IF-FALSE]) | ||
| dnl | ||
| dnl DESCRIPTION | ||
| dnl | ||
| dnl Checks to see if the given perl modules are available. If true the shell | ||
| dnl commands in ACTION-IF-TRUE are executed. If not the shell commands in | ||
| dnl ACTION-IF-FALSE are run. Note if $PERL is not set (for example by | ||
| dnl calling AC_CHECK_PROG, or AC_PATH_PROG), AC_CHECK_PROG(PERL, perl, perl) | ||
| dnl will be run. | ||
| dnl | ||
| dnl MODULES is a space separated list of module names. To check for a | ||
| dnl minimum version of a module, append the version number to the module | ||
| dnl name, separated by an equals sign. | ||
| dnl | ||
| dnl Example: | ||
| dnl | ||
| dnl AX_PROG_PERL_MODULES( Text::Wrap Net::LDAP=1.0.3, , | ||
| dnl AC_MSG_WARN(Need some Perl modules) | ||
| dnl | ||
| dnl LICENSE | ||
| dnl | ||
| dnl Copyright (c) 2009 Dean Povey <povey@wedgetail.com> | ||
| dnl | ||
| dnl Copying and distribution of this file, with or without modification, are | ||
| dnl permitted in any medium without royalty provided the copyright notice | ||
| dnl and this notice are preserved. This file is offered as-is, without any | ||
| dnl warranty. | ||
|
|
||
| #serial 8 | ||
|
|
||
| AU_ALIAS([AC_PROG_PERL_MODULES], [AX_PROG_PERL_MODULES]) | ||
| AC_DEFUN([AX_PROG_PERL_MODULES],[dnl | ||
|
|
||
| m4_define([ax_perl_modules]) | ||
| m4_foreach([ax_perl_module], m4_split(m4_normalize([$1])), | ||
| [ | ||
| m4_append([ax_perl_modules], | ||
| [']m4_bpatsubst(ax_perl_module,=,[ ])[' ]) | ||
| ]) | ||
|
|
||
| # Make sure we have perl | ||
| if test -z "$PERL"; then | ||
| AC_CHECK_PROG(PERL,perl,perl) | ||
| fi | ||
|
|
||
| if test "x$PERL" != x; then | ||
| ax_perl_modules_failed=0 | ||
| for ax_perl_module in ax_perl_modules; do | ||
| AC_MSG_CHECKING(for perl module $ax_perl_module) | ||
|
|
||
| # Would be nice to log result here, but can't rely on autoconf internals | ||
| $PERL -e "use $ax_perl_module; exit" > /dev/null 2>&1 | ||
| if test $? -ne 0; then | ||
| AC_MSG_RESULT(no); | ||
| ax_perl_modules_failed=1 | ||
| else | ||
| AC_MSG_RESULT(ok); | ||
| fi | ||
| done | ||
|
|
||
| # Run optional shell commands | ||
| if test "$ax_perl_modules_failed" = 0; then | ||
| : | ||
| $2 | ||
| else | ||
| : | ||
| $3 | ||
| fi | ||
| else | ||
| AC_MSG_WARN(could not find perl) | ||
| fi])dnl | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.