mirror of
https://github.com/asterisk/asterisk.git
synced 2025-09-25 07:01:09 +00:00
If lua is detected with the lua5.1 prefix (or not), adjust the include path accordingly.
Based upon feedback to a release announcement on the -users list. See http://lists.digium.com/pipermail/asterisk-users/2009-August/236954.html git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@214819 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
@@ -1494,6 +1494,10 @@ if test "${PBX_PWLIB}" = "1" -a "${USE_OPENH323}" != "no" ; then
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
AST_EXT_LIB_CHECK([LUA], [lua5.1], [luaL_newstate], [lua5.1/lua.h], [-lm])
|
AST_EXT_LIB_CHECK([LUA], [lua5.1], [luaL_newstate], [lua5.1/lua.h], [-lm])
|
||||||
|
if test "x${PBX_LUA}" = "x1" ; then
|
||||||
|
AC_DEFINE_UNQUOTED([LUA51_PREFIX], [1], [Define to 1 if lua is found with a lua5.1 prefix])
|
||||||
|
fi
|
||||||
|
|
||||||
# Some distributions (like SuSE) remove the 5.1 suffix.
|
# Some distributions (like SuSE) remove the 5.1 suffix.
|
||||||
AST_EXT_LIB_CHECK([LUA], [lua], [luaL_register], [lua.h], [-lm])
|
AST_EXT_LIB_CHECK([LUA], [lua], [luaL_register], [lua.h], [-lm])
|
||||||
|
|
||||||
|
@@ -1225,6 +1225,9 @@
|
|||||||
slash. */
|
slash. */
|
||||||
#undef LSTAT_FOLLOWS_SLASHED_SYMLINK
|
#undef LSTAT_FOLLOWS_SLASHED_SYMLINK
|
||||||
|
|
||||||
|
/* Define to 1 if lua is found with a lua5.1 prefix */
|
||||||
|
#undef LUA51_PREFIX
|
||||||
|
|
||||||
/* Build chan_misdn for mISDN 1.2 or later. */
|
/* Build chan_misdn for mISDN 1.2 or later. */
|
||||||
#undef MISDN_1_2
|
#undef MISDN_1_2
|
||||||
|
|
||||||
@@ -1243,6 +1246,9 @@
|
|||||||
/* Define to the version of this package. */
|
/* Define to the version of this package. */
|
||||||
#undef PACKAGE_VERSION
|
#undef PACKAGE_VERSION
|
||||||
|
|
||||||
|
/* Define to 1 if the C compiler supports function prototypes. */
|
||||||
|
#undef PROTOTYPES
|
||||||
|
|
||||||
/* Define to necessary symbol if this constant uses a non-standard name on
|
/* Define to necessary symbol if this constant uses a non-standard name on
|
||||||
your system. */
|
your system. */
|
||||||
#undef PTHREAD_CREATE_JOINABLE
|
#undef PTHREAD_CREATE_JOINABLE
|
||||||
@@ -1259,6 +1265,11 @@
|
|||||||
/* Define to the type of arg 5 for `select'. */
|
/* Define to the type of arg 5 for `select'. */
|
||||||
#undef SELECT_TYPE_ARG5
|
#undef SELECT_TYPE_ARG5
|
||||||
|
|
||||||
|
/* Define to 1 if the `setvbuf' function takes the buffering type as its
|
||||||
|
second argument and the buffer pointer as the third, as on System V before
|
||||||
|
release 3. */
|
||||||
|
#undef SETVBUF_REVERSED
|
||||||
|
|
||||||
/* The size of `int', as computed by sizeof. */
|
/* The size of `int', as computed by sizeof. */
|
||||||
#undef SIZEOF_INT
|
#undef SIZEOF_INT
|
||||||
|
|
||||||
@@ -1279,30 +1290,20 @@
|
|||||||
/* Define to 1 if your <sys/time.h> declares `struct tm'. */
|
/* Define to 1 if your <sys/time.h> declares `struct tm'. */
|
||||||
#undef TM_IN_SYS_TIME
|
#undef TM_IN_SYS_TIME
|
||||||
|
|
||||||
/* Enable extensions on AIX 3, Interix. */
|
/* Define to 1 if on AIX 3.
|
||||||
|
System headers sometimes define this.
|
||||||
|
We just want to avoid a redefinition error message. */
|
||||||
#ifndef _ALL_SOURCE
|
#ifndef _ALL_SOURCE
|
||||||
# undef _ALL_SOURCE
|
# undef _ALL_SOURCE
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
/* Number of bits in a file offset, on hosts where this is settable. */
|
||||||
|
#undef _FILE_OFFSET_BITS
|
||||||
|
|
||||||
/* Enable GNU extensions on systems that have them. */
|
/* Enable GNU extensions on systems that have them. */
|
||||||
#ifndef _GNU_SOURCE
|
#ifndef _GNU_SOURCE
|
||||||
# undef _GNU_SOURCE
|
# undef _GNU_SOURCE
|
||||||
#endif
|
#endif
|
||||||
/* Enable threading extensions on Solaris. */
|
|
||||||
#ifndef _POSIX_PTHREAD_SEMANTICS
|
|
||||||
# undef _POSIX_PTHREAD_SEMANTICS
|
|
||||||
#endif
|
|
||||||
/* Enable extensions on HP NonStop. */
|
|
||||||
#ifndef _TANDEM_SOURCE
|
|
||||||
# undef _TANDEM_SOURCE
|
|
||||||
#endif
|
|
||||||
/* Enable general extensions on Solaris. */
|
|
||||||
#ifndef __EXTENSIONS__
|
|
||||||
# undef __EXTENSIONS__
|
|
||||||
#endif
|
|
||||||
|
|
||||||
|
|
||||||
/* Number of bits in a file offset, on hosts where this is settable. */
|
|
||||||
#undef _FILE_OFFSET_BITS
|
|
||||||
|
|
||||||
/* Define to 1 to make fseeko visible on some hosts (e.g. glibc 2.2). */
|
/* Define to 1 to make fseeko visible on some hosts (e.g. glibc 2.2). */
|
||||||
#undef _LARGEFILE_SOURCE
|
#undef _LARGEFILE_SOURCE
|
||||||
@@ -1320,6 +1321,20 @@
|
|||||||
/* Define to 1 if you need to in order for `stat' and other things to work. */
|
/* Define to 1 if you need to in order for `stat' and other things to work. */
|
||||||
#undef _POSIX_SOURCE
|
#undef _POSIX_SOURCE
|
||||||
|
|
||||||
|
/* Enable extensions on Solaris. */
|
||||||
|
#ifndef __EXTENSIONS__
|
||||||
|
# undef __EXTENSIONS__
|
||||||
|
#endif
|
||||||
|
#ifndef _POSIX_PTHREAD_SEMANTICS
|
||||||
|
# undef _POSIX_PTHREAD_SEMANTICS
|
||||||
|
#endif
|
||||||
|
#ifndef _TANDEM_SOURCE
|
||||||
|
# undef _TANDEM_SOURCE
|
||||||
|
#endif
|
||||||
|
|
||||||
|
/* Define like PROTOTYPES; this can be used by system headers. */
|
||||||
|
#undef __PROTOTYPES
|
||||||
|
|
||||||
/* Define to empty if `const' does not conform to ANSI C. */
|
/* Define to empty if `const' does not conform to ANSI C. */
|
||||||
#undef const
|
#undef const
|
||||||
|
|
||||||
|
@@ -42,9 +42,15 @@ ASTERISK_FILE_VERSION(__FILE__, "$Revision$")
|
|||||||
#include "asterisk/paths.h"
|
#include "asterisk/paths.h"
|
||||||
#include "asterisk/hashtab.h"
|
#include "asterisk/hashtab.h"
|
||||||
|
|
||||||
|
#ifdef LUA51_PREFIX
|
||||||
#include <lua5.1/lua.h>
|
#include <lua5.1/lua.h>
|
||||||
#include <lua5.1/lauxlib.h>
|
#include <lua5.1/lauxlib.h>
|
||||||
#include <lua5.1/lualib.h>
|
#include <lua5.1/lualib.h>
|
||||||
|
#else
|
||||||
|
#include <lua.h>
|
||||||
|
#include <lauxlib.h>
|
||||||
|
#include <lualib.h>
|
||||||
|
#endif
|
||||||
|
|
||||||
static char *config = "extensions.lua";
|
static char *config = "extensions.lua";
|
||||||
static char *registrar = "pbx_lua";
|
static char *registrar = "pbx_lua";
|
||||||
|
Reference in New Issue
Block a user