Return-Path: X-Original-To: apmail-httpd-cvs-archive@www.apache.org Delivered-To: apmail-httpd-cvs-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 31D03EB67 for ; Thu, 3 Jan 2013 07:23:51 +0000 (UTC) Received: (qmail 93016 invoked by uid 500); 3 Jan 2013 07:23:49 -0000 Delivered-To: apmail-httpd-cvs-archive@httpd.apache.org Received: (qmail 92808 invoked by uid 500); 3 Jan 2013 07:23:49 -0000 Mailing-List: contact cvs-help@httpd.apache.org; run by ezmlm Precedence: bulk Reply-To: dev@httpd.apache.org list-help: list-unsubscribe: List-Post: List-Id: Delivered-To: mailing list cvs@httpd.apache.org Received: (qmail 92776 invoked by uid 99); 3 Jan 2013 07:23:48 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 03 Jan 2013 07:23:48 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO eris.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 03 Jan 2013 07:23:47 +0000 Received: from eris.apache.org (localhost [127.0.0.1]) by eris.apache.org (Postfix) with ESMTP id 7120923888FE; Thu, 3 Jan 2013 07:23:27 +0000 (UTC) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r1428184 - /httpd/httpd/trunk/acinclude.m4 Date: Thu, 03 Jan 2013 07:23:27 -0000 To: cvs@httpd.apache.org From: kbrand@apache.org X-Mailer: svnmailer-1.0.8-patched Message-Id: <20130103072327.7120923888FE@eris.apache.org> X-Virus-Checked: Checked by ClamAV on apache.org Author: kbrand Date: Thu Jan 3 07:23:27 2013 New Revision: 1428184 URL: http://svn.apache.org/viewvc?rev=1428184&view=rev Log: Improve pkg-config usage for mod_ssl/ab: also use pkg-config for determining the -l flags (and fall back to a hardcoded default of "-lssl -lcrypto") add --static to pkg-config invocations, so that libraries for static linking are also taken into account (PR 54252 - note that the additional flags will only appear in modules/ssl/modules.mk and ab_LDFLAGS, so potential side effects are limited) separate --libs-only-L and --libs-only-other into two invocations (can't be used concurrently, only the first takes effect) use --silence-errors where applicable Modified: httpd/httpd/trunk/acinclude.m4 Modified: httpd/httpd/trunk/acinclude.m4 URL: http://svn.apache.org/viewvc/httpd/httpd/trunk/acinclude.m4?rev=1428184&r1=1428183&r2=1428184&view=diff ============================================================================== --- httpd/httpd/trunk/acinclude.m4 (original) +++ httpd/httpd/trunk/acinclude.m4 Thu Jan 3 07:23:27 2013 @@ -535,14 +535,17 @@ AC_DEFUN(APACHE_CHECK_OPENSSL,[ PKG_CONFIG_PATH="${ap_openssl_base}/lib/pkgconfig${PKG_CONFIG_PATH+:}${PKG_CONFIG_PATH}" export PKG_CONFIG_PATH fi - ap_openssl_libs="`$PKGCONFIG --libs-only-l openssl 2>&1`" + ap_openssl_libs="`$PKGCONFIG --libs-only-l --static --silence-errors openssl`" if test $? -eq 0; then ap_openssl_found="yes" pkglookup="`$PKGCONFIG --cflags-only-I openssl`" APR_ADDTO(CPPFLAGS, [$pkglookup]) APR_ADDTO(MOD_CFLAGS, [$pkglookup]) APR_ADDTO(ab_CFLAGS, [$pkglookup]) - pkglookup="`$PKGCONFIG --libs-only-L --libs-only-other openssl`" + pkglookup="`$PKGCONFIG --libs-only-L --static openssl`" + APR_ADDTO(LDFLAGS, [$pkglookup]) + APR_ADDTO(MOD_LDFLAGS, [$pkglookup]) + pkglookup="`$PKGCONFIG --libs-only-other --static openssl`" APR_ADDTO(LDFLAGS, [$pkglookup]) APR_ADDTO(MOD_LDFLAGS, [$pkglookup]) fi @@ -575,7 +578,7 @@ AC_DEFUN(APACHE_CHECK_OPENSSL,[ [AC_MSG_RESULT(FAILED)]) if test "x$ac_cv_openssl" = "xyes"; then - ap_openssl_libs="-lssl -lcrypto `$apr_config --libs`" + ap_openssl_libs="${ap_openssl_libs:--lssl -lcrypto} `$apr_config --libs`" APR_ADDTO(MOD_LDFLAGS, [$ap_openssl_libs]) APR_ADDTO(LIBS, [$ap_openssl_libs]) APR_SETVAR(ab_LDFLAGS, [$MOD_LDFLAGS])