Browse Source

merged r466 from b1.2: support shm-malloc only on --enable-xcache-test

git-svn-id: svn://svn.lighttpd.net/xcache/trunk@470 c26eb9a1-5813-0410-bd6c-c2e55f420ca7
3.0
Xuefer 14 years ago
parent
commit
8d96b47ea3
  1. 2
      config.m4
  2. 2
      config.w32
  3. 4
      xc_shm.c

2
config.m4

@ -27,7 +27,6 @@ if test "$PHP_XCACHE" != "no"; then
xcache.c \
mmap.c \
mem.c \
xc_malloc.c \
xc_shm.c \
const_string.c \
opcode_spec.c \
@ -51,6 +50,7 @@ if test "$PHP_XCACHE" != "no"; then
[ --enable-xcache-test XCache: Enable self test - FOR DEVELOPERS ONLY!!], no, no)
if test "$PHP_XCACHE_TEST" != "no"; then
XCACHE_ENABLE_TEST=-DXCACHE_ENABLE_TEST
xcache_sources="$xcache_sources xc_malloc.c"
AC_DEFINE([HAVE_XCACHE_TEST], 1, [Define to enable XCache self test])
else
XCACHE_ENABLE_TEST=

2
config.w32

@ -15,7 +15,6 @@ if (PHP_XCACHE != "no") {
xcache.c \
mmap.c \
mem.c \
xc_malloc.c \
xc_shm.c \
const_string.c \
opcode_spec.c \
@ -113,6 +112,7 @@ if (PHP_XCACHE != "no") {
ARG_ENABLE("xcache-test", "XCache: Enable self test - FOR DEVELOPERS ONLY!!", "no");
if (PHP_XCACHE_TEST != "no") {
ADD_FLAG("XCACHE_ENABLE_TEST", "-DXCACHE_ENABLE_TEST");
xcache_sources += " xc_malloc.c";
AC_DEFINE("HAVE_XCACHE_TEST", 1, "Define to enable XCache self test");
}
else {

4
xc_shm.c

@ -19,12 +19,16 @@ static xc_shm_scheme_t xc_shm_schemes[10];
void xc_shm_init_modules() /* {{{ */
{
extern void xc_shm_mem_init();
#ifdef HAVE_XCACHE_TEST
extern void xc_shm_malloc_register();
#endif
extern void xc_shm_mmap_register();
memset(xc_shm_schemes, 0, sizeof(xc_shm_schemes));
xc_shm_mem_init();
#ifdef HAVE_XCACHE_TEST
xc_shm_malloc_register();
#endif
xc_shm_mmap_register();
}
/* }}} */

Loading…
Cancel
Save