You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@openoffice.apache.org by af...@apache.org on 2011/12/02 11:39:29 UTC
svn commit: r1209387 - in /incubator/ooo/trunk/main: bootstrap.1
fetch_tarballs.sh ooo.lst
Author: af
Date: Fri Dec 2 10:39:29 2011
New Revision: 1209387
URL: http://svn.apache.org/viewvc?rev=1209387&view=rev
Log:
118663: Load external archives from new ext_sources directory.
Modified:
incubator/ooo/trunk/main/bootstrap.1
incubator/ooo/trunk/main/fetch_tarballs.sh
incubator/ooo/trunk/main/ooo.lst
Modified: incubator/ooo/trunk/main/bootstrap.1
URL: http://svn.apache.org/viewvc/incubator/ooo/trunk/main/bootstrap.1?rev=1209387&r1=1209386&r2=1209387&view=diff
==============================================================================
--- incubator/ooo/trunk/main/bootstrap.1 (original)
+++ incubator/ooo/trunk/main/bootstrap.1 Fri Dec 2 10:39:29 2011
@@ -38,7 +38,11 @@ if test -n "$DMAKE_URL" -a ! -x "$SOLAR
mkdir -p "$tmp_build_dir"
cd "$tmp_build_dir" || exit
- dmake_full_package_name="$TARFILE_LOCATION/$dmake_package_name"
+ dmake_full_package_name=$(find $TARFILE_LOCATION -type f -name "*-$dmake_package_name")
+ if [ -z "$dmake_full_package_name" ]; then
+ echo "can not find the dmake package"
+ exit
+ fi
if test "$GUI" = "WNT"; then
dmake_full_package_name=`cygpath -u "$dmake_full_package_name"`
fi
Modified: incubator/ooo/trunk/main/fetch_tarballs.sh
URL: http://svn.apache.org/viewvc/incubator/ooo/trunk/main/fetch_tarballs.sh?rev=1209387&r1=1209386&r2=1209387&view=diff
==============================================================================
--- incubator/ooo/trunk/main/fetch_tarballs.sh (original)
+++ incubator/ooo/trunk/main/fetch_tarballs.sh Fri Dec 2 10:39:29 2011
@@ -1,4 +1,4 @@
-#!/bin/sh
+#!/bin/bash
#*************************************************************************
#
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -26,6 +26,8 @@
#
#*************************************************************************
+file_list_name=$1
+
if [ -z "$TARFILE_LOCATION" ]; then
echo "ERROR: no destination defined! please set TARFILE_LOCATION!"
exit
@@ -63,7 +65,7 @@ else
if [ $ret -eq 0 ]; then
fetch_bin=$wg
fetch_args="-nv -N"
- echo found wget: $fetch_bin
+ echo found wget at `which $fetch_bin`
break 2
fi
done
@@ -76,7 +78,7 @@ else
if [ -x $c ]; then
fetch_bin=$c
fetch_args="$file_date_check -O"
- echo found curl: $fetch_bin
+ echo found curl at `which $fetch_bin`
break 2
fi
done
@@ -99,7 +101,7 @@ for i in md5 md5sum /usr/local/bin/md5su
ret=$?
if [ $ret -eq 0 ]; then
md5sum=$i
- echo found md5sum: $md5sum
+ echo found md5sum at `which $md5sum`
break 2
fi
done
@@ -120,114 +122,116 @@ date >> $logfile
mkdir -p $TARFILE_LOCATION/tmp
cd $TARFILE_LOCATION/tmp
-if [ -n "$DMAKE_URL" -a ! -x "$SOLARENV/$OUTPATH/bin/dmake$EXEEXT" ]; then
- # Determine the name of the downloaded file.
- dmake_package_name=`echo $DMAKE_URL | sed "s/^\(.*\/\)//"`
- if [ ! -f "../$dmake_package_name" ]; then
- # Fetch the dmake source
- echo fetching $DMAKE_URL to $TARFILE_LOCATION/tmp
- $fetch_bin $fetch_args $DMAKE_URL 2>&1 | tee -a $logfile
- wret=$?
-
- # When the download failed then remove the remains, otherwise
- # move the downloaded file up to TARFILE_LOCATION
- if [ $wret -ne 0 ]; then
- echo "download failed. removing $dmake_package_name"
- rm "$dmake_package_name"
- failed="$failed $i"
- wret=0
- else
- mv "$dmake_package_name" ..
- echo "successfully downloaded $dmake_package_name"
- fi
- else
- echo "found $dmake_package_name, no need to download it again"
- fi
-fi
+function basename ()
+{
+ echo $1 | sed "s/^\(.*\/\)//"
+}
-#Special handling of epm
-if [ -n "$EPM_URL" -a ! -x "$SOLARENV/$OUTPATH/bin/epm$EXEEXT" ]; then
- # Determine the name of the downloaded file.
- epm_package_name=`echo $EPM_URL | sed "s/^\(.*\/\)//"`
- epm_package=`echo $epm_package_name | sed "s/-source//"`
- epm_wildcard_package_name="*-$epm_package"
-
- epmtest=$(find .. -type f -name "$epm_wildcard_package_name")
-
- # check with wildcard for the renamed package, md5
- if [ -z "$epmtest" ]; then
- # Fetch the epm source
- echo fetching $EPM_URL to $TARFILE_LOCATION/tmp
- $fetch_bin $fetch_args $EPM_URL 2>&1 | tee -a $logfile
-
- wret=$?
-
- # When the download failed then remove the remains, otherwise
- # move the downloaded file up to TARFILE_LOCATION and rename it
- # according our naing convention for external tar balls.
- if [ $wret -ne 0 ]; then
- echo "download failed. removing $epm_package_name"
- rm "$epm_package_name"
- failed="$failed $i"
- wret=0
+#
+# Download a file from a URL and add its md5 checksum to its name.
+#
+function download ()
+{
+ local URL=$1
+
+ if [ -n "$URL" ]; then
+ local basename=$(basename $URL)
+ local candidate=$(find "$TARFILE_LOCATION" -type f -name "*-$basename")
+ if [ -n "$candidate" ]; then
+ echo "$basename is already present ($candidate)"
else
- #mv "$epm_package_name" ..
- epm_md5_sum=`$md5sum $md5special $epm_package_name | sed "s/ .*//"`
- epm_md5_package_name="$epm_md5_sum-$epm_package"
-
- rm -f ../$epm_md5_package_name && \
- cp -pRP $epm_package_name ../$epm_md5_package_name && \
- rm -rf $epm_package_name
- echo "successfully downloaded $epm_package_name and renamed to $epm_md5_package_name"
+ echo fetching $basename
+ $fetch_bin $fetch_args $URL 2>&1 | tee -a $logfile
+
+ if [ $? -ne 0 ]; then
+ echo "download failed"
+ mv $basename ${basename}_broken
+ failed="$failed $i"
+ elif [ -f "$basename" -a -n "$md5sum" ]; then
+ local sum=`$md5sum $md5special $basename | sed "s/ .*//"`
+ mv $basename "$TARFILE_LOCATION/$sum-$basename"
+ echo "added md5 sum $sum"
+ fi
fi
- else
- echo "found $epmtest, no need to download it again"
fi
-fi
-# end special
+}
+#
+# Download a file from a URL and check its md5 sum to the one that is part of its name.
+#
+function download_and_check ()
+{
+ local URL=$1
+
+ if [ -n "$URL" ]; then
+ local basename=$(basename $URL)
+ if [ -f "$TARFILE_LOCATION/$basename" ]; then
+ echo "$basename is already present"
+ else
+ echo "fetching $basename"
+ $fetch_bin $fetch_args $URL 2>&1 | tee -a $logfile
-cd $TARFILE_LOCATION/tmp
-filelist=`cat $1`
-echo $$ > fetch-running
-for i in $filelist ; do
-# echo $i
- if [ "$i" != `echo $i | sed "s/^http:\///"` ]; then
- tarurl=$i
- # TODO: check for comment
- else
- if [ "$tarurl" != "" ]; then
- if [ ! -f "../$i" ]; then
- echo $i
- echo fetching $i
- $fetch_bin $fetch_args $tarurl/$i 2>&1 | tee -a $logfile
- wret=$?
- if [ $wret -ne 0 ]; then
- mv $i ${i}_broken
- failed="$failed $i"
- wret=0
- fi
- if [ -f $i -a -n "$md5sum" ]; then
- sum=`$md5sum $md5special $i | sed "s/ .*//"`
- sum2=`echo $i | sed "s/-.*//"`
- if [ "$sum" != "$sum2" ]; then
- echo checksum failure for $i 2>&1 | tee -a $logfile
- failed="$failed $i"
- mv $i ${i}_broken
- else
- mv $i ..
- fi
- else
- mv $i ..
+ if [ $? -ne 0 ]; then
+ echo "download failed"
+ mv $basename ${basename}_broken
+ failed="$failed $i"
+ elif [ -f "$basename" -a -n "$md5sum" ]; then
+ local sum=`$md5sum $md5special $basename | sed "s/ .*//"`
+ local sum_in_name=`echo $basename | sed "s/-.*//"`
+ if [ "$sum" != "$sum_in_name" ]; then
+ echo checksum failure for $basename 2>&1 | tee -a $logfile
+ failed="$failed $basename"
+ mv $basename ${basename}_broken
fi
+ mv $basename "$TARFILE_LOCATION/$basename"
fi
fi
fi
-done
-rm $TARFILE_LOCATION/tmp/*-*
-cd $start_dir
+}
+
+echo "downloading tar balls to $TARFILE_LOCATION"
+
+while read line ; do
+ # Remove leading and trailing space and comments
+ line=`echo $line | sed 's/^[[:space:]]*//;s/[[:space:]]*$//;s/[[:space:]]*#.*$//'`
+ case $line in
+ # Ignore empty lines.
+ '')
+ ;;
+
+ # When a URL ends in a / then it is taken as a partial URL
+ # to which the following lines will be appended.
+ ftp:\/\/*\/ | http:\/\/*\/)
+ UrlHead=$line
+ echo $UrlHead
+ ;;
+
+ # A full URL represents a single file which is downloaded.
+ ftp:\/\/* | http:\/\/*)
+ download $line
+ ;;
+
+ # Any other line is interpreted as the second part of a partial URL.
+ # It is appended to UrlHead and then downloaded.
+ *)
+ download_and_check $UrlHead$line
+ ;;
+ esac
+done < "$file_list_name"
+
+
+# Special handling of dmake
+if [ -n "$DMAKE_URL" -a ! -x "$SOLARENV/$OUTPATH/bin/dmake$EXEEXT" ]; then
+ download $DMAKE_URL
+fi
+
+# Special handling of epm
+if [ -n "$EPM_URL" -a ! -x "$SOLARENV/$OUTPATH/bin/epm$EXEEXT" ]; then
+ download $EPM_URL
+fi
+
if [ ! -z "$failed" ]; then
echo
Modified: incubator/ooo/trunk/main/ooo.lst
URL: http://svn.apache.org/viewvc/incubator/ooo/trunk/main/ooo.lst?rev=1209387&r1=1209386&r2=1209387&view=diff
==============================================================================
--- incubator/ooo/trunk/main/ooo.lst (original)
+++ incubator/ooo/trunk/main/ooo.lst Fri Dec 2 10:39:29 2011
@@ -1,13 +1,19 @@
-http://hg.services.openoffice.org/binaries
+# Format of this file:
+# Comments start with '#' and are ignored.
+# Empty lines (except for whitespace) are ignored.
+# Full URLs (http and ftp) are loaded as is.
+# Partial URLs (http and ftp) end in '/' and are added to the following lines.
+
+# Load libraries from svn.apache.org. When the source code was checked out
+# with SVN then these should already be present.
+http://svn.apache.org/repos/asf/incubator/ooo/trunk/ext_sources/
48a9f787f43a09c0a9b7b00cd1fddbbf-hyphen-2.7.1.tar.gz
63ddc5116488985e820075e65fbe6aa4-openssl-0.9.8o.tar.gz
-09357cc74975b01714e00c5899ea1881-pixman-0.12.0.tar.gz
0b49ede71c21c0599b0cc19b353a6cb3-README_apache-commons.txt
68dd2e8253d9a7930e9fd50e2d7220d0-hunspell-1.2.9.tar.gz
128cfc86ed5953e57fe0f5ae98b62c2e-libtextcat-2.2.tar.gz
17410483b5b5f267aa18b7e00b65e6e0-hsqldb_1_8_0.zip
1756c4fa6c616ae15973c104cd8cb256-Adobe-Core35_AFMs-314.tar.gz
-18f577b374d60b3c760a3a3350407632-STLport-4.5.tar.gz
1f24ab1d39f4a51faf22244c94a6203f-xmlsec1-1.2.14.tar.gz
24be19595acad0a2cae931af77a0148a-LICENSE_source-9.0.0.7-bj.html
284e768eeda0e2898b0d5bf7e26a016e-raptor-1.4.18.tar.gz
@@ -15,20 +21,15 @@ http://hg.services.openoffice.org/binari
2ae988b339daec234019a7066f96733e-commons-lang-2.3-src.tar.gz
2c9b0f83ed5890af02c0df1c1776f39b-commons-httpclient-3.1-src.tar.gz
2f6ecca935948f7db92d925d88d0d078-icu4c-4_0_1-src.tgz
-35c94d2df8893241173de1d16b6034c0-swingExSrc.zip
-377a60170e5185eb63d3ed2fae98e621-README_silgraphite-2.3.1.txt
3c219630e4302863a9a83d0efde889db-commons-logging-1.1.1-src.tar.gz
48470d662650c3c074e1c3fabbc67bbd-README_source-9.0.0.7-bj.txt
48d8169acc35f97e05d8dcdfd45be7f2-lucene-2.3.2.tar.gz
-4a660ce8466c9df01f19036435425c3a-glibc-2.1.3-stub.tar.gz
-4ea70ea87b47e92d318d4e7f5b940f47-cairo-1.8.0.tar.gz
b92261a5679276c400555004937af965-nss-3.12.6-with-nspr-4.8.4.tar.gz
7740a8ec23878a2f50120e1faa2730f2-libxml2-2.7.6.tar.gz
7376930b0d3f3d77a685d94c4a3acda8-STLport-4.5-0119.tar.gz
798b2ffdc8bcfe7bca2cf92b62caf685-rhino1_5R5.zip
ecb2e37e45c9933e2a963cabe03670ab-curl-7.19.7.tar.gz
8294d6c42e3553229af9934c5c0ed997-stax-api-1.0-2-sources.jar
-bd30e9cf5523cdfc019b94f5e1d7fd19-cppunit-1.12.1.tar.gz
a169ab152209200a7bad29a275cb0333-seamonkey-1.1.14.source.tar.gz
a4d9b30810a434a3ed39fc0003bbd637-LICENSE_stax-api-1.0-2-sources.html
a7983f859eafb2677d7ff386a023bc40-xsltml_2.1.2.zip
@@ -37,6 +38,7 @@ af3c3acf618de6108d65fcdc92b492e1-commons
bc702168a2af16869201dbe91e46ae48-LICENSE_Python-2.6.1
c441926f3a552ed3e5b274b62e86af16-STLport-4.0.tar.gz
ca66e26082cab8bb817185a116db809b-redland-1.0.8.tar.gz
+377a60170e5185eb63d3ed2fae98e621-README_silgraphite-2.3.1.txt
d35724900f6a4105550293686688bbb3-silgraphite-2.3.1.tar.gz
d70951c80dabecc2892c919ff5d07172-db-4.7.25.NC-custom.tar.gz
e0707ff896045731ff99e99799606441-README_db-4.7.25.NC-custom.txt
@@ -56,3 +58,8 @@ cf8a6967f7de535ae257fa411c98eb88-mdds_0.
a2c10c04f396a9ce72894beb18b4e1f9-jpeg-8c.tar.gz
c735eab2d659a96e5a594c9e8541ad63-zlib-1.2.5.tar.gz
+# Temporary
+http://hg.services.openoffice.org/binaries/
+4a660ce8466c9df01f19036435425c3a-glibc-2.1.3-stub.tar.gz
+d70951c80dabecc2892c919ff5d07172-db-4.7.25.NC-custom.tar.gz
+e0707ff896045731ff99e99799606441-README_db-4.7.25.NC-custom.txt