mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-11-01 15:11:24 +00:00
test-release.sh: Add a way to specify --build to configure
Summary: I currently have to specify --build=mips-linux-gnu or --build=mipsel-linux-gnu to configure in order to successfully recurse a 32-bit build of the compiler on my mips64-linux-gnu and mips64el-linux-gnu targets. This is a bug and will be fixed but in the meantime it will be useful to have a way to work around this. Reviewers: tstellarAMD Subscribers: llvm-commits Differential Revision: http://reviews.llvm.org/D6522 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@223369 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
3f598f77bd
commit
86bf88145b
@ -39,27 +39,30 @@ do_debug="no"
|
|||||||
do_asserts="no"
|
do_asserts="no"
|
||||||
do_compare="yes"
|
do_compare="yes"
|
||||||
BuildDir="`pwd`"
|
BuildDir="`pwd`"
|
||||||
|
BuildTriple=""
|
||||||
|
|
||||||
function usage() {
|
function usage() {
|
||||||
echo "usage: `basename $0` -release X.Y -rc NUM [OPTIONS]"
|
echo "usage: `basename $0` -release X.Y -rc NUM [OPTIONS]"
|
||||||
echo ""
|
echo ""
|
||||||
echo " -release X.Y The release number to test."
|
echo " -release X.Y The release number to test."
|
||||||
echo " -rc NUM The pre-release candidate number."
|
echo " -rc NUM The pre-release candidate number."
|
||||||
echo " -final The final release candidate."
|
echo " -final The final release candidate."
|
||||||
echo " -triple TRIPLE The target triple for this machine."
|
echo " -triple TRIPLE The target triple for this machine."
|
||||||
echo " -j NUM Number of compile jobs to run. [default: 3]"
|
echo " -j NUM Number of compile jobs to run. [default: 3]"
|
||||||
echo " -build-dir DIR Directory to perform testing in. [default: pwd]"
|
echo " -build-dir DIR Directory to perform testing in. [default: pwd]"
|
||||||
echo " -no-checkout Don't checkout the sources from SVN."
|
echo " -no-checkout Don't checkout the sources from SVN."
|
||||||
echo " -no-64bit Don't test the 64-bit version. [default: yes]"
|
echo " -no-64bit Don't test the 64-bit version. [default: yes]"
|
||||||
echo " -enable-ada Build Ada. [default: disable]"
|
echo " -enable-ada Build Ada. [default: disable]"
|
||||||
echo " -disable-clang Do not test clang. [default: enable]"
|
echo " -disable-clang Do not test clang. [default: enable]"
|
||||||
echo " -enable-dragonegg Test dragonegg. [default: disable]"
|
echo " -enable-dragonegg Test dragonegg. [default: disable]"
|
||||||
echo " -enable-fortran Enable Fortran build. [default: disable]"
|
echo " -enable-fortran Enable Fortran build. [default: disable]"
|
||||||
echo " -disable-objc Disable ObjC build. [default: enable]"
|
echo " -disable-objc Disable ObjC build. [default: enable]"
|
||||||
echo " -test-debug Test the debug build. [default: no]"
|
echo " -test-debug Test the debug build. [default: no]"
|
||||||
echo " -test-asserts Test with asserts on. [default: no]"
|
echo " -test-asserts Test with asserts on. [default: no]"
|
||||||
echo " -no-compare-files Don't test that phase 2 and 3 files are identical."
|
echo " -no-compare-files Don't test that phase 2 and 3 files are identical."
|
||||||
echo " -use-gzip Use gzip instead of xz."
|
echo " -use-gzip Use gzip instead of xz."
|
||||||
|
echo " -build-triple TRIPLE The build triple for this machine"
|
||||||
|
echo " [default: use config.guess]"
|
||||||
}
|
}
|
||||||
|
|
||||||
while [ $# -gt 0 ]; do
|
while [ $# -gt 0 ]; do
|
||||||
@ -80,6 +83,10 @@ while [ $# -gt 0 ]; do
|
|||||||
shift
|
shift
|
||||||
Triple="$1"
|
Triple="$1"
|
||||||
;;
|
;;
|
||||||
|
-build-triple | --build-triple )
|
||||||
|
shift
|
||||||
|
BuildTriple="$1"
|
||||||
|
;;
|
||||||
-j* )
|
-j* )
|
||||||
NumJobs="`echo $1 | sed -e 's,-j\([0-9]*\),\1,g'`"
|
NumJobs="`echo $1 | sed -e 's,-j\([0-9]*\),\1,g'`"
|
||||||
if [ -z "$NumJobs" ]; then
|
if [ -z "$NumJobs" ]; then
|
||||||
@ -295,17 +302,21 @@ function configure_llvmCore() {
|
|||||||
echo "# Using C compiler: $c_compiler"
|
echo "# Using C compiler: $c_compiler"
|
||||||
echo "# Using C++ compiler: $cxx_compiler"
|
echo "# Using C++ compiler: $cxx_compiler"
|
||||||
|
|
||||||
|
build_triple_option="${BuildTriple:+--build=$BuildTriple}"
|
||||||
|
|
||||||
cd $ObjDir
|
cd $ObjDir
|
||||||
echo "# Configuring llvm $Release-$RC $Flavor"
|
echo "# Configuring llvm $Release-$RC $Flavor"
|
||||||
echo "# $BuildDir/llvm.src/configure --prefix=$InstallDir \
|
echo "# $BuildDir/llvm.src/configure --prefix=$InstallDir \
|
||||||
--enable-optimized=$Optimized \
|
--enable-optimized=$Optimized \
|
||||||
--enable-assertions=$Assertions \
|
--enable-assertions=$Assertions \
|
||||||
--disable-timestamps"
|
--disable-timestamps \
|
||||||
|
$build_triple_option"
|
||||||
env CC="$c_compiler" CXX="$cxx_compiler" \
|
env CC="$c_compiler" CXX="$cxx_compiler" \
|
||||||
$BuildDir/llvm.src/configure --prefix=$InstallDir \
|
$BuildDir/llvm.src/configure --prefix=$InstallDir \
|
||||||
--enable-optimized=$Optimized \
|
--enable-optimized=$Optimized \
|
||||||
--enable-assertions=$Assertions \
|
--enable-assertions=$Assertions \
|
||||||
--disable-timestamps \
|
--disable-timestamps \
|
||||||
|
$build_triple_option \
|
||||||
2>&1 | tee $LogDir/llvm.configure-Phase$Phase-$Flavor.log
|
2>&1 | tee $LogDir/llvm.configure-Phase$Phase-$Flavor.log
|
||||||
cd $BuildDir
|
cd $BuildDir
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user