Skip to content

Commit

Permalink
m4/ax_check_openssl.m4: run pkg-config tests even if --with-openssl i…
Browse files Browse the repository at this point in the history
…s given, if it wasn't given a path

configure: update version to 2.1.3

Reported-By: Wade Cline <[email protected]>
  • Loading branch information
aaronmdjones committed Sep 15, 2017
1 parent 9a92be2 commit 2f8f6a3
Show file tree
Hide file tree
Showing 3 changed files with 54 additions and 61 deletions.
67 changes: 31 additions & 36 deletions configure
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
# Generated by GNU Autoconf 2.69 for libmowgli-2 2.1.2.
# Generated by GNU Autoconf 2.69 for libmowgli-2 2.1.3.
#
# Report bugs to <https://github.com/atheme/libmowgli-2>.
#
Expand Down Expand Up @@ -580,8 +580,8 @@ MAKEFLAGS=
# Identity of this package.
PACKAGE_NAME='libmowgli-2'
PACKAGE_TARNAME='libmowgli-2'
PACKAGE_VERSION='2.1.2'
PACKAGE_STRING='libmowgli-2 2.1.2'
PACKAGE_VERSION='2.1.3'
PACKAGE_STRING='libmowgli-2 2.1.3'
PACKAGE_BUGREPORT='https://github.com/atheme/libmowgli-2'
PACKAGE_URL=''

