mod_v8: Use parallel build by default. Use configure flag "--disable-parallel-build-v8" to disable it. It's disabled by default for Debian build scripts, since parallel build has some issues with cowbuilder.

This commit is contained in:
Peter Olsson 2014-03-23 09:25:41 +01:00
parent 741cb889d9
commit c8fa0f0c4b
3 changed files with 13 additions and 2 deletions

View File

@ -1112,6 +1112,11 @@ AC_ARG_ENABLE(static-v8,
[AS_HELP_STRING([--enable-static-v8], [Statically link V8 into mod_v8])], [enable_static_v8="$enableval"], [enable_static_v8="no"]) [AS_HELP_STRING([--enable-static-v8], [Statically link V8 into mod_v8])], [enable_static_v8="$enableval"], [enable_static_v8="no"])
AM_CONDITIONAL([ENABLE_STATIC_V8],[test "x$enable_static_v8" != "xno"]) AM_CONDITIONAL([ENABLE_STATIC_V8],[test "x$enable_static_v8" != "xno"])
# Option to disable parallel build of Google's V8
AC_ARG_ENABLE(parallel-build-v8,
[AS_HELP_STRING([--disable-parallel-build-v8], [Disable parallel build of V8])], [enable_parallel_build_v8="$enableval"], [enable_parallel_build_v8="yes"])
AM_CONDITIONAL([ENABLE_PARALLEL_BUILD_V8],[test "x$enable_parallel_build_v8" != "xno"])
AM_CONDITIONAL([HAVE_ODBC],[test "x$enable_core_odbc_support" != "xno"]) AM_CONDITIONAL([HAVE_ODBC],[test "x$enable_core_odbc_support" != "xno"])
AM_CONDITIONAL([HAVE_LIBEDIT],[test "x$enable_core_libedit_support" != "xno"]) AM_CONDITIONAL([HAVE_LIBEDIT],[test "x$enable_core_libedit_support" != "xno"])
AM_CONDITIONAL([HAVE_MYSQL],[test "$found_mysql" = "yes"]) AM_CONDITIONAL([HAVE_MYSQL],[test "$found_mysql" = "yes"])

2
debian/rules vendored
View File

@ -84,7 +84,7 @@ override_dh_auto_clean:
--with-certsdir=/etc/freeswitch/tls \ --with-certsdir=/etc/freeswitch/tls \
--with-scriptdir=/usr/share/freeswitch/scripts \ --with-scriptdir=/usr/share/freeswitch/scripts \
--with-recordingsdir=/var/lib/freeswitch/recordings \ --with-recordingsdir=/var/lib/freeswitch/recordings \
--enable-static-v8 --enable-static-v8 --disable-parallel-build-v8
touch $@ touch $@
override_dh_auto_configure: .stamp-configure override_dh_auto_configure: .stamp-configure

View File

@ -40,6 +40,12 @@ V8_BUILDPARAMS += library=shared
V8LIB=$(V8_LIBDIR)/libv8.$(V8_LIBEXT) V8LIB=$(V8_LIBDIR)/libv8.$(V8_LIBEXT)
endif endif
if ENABLE_PARALLEL_BUILD_V8
V8_EXTRA_BUILD_PARAMS=
else
V8_EXTRA_BUILD_PARAMS=--no-parallel
endif
# Try to find the target platform for our configured CXX compiler # Try to find the target platform for our configured CXX compiler
# Parse the result one extra time to handle different i386 platforms (i386, i486 etc) # Parse the result one extra time to handle different i386 platforms (i386, i486 etc)
CXX_TARGET_PLATFORM := $(shell $(CXX) -v 2>&1 | grep Target | cut '-d:' -f2 | cut '-d-' -f1 | tr -d ' ') CXX_TARGET_PLATFORM := $(shell $(CXX) -v 2>&1 | grep Target | cut '-d:' -f2 | cut '-d-' -f1 | tr -d ' ')
@ -127,7 +133,7 @@ $(V8LIB): $(V8_DIR) $(V8_DIR)/.stamp-patch
fi; \ fi; \
fi; \ fi; \
cd $(V8_BUILDDIR) && CFLAGS="$(V8_CXXFLAGS)" CXXFLAGS="$(V8_CXXFLAGS)" \ cd $(V8_BUILDDIR) && CFLAGS="$(V8_CXXFLAGS)" CXXFLAGS="$(V8_CXXFLAGS)" \
LINK=@CXX@ CXX=@CXX@ GYPFLAGS="--no-parallel" GYP_DEFINES="$$defines" \ LINK=@CXX@ CXX=@CXX@ GYPFLAGS="$(V8_EXTRA_BUILD_PARAMS)" GYP_DEFINES="$$defines" \
OUTDIR=$(V8_BUILDDIR)/out \ OUTDIR=$(V8_BUILDDIR)/out \
PYTHONPATH="$(V8_DIR)/build/gyp/pylib:$(PYTHONPATH)" $(MAKE) -C $(V8_DIR) $(V8_BUILDPARAMS) native PYTHONPATH="$(V8_DIR)/build/gyp/pylib:$(PYTHONPATH)" $(MAKE) -C $(V8_DIR) $(V8_BUILDPARAMS) native