Add Anaconda 1.8.0

This commit is contained in:
Yamashita Yuu 2014-02-04 12:24:22 +09:00
parent b21d2c7dea
commit 59fbf8d103
2 changed files with 57 additions and 0 deletions

View file

@ -131,6 +131,10 @@ install_zip() {
install_package_using "zip" 1 "$@"
}
install_script() {
install_package_using "script" 1 "$@"
}
install_package_using() {
local package_type="$1"
local package_type_nargs="$2"
@ -470,6 +474,34 @@ fetch_zip() {
} >&4 2>&1
}
fetch_script() {
local package_name="$1"
local package_url="$2"
local mirror_url
local checksum
if [ "$package_url" != "${package_url/\#}" ]; then
checksum="${package_url#*#}"
package_url="${package_url%%#*}"
if [ -n "$PYTHON_BUILD_MIRROR_URL" ]; then
mirror_url="${PYTHON_BUILD_MIRROR_URL}/$checksum"
fi
fi
local package_filename="${package_name}.sh" # TODO: extract suffix from ${package_url}
if ! symlink_tarball_from_cache "$package_filename" "$checksum"; then
echo "Downloading ${package_filename}..." >&2
http head "$mirror_url" &&
download_tarball "$mirror_url" "$package_filename" "$checksum" ||
download_tarball "$package_url" "$package_filename" "$checksum"
fi
mkdir -p "$(dirname "${package_name}/${package_filename}")"
mv -f "${package_filename}" "${package_name}/${package_filename}"
}
build_package() {
local package_name="$1"
shift
@ -694,6 +726,12 @@ build_package_pypy_builder() {
build_package_pypy
}
build_package_anaconda() {
local package_name="$1"
{ bash "${package_name}.sh" -b -p "${PREFIX_PATH}"
} >&4 2>&1
}
build_package_copy() {
mkdir -p "$PREFIX_PATH"
cp -fR . "$PREFIX_PATH"

View file

@ -0,0 +1,19 @@
case "$(uname -s)" in
"Darwin" )
install_script "Anaconda-1.8.0-MacOSX-x86_64" "http://repo.continuum.io/archive/Anaconda-1.8.0-MacOSX-x86_64.sh#9fd7dd485c5f04fb65699a290e69671c" "anaconda" verify_py27
;;
"Linux" )
case "$(uname -m)" in
"i386" | "i486" | "i586" | "i686" | "i786" )
install_script "Anaconda-1.8.0-Linux-x86" "http://repo.continuum.io/archive/Anaconda-1.8.0-Linux-x86.sh#5028bf0aa7ff8a071d5532b8f8ec924c" "anaconda" verify_py27
;;
"x86_64" )
install_script "Anaconda-1.8.0-Linux-x86_64" "http://repo.continuum.io/archive/Anaconda-1.8.0-Linux-x86_64.sh#398d4b7ddc5c0a16c556c415b2444266" "anaconda" verify_py27
esac
;;
* )
{ echo "Precompiled binary of anaconda-1.8.0 is not available for $(uname -s)-$(uname -m)."
} 1>&4 2>&1
false
;;
esac