Annotation of sql/oracle/configure.in, revision 1.35
1.28 moko 1: dnl Autoconf initialisation
2: AC_PREREQ(2.59)
3: AC_INIT(parser3, 10.2)
4: AC_CONFIG_SRCDIR(parser3oracle.C)
1.1 parser 5: AM_CONFIG_HEADER(config_auto.h)
6:
1.28 moko 7: dnl Automake Initialisation
8: AM_INIT_AUTOMAKE
9:
1.1 parser 10: dnl Arguments
1.2 parser 11: AC_ARG_WITH(oracleoci-inc,[ --with-oracleoci-inc[=DIR] DIR is the Oracle OCI includes directory],,
1.1 parser 12: withval="$ORACLE_HOME/rdbms/demo"
13: )
1.28 moko 14:
1.2 parser 15: ORACLE_OCI_INC=$withval
16: AC_SUBST(ORACLE_OCI_INC)
1.1 parser 17:
1.2 parser 18: if test \! -f "$ORACLE_OCI_INC/oci.h"; then
19: AC_MSG_ERROR($ORACLE_OCI_INC does not seem to be valid Oracle OCI includes directory)
20: fi
21:
22: AC_ARG_WITH(oraclepublic-inc,[ --with-oraclepublic-inc[=DIR] DIR is the Oracle public includes directory],,
1.1 parser 23: withval="$ORACLE_HOME/network/public"
24: )
1.28 moko 25:
1.2 parser 26: ORACLE_PUBLIC_INC=$withval
27: AC_SUBST(ORACLE_PUBLIC_INC)
28:
29: if test \! -f "$ORACLE_PUBLIC_INC/nzt.h"; then
30: AC_MSG_ERROR($ORACLE_PUBLIC_INC does not seem to be valid Oracle public includes directory)
31: fi
1.1 parser 32:
1.28 moko 33: dnl Checks for programs
1.1 parser 34: AC_PROG_INSTALL
1.17 paf 35: AC_PROG_CXX
36: AC_PROG_CC
37:
1.28 moko 38: dnl Enable building of the convenience library
39: LT_CONFIG_LTDL_DIR(libltdl)
1.35 ! moko 40: LT_INIT(disable-static dlopen win32-dll)
1.28 moko 41: LTDL_INIT
1.1 parser 42:
1.28 moko 43: dnl Checks for libraries
1.1 parser 44:
1.28 moko 45: dnl Checks for header files
1.1 parser 46: AC_CHECK_HEADERS(
47: stdio.h \
48: stdlib.h \
49: string.h \
50: setjmp.h \
1.4 paf 51: ctype.h \
52: setjmp.h
1.1 parser 53: )
54:
1.6 paf 55: AC_MSG_CHECKING(for BSD setenv/getenv/unsetenv)
1.19 paf 56: AC_TRY_LINK(
1.6 paf 57: #ifdef HAVE_STDLIB_H
58: # include <stdlib.h>
59: #endif
60: #ifdef HAVE_STRING_H
61: # include <string.h>
62: #endif
63: ,
64: #define TEST_NAME "oracle-configure-test-var"
65: #define TEST_VALUE "oracle-configure-test-value"
66: int result=setenv(TEST_NAME, TEST_VALUE, 1/*overwrite*/);
67: char *getenv_value=getenv(TEST_NAME);
68: if(!getenv_value)
69: return 1;
70: if(strcmp(getenv_value, TEST_VALUE)!=0)
71: return 2;
72: unsetenv(TEST_NAME);
73: ,[
1.25 misha 74: AC_MSG_RESULT(yes)
1.6 paf 75: AC_DEFINE(HAVE_SETENV,,library has BSD setenv/unsetenv)
76: ],
1.25 misha 77: AC_MSG_RESULT(no)
1.6 paf 78:
1.25 misha 79: AC_MSG_CHECKING(for POSIX putenv/getenv)
80: AC_TRY_LINK(
81: #ifdef HAVE_STDLIB_H
82: # include <stdlib.h>
83: #endif
84: #ifdef HAVE_STRING_H
85: # include <string.h>
86: #endif
87: ,
88: #define TEST_NAME "oracle-configure-test-var"
89: #define TEST_VALUE "oracle-configure-test-value"
90: int result=putenv(TEST_NAME"="TEST_VALUE);
91: char *getenv_value=getenv(TEST_NAME);
92: if(!getenv_value)
93: return 1;
94: if(strcmp(getenv_value, TEST_NAME)!=0)
95: return 2;
96: ,[
97: AC_MSG_RESULT(yes)
98: AC_DEFINE(HAVE_PUTENV,,library has POSIX putenv)
99: ],
100: AC_MSG_RESULT(no)
101: AC_MSG_ERROR("there must be some function to modify environment")
102: )
1.6 paf 103: )
104:
1.28 moko 105: dnl Checks for typedefs, structures, and compiler characteristics
1.1 parser 106: AC_TYPE_SIZE_T
107:
1.28 moko 108: dnl Checks for library functions
1.1 parser 109:
110: dnl Output makefiles
1.11 paf 111: AC_OUTPUT(Makefile)
E-mail: