aboutsummaryrefslogtreecommitdiff
path: root/m4
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2016-11-28 15:40:02 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2016-11-28 15:40:02 +0200
commitede47339e7c3893eb4c9f04985d8271f22c4397d (patch)
tree80a18613530a238fb9aeae6f20bdadbc75b48cdc /m4
parent2fb7a2f0ef92360be1b2834a190904954104dc9e (diff)
Update to better support new instant client installation layout (autotools)
Diffstat (limited to 'm4')
-rw-r--r--m4/liboci.m426
1 files changed, 25 insertions, 1 deletions
diff --git a/m4/liboci.m4 b/m4/liboci.m4
index 7d9cb52..0d180bf 100644
--- a/m4/liboci.m4
+++ b/m4/liboci.m4
@@ -112,12 +112,36 @@ main ()
oci_found=yes
])
+ # Try the new Instant Client layout.
+ #
+ if test x"$oci_found" = xno; then
+ CPPFLAGS="$CPPFLAGS -I$ORACLE_HOME/include"
+ LDFLAGS="$LDFLAGS -L$ORACLE_HOME/lib"
+ LIBS="-lclntsh $LIBS"
+
+ CXX_LIBTOOL_LINK_IFELSE([
+AC_LANG_SOURCE([
+#include <oci.h>
+
+int
+main ()
+{
+ OCIEnv* env (0);
+ OCIEnvNlsCreate (&env, OCI_THREADED, 0, 0, 0, 0, 0, 0, 0, 0);
+ OCIHandleFree (env, OCI_HTYPE_ENV);
+ return 0;
+}
+])],
+[
+oci_found=yes
+])
+ fi
+
if test x"$oci_found" = xno; then
CPPFLAGS="$save_CPPFLAGS"
LDFLAGS="$save_LDFLAGS"
LIBS="$save_LIBS"
fi
-
fi
fi