-
Notifications
You must be signed in to change notification settings - Fork 16
/
config.m4
23 lines (19 loc) · 906 Bytes
/
config.m4
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
PHP_ARG_ENABLE(cld, enable Chromium Compact Language Detector,
[ --enable-cld Enable Chromium Compact Language Detector])
if test -z "$PHP_LIBCLD_DIR"; then
PHP_ARG_WITH(libcld-dir, libcld install dir,
[ --with-libcld-dir=DIR Chromium Compact Language Detector: libcld install prefix], no, no)
fi
if test "$PHP_CLD" != "no"; then
if ! test -f $PHP_LIBCLD_DIR/internal/libcld2.so; then
AC_MSG_ERROR([libcld not found. Specify installation directory with --with-libcld-dir=])
fi
PHP_REQUIRE_CXX()
PHP_SUBST(CLD_SHARED_LIBADD)
PHP_ADD_INCLUDE($PHP_LIBCLD_DIR)
PHP_ADD_LIBRARY(stdc++, 1, CLD_SHARED_LIBADD)
PHP_ADD_LIBRARY_WITH_PATH(cld2, $PHP_LIBCLD_DIR/internal, CLD_SHARED_LIBADD)
PHP_ADD_LIBRARY_WITH_PATH(cld2_full, $PHP_LIBCLD_DIR/internal, CLD_SHARED_LIBADD)
PHP_NEW_EXTENSION(cld, cld.cc, $ext_shared)
CXXFLAGS="-Wall -Wno-write-strings"
fi