-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathconfig.m4
More file actions
32 lines (27 loc) · 959 Bytes
/
config.m4
File metadata and controls
32 lines (27 loc) · 959 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
PHP_ARG_WITH(json_path, for JSON path support,
[ --with-json-path[=DIR] Include JSON path support])
if test "$PHP_JSON_PATH" != "no"; then
if test -r $PHP_JSON_PATH/include/yajl/yajl_parse.h; then
YAJL_DIR=$PHP_JSON_PATH
else
AC_MSG_CHECKING(for Yajl in default path)
for i in /usr/local /usr; do
if test -r $i/include/yajl/yajl_parse.h; then
YAJL_DIR=$i
AC_MSG_RESULT(found in $i)
break
fi
done
fi
if test -z "$YAJL_DIR"; then
AC_MSG_RESULT(not found)
AC_MSG_ERROR(Please reinstall the yajl distribution -
yajl_parse.h should be in <yajl-dir>/include/yajl/yajl_parse.h)
fi
AC_DEFINE([HAVE_JSON_PATH],1 , [whether to enable JSON path support])
AC_HEADER_STDC
PHP_ADD_INCLUDE($YAJL_DIR/include)
PHP_ADD_LIBRARY_WITH_PATH(yajl, $YAJL_DIR/lib, JSON_PATH_SHARED_LIBADD)
PHP_NEW_EXTENSION(json_path, json_path.c, $ext_shared)
PHP_SUBST(JSON_PATH_SHARED_LIBADD)
fi