mirror of
https://github.com/phpv8/v8js.git
synced 2025-01-03 13:21:52 +00:00
On MacOS/Darwin link against libv8_libbase.a as well, refs #97
This commit is contained in:
parent
37e3e001c5
commit
453a95826b
24
config.m4
24
config.m4
@ -110,22 +110,32 @@ AC_LINK_IFELSE([AC_LANG_PROGRAM([[#include <v8-debug.h>]],
|
||||
dnl link in libplatform to make our life easier.
|
||||
PHP_ADD_INCLUDE($V8_DIR)
|
||||
|
||||
SEARCH_FOR="lib/libv8_libplatform.a"
|
||||
AC_MSG_CHECKING([for libv8_libplatform.a])
|
||||
case $host_os in
|
||||
darwin* )
|
||||
static_link_extra="libv8_libplatform.a libv8_libbase.a"
|
||||
;;
|
||||
* )
|
||||
static_link_extra="libv8_libplatform.a"
|
||||
;;
|
||||
esac
|
||||
|
||||
for static_link_extra_file in $static_link_extra; do
|
||||
AC_MSG_CHECKING([for $static_link_extra_file])
|
||||
|
||||
for i in $PHP_V8JS $SEARCH_PATH ; do
|
||||
if test -r $i/$SEARCH_FOR; then
|
||||
LIBPLATFORM_DIR=$i
|
||||
if test -r $i/lib/$static_link_extra_file; then
|
||||
static_link_dir=$i
|
||||
AC_MSG_RESULT(found in $i)
|
||||
fi
|
||||
done
|
||||
|
||||
if test -z "$LIBPLATFORM_DIR"; then
|
||||
if test -z "$static_link_dir"; then
|
||||
AC_MSG_RESULT([not found])
|
||||
AC_MSG_ERROR([Please provide libv8_libplatform.a next to the libv8.so, see README.md for details])
|
||||
AC_MSG_ERROR([Please provide $static_link_extra_file next to the libv8.so, see README.md for details])
|
||||
fi
|
||||
|
||||
LDFLAGS="$LDFLAGS $LIBPLATFORM_DIR/$SEARCH_FOR"
|
||||
LDFLAGS="$LDFLAGS $static_link_dir/lib/$static_link_extra_file"
|
||||
done
|
||||
fi
|
||||
|
||||
AC_CACHE_CHECK(for C standard version, ac_cv_v8_cstd, [
|
||||
|
Loading…
Reference in New Issue
Block a user