llvm.org GIT mirror llvm / 3c031bd
Merging r195193: ------------------------------------------------------------------------ r195193 | void | 2013-11-19 20:55:20 -0800 (Tue, 19 Nov 2013) | 5 lines Add -triple option. The -triple option is used to create a named tarball of the release binaries. Also disable the RPATH modifications on Mac OS X. It's not needed. ------------------------------------------------------------------------ git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_34@195194 91177308-0d34-0410-b5e6-96231b3b80d8 Bill Wendling 7 years ago
1 changed file(s) with 38 addition(s) and 3 deletion(s). Raw diff Collapse all Expand all
2525 Release=""
2626 Release_no_dot=""
2727 RC=""
28 Triple=""
2829 do_checkout="yes"
2930 do_ada="no"
3031 do_clang="yes"
4344 echo " -release X.Y The release number to test."
4445 echo " -rc NUM The pre-release candidate number."
4546 echo " -final The final release candidate."
47 echo " -triple TRIPLE The target triple for this machine."
4648 echo " -j NUM Number of compile jobs to run. [default: 3]"
4749 echo " -build-dir DIR Directory to perform testing in. [default: pwd]"
4850 echo " -no-checkout Don't checkout the sources from SVN."
7173 -final | --final )
7274 RC=final
7375 ;;
76 -triple | --triple )
77 shift
78 Triple="$1"
79 ;;
7480 -j* )
7581 NumJobs="`echo $1 | sed -e 's,-j\([0-9]*\),\1,g'`"
7682 if [ -z "$NumJobs" ]; then
134140 echo "error: no release candidate number specified"
135141 exit 1
136142 fi
143 if [ -z "$Triple" ]; then
144 echo "error: no target triple specified"
145 exit 1
146 fi
137147
138148 # Figure out how many make processes to run.
139149 if [ -z "$NumJobs" ]; then
157167 # Location of log files.
158168 LogDir=$BuildDir/logs
159169 mkdir -p $LogDir
170
171 # Final package name.
172 Package=clang+llvm-$Release
173 if [ $RC != "final" ]; then
174 Package=$Package-$RC
175 fi
176 Package=$Package-$Triple
160177
161178 # Find compilers.
162179 if [ "$do_dragonegg" = "yes" ]; then
188205 fi
189206 }
190207
191 check_program_exists 'chrpath'
192 check_program_exists 'file'
193 check_program_exists 'objdump'
208 if [ `uname -s` != "Darwin" ]; then
209 check_program_exists 'chrpath'
210 check_program_exists 'file'
211 check_program_exists 'objdump'
212 fi
194213
195214 # Make sure that the URLs are valid.
196215 function check_valid_urls() {
342361 # Clean RPATH. Libtool adds the build directory to the search path, which is
343362 # not necessary --- and even harmful --- for the binary packages we release.
344363 function clean_RPATH() {
364 if [ `uname -s` = "Darwin" ]; then
365 return
366 fi
345367 local InstallPath="$1"
346368 for Candidate in `find $InstallPath/{bin,lib} -type f`; do
347369 if file $Candidate | grep ELF | egrep 'executable|shared object' > /dev/null 2>&1 ; then
352374 fi
353375 fi
354376 done
377 }
378
379 # Create a package of the release binaries.
380 function package_release() {
381 cwd=`pwd`
382 cd $BuildDir/Phase3/Release
383 mv llvmCore-$Release-$RC.install $Package
384 tar cfz $BuildDir/$Package.tar.gz $Package
385 mv $Package llvmCore-$Release-$RC.install
386 cd $cwd
355387 }
356388
357389 set -e # Exit if any command fails
549581 done
550582 ) 2>&1 | tee $LogDir/testing.$Release-$RC.log
551583
584 package_release
585
552586 set +e
553587
554588 # Woo hoo!
555589 echo "### Testing Finished ###"
590 echo "### Package: $Package.tar.gz"
556591 echo "### Logs: $LogDir"
557592 exit 0