Show
Ignore:
Timestamp:
05/05/05 10:53:05 (4 years ago)
Author:
zoeloelip
Message:

This patch fixes some stuff concerning configuration. With this patch some parts that are forgotten with the
code split are fixed. They are also needed to compile eA with VC.
The other stuff make it possible to compile eA as a static module for php.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • eaccelerator/trunk/config.m4

    r64 r73  
     1AC_DEFUN([EA_REMOVE_IPC_TEST], [ 
     2  # for cygwin ipc error 
     3  if test -f conftest* ; then 
     4    echo $ECHO_N "Wait for conftest* to exit$ECHO_C" 
     5    while ! rm -f conftest* 2>/dev/null ; do 
     6      echo $ECHO_N ".$ECHO_C" 
     7      sleep 1 
     8    done 
     9    echo 
     10  fi 
     11]) 
     12 
    113AC_ARG_WITH(eaccelerator,[],[enable_eaccelerator=$withval]) 
    214 
     
    148160#define MM_SHM_IPC 
    149161#define MM_TEST_SHM 
    150 #include "mm.c" 
     162#include "$ext_srcdir/mm.c" 
    151163],dnl 
    152164    mm_shm_ipc=yes 
    153165    msg=yes,msg=no,msg=no) 
    154166  AC_MSG_RESULT([$msg]) 
     167  EA_REMOVE_IPC_TEST() 
    155168 
    156169  AC_MSG_CHECKING(for mmap shared memory support) 
     
    158171#define MM_SHM_MMAP_FILE 
    159172#define MM_TEST_SHM 
    160 #include "mm.c" 
     173#include "$ext_srcdir/mm.c" 
    161174],dnl 
    162175    mm_shm_mmap_file=yes 
     
    168181#define MM_SHM_MMAP_ZERO 
    169182#define MM_TEST_SHM 
    170 #include "mm.c" 
     183#include "$ext_srcdir/mm.c" 
    171184],dnl 
    172185    mm_shm_mmap_zero=yes 
     
    178191#define MM_SHM_MMAP_ANON 
    179192#define MM_TEST_SHM 
    180 #include "mm.c" 
     193#include "$ext_srcdir/mm.c" 
    181194],dnl 
    182195    mm_shm_mmap_anon=yes 
     
    188201#define MM_SHM_MMAP_POSIX 
    189202#define MM_TEST_SHM 
    190 #include "mm.c" 
     203#include "$ext_srcdir/mm.c" 
    191204],dnl 
    192205    mm_shm_mmap_posix=yes 
     
    210223    AC_DEFINE(MM_SHM_MMAP_FILE, 1, [Define if you like to use mmap on temporary file shared memory]) 
    211224    msg="mmap" 
    212   fi 
    213   AC_MSG_RESULT([$msg]) 
     225  else 
     226    msg="no" 
     227  fi 
     228  AC_MSG_RESULT([$msg]) 
     229  if test "$msg" = "no" ; then 
     230    AC_MSG_WARN([eaccelerator cannot detect shared memory type, which is required]) 
     231  fi 
    214232 
    215233  AC_MSG_CHECKING(for spinlock semaphores support) 
    216234  AC_TRY_RUN([#define MM_SEM_SPINLOCK 
    217235#define MM_TEST_SEM 
    218 #include "mm.c" 
     236#include "$ext_srcdir/mm.c" 
    219237],dnl 
    220238    mm_sem_spinlock=yes 
     
    225243  AC_TRY_RUN([#define MM_SEM_PTHREAD 
    226244#define MM_TEST_SEM 
    227 #include "mm.c" 
     245#include "$ext_srcdir/mm.c" 
    228246],dnl 
    229247    mm_sem_pthread=yes 
     
    234252  AC_TRY_RUN([#define MM_SEM_POSIX 
    235253#define MM_TEST_SEM 
    236 #include "mm.c" 
     254#include "$ext_srcdir/mm.c" 
    237255],dnl 
    238256    mm_sem_posix=yes 
     
    243261  AC_TRY_RUN([#define MM_SEM_IPC 
    244262#define MM_TEST_SEM 
    245 #include "mm.c" 
     263#include "$ext_srcdir/mm.c" 
    246264],dnl 
    247265    mm_sem_ipc=yes 
    248266    msg=yes,msg=no,msg=no) 
    249267  AC_MSG_RESULT([$msg]) 
     268  EA_REMOVE_IPC_TEST() 
    250269 
    251270  AC_MSG_CHECKING(for fcntl semaphores support) 
    252271  AC_TRY_RUN([#define MM_SEM_FCNTL 
    253272#define MM_TEST_SEM 
    254 #include "mm.c" 
     273#include "$ext_srcdir/mm.c" 
    255274],dnl 
    256275    mm_sem_fcntl=yes 
     
    261280  AC_TRY_RUN([#define MM_SEM_FLOCK 
    262281#define MM_TEST_SEM 
    263 #include "mm.c" 
     282#include "$ext_srcdir/mm.c" 
    264283],dnl 
    265284    mm_sem_flock=yes 
     
    286305    AC_DEFINE(MM_SEM_POSIX, 1, [Define if you like to use posix based semaphores]) 
    287306    msg="posix" 
    288   fi 
    289   AC_MSG_RESULT([$msg]) 
     307  else 
     308    msg="no" 
     309  fi 
     310  AC_MSG_RESULT([$msg]) 
     311  if test "$msg" = "no" ; then 
     312    AC_MSG_WARN([eaccelerator cannot semaphores type, which is required]) 
     313  fi 
    290314 
    291315  AC_CHECK_FUNC(sched_yield,[ 
     
    298322 
    299323  old_cppflags="$CPPFLAGS" 
    300   CPPFLAGS="$CPPFLAGS $INCLUDES
     324  CPPFLAGS="$CPPFLAGS $INCLUDES -I$abs_srcdir
    301325  AC_MSG_CHECKING(for ext/session/php_session.h) 
    302326  AC_TRY_CPP([#include "ext/session/php_session.h"],msg="yes",msg="no")