forked from premiere/premiere-libtorrent
updated openssl m4 script
This commit is contained in:
parent
6a5806bfd2
commit
fc36d27a59
|
@ -1,5 +1,5 @@
|
|||
# ===========================================================================
|
||||
# http://www.nongnu.org/autoconf-archive/ax_check_openssl.html
|
||||
# http://www.gnu.org/software/autoconf-archive/ax_check_openssl.html
|
||||
# ===========================================================================
|
||||
#
|
||||
# SYNOPSIS
|
||||
|
@ -24,21 +24,22 @@
|
|||
#
|
||||
# LICENSE
|
||||
#
|
||||
# Copyright (c) 2009 Zmanda Inc. <http://www.zmanda.com/>
|
||||
# Copyright (c) 2009 Dustin J. Mitchell <dustin@zmanda.com>
|
||||
# Copyright (c) 2009, 2010 Zmanda Inc. <http://www.zmanda.com/>
|
||||
# Copyright (c) 2009, 2010 Dustin J. Mitchell <dustin@zmanda.com>
|
||||
#
|
||||
# Copying and distribution of this file, with or without modification, are
|
||||
# permitted in any medium without royalty provided the copyright notice
|
||||
# and this notice are preserved.
|
||||
# and this notice are preserved. This file is offered as-is, without any
|
||||
# warranty.
|
||||
|
||||
#serial 6
|
||||
|
||||
AU_ALIAS([CHECK_SSL], [AX_CHECK_OPENSSL])
|
||||
AC_DEFUN([AX_CHECK_OPENSSL],
|
||||
[AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl
|
||||
|
||||
AC_DEFUN([AX_CHECK_OPENSSL], [
|
||||
found=false
|
||||
AC_ARG_WITH(openssl,
|
||||
AS_HELP_STRING([--with-openssl@<:@=DIR@:>@],
|
||||
[specify root directory for OpenSSL library]),
|
||||
AS_HELP_STRING([--with-openssl=DIR],
|
||||
[root of the OpenSSL directory]),
|
||||
[
|
||||
case "$withval" in
|
||||
"" | y | ye | yes | n | no)
|
||||
|
@ -50,8 +51,8 @@ AC_DEFUN([AX_CHECK_OPENSSL],
|
|||
], [
|
||||
# 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
|
||||
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`
|
||||
|
@ -77,7 +78,7 @@ AC_DEFUN([AX_CHECK_OPENSSL],
|
|||
AC_MSG_CHECKING([for openssl/ssl.h in $ssldir])
|
||||
if test -f "$ssldir/include/openssl/ssl.h"; then
|
||||
OPENSSL_INCLUDES="-I$ssldir/include"
|
||||
OPENSSL_LDFLAGS="-L $ssldir/lib"
|
||||
OPENSSL_LDFLAGS="-L$ssldir/lib"
|
||||
OPENSSL_LIBS="-lssl -lcrypto"
|
||||
found=true
|
||||
AC_MSG_RESULT([yes])
|
||||
|
|
Loading…
Reference in New Issue