Expand Down Expand Up @@ -1295,7 +1295,7 @@ if test "$ac_init_help" = "long"; then
# Omit some internal or obsolete options to make the list less imposing.
# This message is too long to be a string in the A/UX 3.1 sh.
cat <<_ACEOF
\`configure' configures libmowgli-2 2.1.2 to adapt to many kinds of systems.
\`configure' configures libmowgli-2 2.1.3 to adapt to many kinds of systems.
Usage: $0 [OPTION]... [VAR=VALUE]...
Expand Down Expand Up @@ -1362,7 +1362,7 @@ fi

if test -n "$ac_init_help"; then
case $ac_init_help in
short | recursive ) echo "Configuration of libmowgli-2 2.1.2:";;
short | recursive ) echo "Configuration of libmowgli-2 2.1.3:";;
esac
cat <<\_ACEOF
Expand Down Expand Up @@ -1455,7 +1455,7 @@ fi
test -n "$ac_init_help" && exit $ac_status
if $ac_init_version; then
cat <<\_ACEOF
libmowgli-2 configure 2.1.2
libmowgli-2 configure 2.1.3
generated by GNU Autoconf 2.69
Copyright (C) 2012 Free Software Foundation, Inc.
Expand Down Expand Up @@ -1824,7 +1824,7 @@ cat >config.log <<_ACEOF
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.
It was created by libmowgli-2 $as_me 2.1.2, which was
It was created by libmowgli-2 $as_me 2.1.3, which was
generated by GNU Autoconf 2.69. Invocation command line was
$ $0 $@
Expand Down Expand Up @@ -4511,28 +4511,28 @@ OPENSSL="no"
found=false
skip=false
founddir=
ssldirs=
# Check whether --with-openssl was given.
if test "${with_openssl+set}" = set; then :
withval=$with_openssl;
case "$withval" in
"")
as_fn_error $? "Empty --with-openssl value" "$LINENO" 5
;;
n | no | N | NO)
skip=true
;;
y | ye | yes | Y | YE | YES)
y | ye | yes | Y | YE | YES | "")
;;
*) ssldirs="$withval"
*)
ssldirs="$withval"
;;
esac
else
fi
# if pkg-config is installed and openssl has installed a .pc file,
# then use that information and don't search ssldirs
# Extract the first word of "pkg-config", so it can be a program name with args.
# if pkg-config is installed and openssl has installed a .pc file,
# then use that information and don't search ssldirs
# Extract the first word of "pkg-config", so it can be a program name with args.
set dummy pkg-config; ac_word=$2
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
$as_echo_n "checking for $ac_word... " >&6; }
Expand Down Expand Up @@ -4572,25 +4572,20 @@ $as_echo "no" >&6; }
fi
if test x"$PKG_CONFIG" != x""; then
OPENSSL_LDFLAGS=`$PKG_CONFIG openssl --libs-only-L 2>/dev/null`
if test $? = 0; then
OPENSSL_LIBS=`$PKG_CONFIG openssl --libs-only-l 2>/dev/null`
OPENSSL_INCLUDES=`$PKG_CONFIG openssl --cflags-only-I 2>/dev/null`
founddir=`$PKG_CONFIG openssl --variable=includedir 2>/dev/null`
found=true
fi
fi
# no such luck; use some default ssldirs
if ! $found; then
ssldirs="/usr/local/ssl /usr/lib/ssl /usr/ssl /usr/pkg /usr/local /usr"
fi
fi
if test x"$ssldirs" = x"" && test x"$PKG_CONFIG" != x""; then
OPENSSL_LDFLAGS=`$PKG_CONFIG openssl --libs-only-L 2>/dev/null`
if test $? = 0; then
OPENSSL_LIBS=`$PKG_CONFIG openssl --libs-only-l 2>/dev/null`
OPENSSL_INCLUDES=`$PKG_CONFIG openssl --cflags-only-I 2>/dev/null`
founddir=`$PKG_CONFIG openssl --variable=includedir 2>/dev/null`
found=true
fi
fi
# no such luck; use some default ssldirs
if ! $found; then
ssldirs="/usr/local/ssl /usr/lib/ssl /usr/ssl /usr/pkg /usr/local /usr"
fi
# note that we #include <openssl/foo.h>, so the OpenSSL headers have to be in
# an 'openssl' subdirectory
Expand Down Expand Up @@ -5334,7 +5329,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
# report actual input values of CONFIG_FILES etc. instead of their
# values after options handling.
ac_log="
This file was extended by libmowgli-2 $as_me 2.1.2, which was
This file was extended by libmowgli-2 $as_me 2.1.3, which was
generated by GNU Autoconf 2.69. Invocation command line was
CONFIG_FILES = $CONFIG_FILES
Expand Down Expand Up @@ -5396,7 +5391,7 @@ _ACEOF
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
ac_cs_version="\\
libmowgli-2 config.status 2.1.2
libmowgli-2 config.status 2.1.3
configured by $0, generated by GNU Autoconf 2.69,
with options \\"\$ac_cs_config\\"
Expand Down
2 changes: 1 addition & 1 deletion configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
# Process this file with autoconf to produce a configure script.

AC_PREREQ([2.69])
AC_INIT([libmowgli-2],[2.1.2],[https://github.com/atheme/libmowgli-2])
AC_INIT([libmowgli-2],[2.1.3],[https://github.com/atheme/libmowgli-2])
AC_CONFIG_SRCDIR([src])
AC_CONFIG_HEADER([src/libmowgli/platform/autoconf.h])

Expand Down
46 changes: 22 additions & 24 deletions m4/ax_check_openssl.m4
Original file line number Diff line number Diff line change
Expand Up @@ -39,43 +39,41 @@ AC_DEFUN([AX_CHECK_OPENSSL], [
found=false
skip=false
founddir=
ssldirs=
AC_ARG_WITH([openssl],
[AS_HELP_STRING([--with-openssl=DIR],
[root of the OpenSSL directory])],
[
case "$withval" in
"")
AC_MSG_ERROR([Empty --with-openssl value])
;;
n | no | N | NO)
skip=true
;;
y | ye | yes | Y | YE | YES)
y | ye | yes | Y | YE | YES | "")
;;
*) ssldirs="$withval"
*)
ssldirs="$withval"
;;
esac
], [
# if pkg-config is installed and openssl has installed a .pc file,
# then use that information and don't search ssldirs
AC_PATH_PROG([PKG_CONFIG], [pkg-config])
if test x"$PKG_CONFIG" != x""; then
OPENSSL_LDFLAGS=`$PKG_CONFIG openssl --libs-only-L 2>/dev/null`
if test $? = 0; then
OPENSSL_LIBS=`$PKG_CONFIG openssl --libs-only-l 2>/dev/null`
OPENSSL_INCLUDES=`$PKG_CONFIG openssl --cflags-only-I 2>/dev/null`
founddir=`$PKG_CONFIG openssl --variable=includedir 2>/dev/null`
found=true
fi
fi
], []
)
# no such luck; use some default ssldirs
if ! $found; then
ssldirs="/usr/local/ssl /usr/lib/ssl /usr/ssl /usr/pkg /usr/local /usr"
fi
]
)
# if pkg-config is installed and openssl has installed a .pc file,
# then use that information and don't search ssldirs
AC_PATH_PROG([PKG_CONFIG], [pkg-config])
if test x"$ssldirs" = x"" && test x"$PKG_CONFIG" != x""; then
OPENSSL_LDFLAGS=`$PKG_CONFIG openssl --libs-only-L 2>/dev/null`
if test $? = 0; then
OPENSSL_LIBS=`$PKG_CONFIG openssl --libs-only-l 2>/dev/null`
OPENSSL_INCLUDES=`$PKG_CONFIG openssl --cflags-only-I 2>/dev/null`
founddir=`$PKG_CONFIG openssl --variable=includedir 2>/dev/null`
found=true
fi
fi
# no such luck; use some default ssldirs
if ! $found; then
ssldirs="/usr/local/ssl /usr/lib/ssl /usr/ssl /usr/pkg /usr/local /usr"
fi
# note that we #include <openssl/foo.h>, so the OpenSSL headers have to be in
# an 'openssl' subdirectory
Expand Down

0 comments on commit 2f8f6a3

Please sign in to comment.