summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMark L. Woodward <mlwmohawk@php.net>2001-10-11 00:36:24 +0000
committerMark L. Woodward <mlwmohawk@php.net>2001-10-11 00:36:24 +0000
commitbb5398c6878264bc33b0d737f196f90343c748dc (patch)
tree75df21dd888fafab4b487d75458ed5646c12737a
parent1f3cd999e594469266cd24f8efeb66c38ca8db8a (diff)
downloadphp-git-bb5398c6878264bc33b0d737f196f90343c748dc.tar.gz
Allow msession to build without ext/session
-rw-r--r--ext/msession/README7
-rw-r--r--ext/msession/config.m44
-rw-r--r--ext/msession/msession.c8
3 files changed, 14 insertions, 5 deletions
diff --git a/ext/msession/README b/ext/msession/README
index 60cea7cdfa..d089d23008 100644
--- a/ext/msession/README
+++ b/ext/msession/README
@@ -8,13 +8,10 @@ Requirements:
Mohawk Software's Phoenix library.
Mohawk Software's msession daemon.
-
Building:
-I (regretfully) have not invested the time to make all
-this stuff automatic.
-
In the config.m4 file you will need to specify the include
and library directories for Phoenix. The setting in config.m4
is probably wrong.
-
+You will need phoenix installed and built to compile this
+module.
diff --git a/ext/msession/config.m4 b/ext/msession/config.m4
index c9953dccfb..61ebc7acd1 100644
--- a/ext/msession/config.m4
+++ b/ext/msession/config.m4
@@ -27,5 +27,9 @@ if test "$PHP_MSESSION" != "no"; then
PHP_SUBST(PHOENIX_LIB)
PHP_EXTENSION(msession, $ext_shared)
+
+ if test "$enable_session" != "no"; then
+ AC_DEFINE(HAVE_PHP_SESSION,1,[ ])
+ fi
fi
diff --git a/ext/msession/msession.c b/ext/msession/msession.c
index d3992f0f98..c329c95ec3 100644
--- a/ext/msession/msession.c
+++ b/ext/msession/msession.c
@@ -42,11 +42,14 @@ char g_msession[]="Msession";
#if HAVE_MSESSION
+#ifdef HAVE_PHP_SESSION
PS_FUNCS(msession);
ps_module ps_mod_msession = {
PS_MOD(msession)
};
+#endif
+
// #define ERR_DEBUG
@@ -123,7 +126,9 @@ PHP_MINIT_FUNCTION(msession)
g_conn = NULL;
g_host = g_defhost;
+#ifdef HAVE_PHP_SESSION
php_session_register_module(&ps_mod_msession);
+#endif
return SUCCESS;
}
@@ -983,6 +988,8 @@ PHP_FUNCTION(msession_plugin)
}
}
+#ifdef HAVE_PHP_SESSION
+
PS_OPEN_FUNC(msession)
{
ELOG( "ps_open_msession");
@@ -1031,4 +1038,5 @@ PS_GC_FUNC(msession)
ELOG( "ps_gc_msession");
return SUCCESS;
}
+#endif /* HAVE_PHP_SESSION */
#endif /* HAVE_MSESSION */