summaryrefslogtreecommitdiff
path: root/ext/interbase
diff options
context:
space:
mode:
authorSascha Schumann <sas@php.net>2000-05-02 04:26:22 +0000
committerSascha Schumann <sas@php.net>2000-05-02 04:26:22 +0000
commitdca0d3f4544bcd2219a68c33b1376d08753e0480 (patch)
treed950ab1f1b52ce8a25fc5970c6ce5cdd9886fc73 /ext/interbase
parent82c5c690c9813fe8f5abe790947be8065968b05b (diff)
downloadphp-git-dca0d3f4544bcd2219a68c33b1376d08753e0480.tar.gz
Make interbase compilable as shared module
Diffstat (limited to 'ext/interbase')
-rw-r--r--ext/interbase/Makefile.in2
-rw-r--r--ext/interbase/config.m439
2 files changed, 17 insertions, 24 deletions
diff --git a/ext/interbase/Makefile.in b/ext/interbase/Makefile.in
index a2ccc12f11..bb2176afad 100644
--- a/ext/interbase/Makefile.in
+++ b/ext/interbase/Makefile.in
@@ -1,5 +1,7 @@
LTLIBRARY_NAME = libinterbase.la
LTLIBRARY_SOURCES = interbase.c
+LTLIBRARY_SHARED_NAME = interbase.la
+LTLIBRARY_SHARED_LIBADD = $(INTERBASE_SHARED_LIBADD)
include $(top_srcdir)/build/dynlib.mk
diff --git a/ext/interbase/config.m4 b/ext/interbase/config.m4
index f79fa94695..c3a266d651 100644
--- a/ext/interbase/config.m4
+++ b/ext/interbase/config.m4
@@ -1,29 +1,20 @@
dnl $Id$
-AC_MSG_CHECKING(for InterBase support)
-AC_ARG_WITH(interbase,
+PHP_ARG_WITH(interbase,for InterBase support,
[ --with-interbase[=DIR] Include InterBase support. DIR is the InterBase base
- install directory, defaults to /usr/interbase],
-[
- if test "$withval" != "no"; then
- if test "$withval" = "yes"; then
- IBASE_INCDIR=/usr/interbase/include
- IBASE_LIBDIR=/usr/interbase/lib
- else
- IBASE_INCDIR=$withval/include
- IBASE_LIBDIR=$withval/lib
- fi
- IBASE_INCLUDE=-I$IBASE_INCDIR
- IBASE_LFLAGS=-L$IBASE_LIBDIR
- IBASE_LIBS="-lgds"
- AC_DEFINE(HAVE_IBASE,1,[ ])
- AC_MSG_RESULT(yes)
- EXTRA_LIBS="$EXTRA_LIBS $IBASE_LFLAGS $IBASE_LIBS"
- INCLUDES="$INCLUDES $IBASE_INCLUDE"
- PHP_EXTENSION(interbase)
+ install directory, defaults to /usr/interbase])
+
+if test "$PHP_INTERBASE" != "no"; then
+ if test "$PHP_INTERBASE" = "yes"; then
+ IBASE_INCDIR=/usr/interbase/include
+ IBASE_LIBDIR=/usr/interbase/lib
else
- AC_MSG_RESULT(no)
+ IBASE_INCDIR=$PHP_INTERBASE/include
+ IBASE_LIBDIR=$PHP_INTERBASE/lib
fi
-],[
- AC_MSG_RESULT(no)
-])
+ AC_ADD_LIBRARY_WITH_PATH(gds, $IBASE_LIBDIR, INTERBASE_SHARED_LIBADD)
+ AC_ADD_INCLUDE($IBASE_INCDIR)
+ AC_DEFINE(HAVE_IBASE,1,[ ])
+ PHP_EXTENSION(interbase, $ext_shared)
+ PHP_SUBST(INTERBASE_SHARED_LIBADD)
+fi