You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@apr.apache.org by co...@apache.org on 2011/05/09 02:41:01 UTC

svn commit: r1100853 - /apr/apr-util/branches/1.3.x/build/dbd.m4

Author: covener
Date: Mon May  9 00:41:00 2011
New Revision: 1100853

URL: http://svn.apache.org/viewvc?rev=1100853&view=rev
Log:
backport r1100848 from trunk:

PR51071: check the --with-odbc arg to see if it's an executable file
(odbc_config itself) before defaulting to using it as a prefix for
libs/includes.

Required for getting the right architecture odbc
on AIX packaging, which share a prefix.

Modified:
    apr/apr-util/branches/1.3.x/build/dbd.m4

Modified: apr/apr-util/branches/1.3.x/build/dbd.m4
URL: http://svn.apache.org/viewvc/apr/apr-util/branches/1.3.x/build/dbd.m4?rev=1100853&r1=1100852&r2=1100853&view=diff
==============================================================================
--- apr/apr-util/branches/1.3.x/build/dbd.m4 (original)
+++ apr/apr-util/branches/1.3.x/build/dbd.m4 Mon May  9 00:41:00 2011
@@ -505,8 +505,14 @@ AC_DEFUN([APU_CHECK_DBD_ODBC], [
         odbc_LDFLAGS="-L`$ODBC_CONFIG --lib-prefix`"
         odbc_LIBS="`$ODBC_CONFIG --libs`"
       else
-        odbc_CPPFLAGS="-I$withval/include"
-        odbc_LDFLAGS="-L$withval/lib "
+        if test -f "$withval" && test -x "$withval"; then 
+          odbc_CPPFLAGS="-I`$withval --include-prefix`"
+          odbc_LDFLAGS="-L`$withval --lib-prefix`"
+          odbc_LIBS="`$withval --libs`"
+        else
+          odbc_CPPFLAGS="-I$withval/include"
+          odbc_LDFLAGS="-L$withval/lib "
+        fi
       fi
 
       APR_ADDTO(CPPFLAGS, [$odbc_CPPFLAGS])