bug 661908 - create a virtualenv as part of configure. r=khuey

--HG--
extra : rebase_source : 9f2977471ba4baf45cc618c87b2e99f102bc9cca
This commit is contained in:
Ted Mielczarek 2012-04-25 13:37:16 -04:00
Родитель c69de0097d
Коммит 733cf5c40a
3 изменённых файлов: 38 добавлений и 4 удалений

Просмотреть файл

@ -30,6 +30,7 @@ build/Makefile
build/pgo/Makefile build/pgo/Makefile
build/pgo/blueprint/Makefile build/pgo/blueprint/Makefile
build/pgo/js-input/Makefile build/pgo/js-input/Makefile
build/virtualenv/Makefile
config/Makefile config/Makefile
config/autoconf.mk config/autoconf.mk
config/nspr/Makefile config/nspr/Makefile

Просмотреть файл

@ -0,0 +1,15 @@
# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this file,
# You can obtain one at http://mozilla.org/MPL/2.0/.
DEPTH = ../..
topsrcdir = @top_srcdir@
srcdir = @srcdir@
VPATH = @srcdir@
include $(DEPTH)/config/autoconf.mk
default::
# install some packages
include $(topsrcdir)/config/rules.mk

Просмотреть файл

@ -7901,10 +7901,9 @@ else
fi fi
AC_SUBST(CL_INCLUDES_PREFIX) AC_SUBST(CL_INCLUDES_PREFIX)
rm -f dummy-hello.c rm -f dummy-hello.c
_topsrcdirwin=`cd \`dirname $0\`; pwd -W`
dnl cl.py provides dependency generation for MSVC dnl cl.py provides dependency generation for MSVC
CC_WRAPPER="$PYTHON -O $_topsrcdirwin/build/cl.py" CC_WRAPPER='$(PYTHON) -O $(topsrcdir)/build/cl.py'
CXX_WRAPPER="$PYTHON -O $_topsrcdirwin/build/cl.py" CXX_WRAPPER='$(PYTHON) -O $(topsrcdir)/build/cl.py'
COMPILER_DEPEND=1 COMPILER_DEPEND=1
fi fi
fi fi
@ -8544,7 +8543,6 @@ AC_SUBST(MOZ_MAPINFO)
AC_SUBST(MOZ_BROWSE_INFO) AC_SUBST(MOZ_BROWSE_INFO)
AC_SUBST(MOZ_TOOLS_DIR) AC_SUBST(MOZ_TOOLS_DIR)
AC_SUBST(WIN32_REDIST_DIR) AC_SUBST(WIN32_REDIST_DIR)
AC_SUBST(PYTHON)
AC_SUBST(MAKENSISU) AC_SUBST(MAKENSISU)
dnl Echo the CFLAGS to remove extra whitespace. dnl Echo the CFLAGS to remove extra whitespace.
@ -8926,6 +8924,22 @@ AC_SUBST(MOZ_DEFINES)
rm -f confdefs.h rm -f confdefs.h
mv confdefs.h.save confdefs.h mv confdefs.h.save confdefs.h
dnl Create a virtualenv where we can install local Python packages
AC_MSG_RESULT([Creating Python virtualenv])
rm -rf _virtualenv
mkdir _virtualenv
$PYTHON $_topsrcdir/other-licenses/virtualenv/virtualenv.py ./_virtualenv
case "$host_os" in
mingw*)
PYTHON=`pwd`/_virtualenv/Scripts/python.exe
;;
*)
PYTHON=`pwd`/_virtualenv/bin/python
;;
esac
AC_SUBST(PYTHON)
dnl Load the list of Makefiles to generate. dnl Load the list of Makefiles to generate.
dnl To add new Makefiles, edit allmakefiles.sh. dnl To add new Makefiles, edit allmakefiles.sh.
dnl allmakefiles.sh sets the variable, MAKEFILES. dnl allmakefiles.sh sets the variable, MAKEFILES.
@ -8949,6 +8963,10 @@ mv -f config/autoconf.mk config/autoconf.mk.orig 2> /dev/null
AC_OUTPUT($MAKEFILES) AC_OUTPUT($MAKEFILES)
# Populate the virtualenv
AC_MSG_RESULT([Populating Python virtualenv])
$MAKE -C build/virtualenv || exit 1
# Generate a JSON config file for unittest harnesses etc to read # Generate a JSON config file for unittest harnesses etc to read
# build configuration details from in a standardized way. # build configuration details from in a standardized way.
OS_TARGET=${OS_TARGET} TARGET_CPU=${TARGET_CPU} MOZ_DEBUG=${MOZ_DEBUG} \ OS_TARGET=${OS_TARGET} TARGET_CPU=${TARGET_CPU} MOZ_DEBUG=${MOZ_DEBUG} \