|
| 1 | +#!/bin/bash |
| 2 | +set -x |
| 3 | +################################################################################ |
| 4 | +# File: build/deps/download.sh |
| 5 | +# Purpose: Use this script to download the files in this dir. Useful if, for |
| 6 | +# example, you don't trust their integrity and/or want to verify them. |
| 7 | +# |
| 8 | +# * https://github.com/BusKill/buskill-app/issues/2 |
| 9 | +# |
| 10 | +# Note: This script was built to be run in Debian or TAILS |
| 11 | +# Authors: Michael Altfield <[email protected]> |
| 12 | +# Created: 2020-08-19 |
| 13 | +# Updated: 2020-08-19 |
| 14 | +# Version: 0.1 |
| 15 | +################################################################################ |
| 16 | + |
| 17 | +sudo apt-get -y install python3-pip python3-setuptools |
| 18 | + |
| 19 | +CURL="/usr/bin/curl" |
| 20 | +WGET="/usr/bin/wget --retry-on-host-error --retry-connrefused" |
| 21 | +PYTHON="/usr/bin/python3" |
| 22 | + |
| 23 | +# in tails, we must torify |
| 24 | +if [[ "`whoami`" == "amnesia" ]]; then |
| 25 | + CURL="/usr/bin/torify ${CURL}" |
| 26 | + WGET="/usr/bin/torify ${WGET}" |
| 27 | + PYTHON="/usr/bin/torify ${PYTHON}" |
| 28 | +fi |
| 29 | + |
| 30 | +tmpDir=`mktemp -d` |
| 31 | +pushd "${tmpDir}" |
| 32 | + |
| 33 | +# first get some info about our internet connection |
| 34 | +${CURL} -s https://ifconfig.co/country | head -n1 |
| 35 | +${CURL} -s https://check.torproject.org | grep Congratulations | head -n1 |
| 36 | + |
| 37 | +# and today's date |
| 38 | +date -u +"%Y-%m-%d" |
| 39 | + |
| 40 | +# first download and upgrade pip (required to get some wheels) |
| 41 | +${PYTHON} -m pip download --no-cache-dir pip==20.1.1 |
| 42 | +${PYTHON} -m pip install --upgrade pip==20.1.1 |
| 43 | + |
| 44 | +# pip (all platforms) |
| 45 | +#${PYTHON} -m pip download --no-cache-dir kivy==1.11.1 libusb1==1.8 pyinstaller==3.6 altgraph==0.17 macholib==1.14 future==0.18.2 pefile==2019.4.18 pywin32-ctypes==0.2.0 setuptools==49.1.0 wheel==0.34.2 virtualenv==20.0.26 |
| 46 | + |
| 47 | +# pip (platform-specific binaries/wheels) |
| 48 | +${WGET} `${CURL} -s https://pypi.org/simple/kivy/ | grep -oE 'https://.*Kivy-1.11.1-cp37-cp37m-win_amd64.whl#'` |
| 49 | +${WGET} `${CURL} -s https://pypi.org/simple/kivy/ | grep -oE 'https://.*Kivy-1.11.1-cp37-cp37m-macosx_10_6_intel.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl#'` |
| 50 | +${WGET} `${CURL} -s https://pypi.org/simple/pypiwin32/ | grep -oE 'https://.*pypiwin32-223-py3-none-any.whl#'` |
| 51 | +${WGET} `${CURL} -s https://pypi.org/simple/pywin32/ | grep -oE 'https://.*pywin32-228-cp37-cp37m-win_amd64.whl#'` |
| 52 | +${WGET} `${CURL} -s https://pypi.org/simple/kivy-deps-sdl2/ | grep -oE 'https://.*kivy_deps.sdl2-0.2.0-cp37-cp37m-win_amd64.whl#'` |
| 53 | +${WGET} `${CURL} -s https://pypi.org/simple/kivy-deps-glew/ | grep -oE 'https://.*kivy_deps.glew-0.2.0-cp37-cp37m-win_amd64.whl#'` |
| 54 | +${WGET} `${CURL} -s https://pypi.org/simple/kivy-deps-angle/ | grep -oE 'https://.*kivy_deps.angle-0.2.0-cp37-cp37m-win_amd64.whl#'` |
| 55 | + |
| 56 | +# misc linux |
| 57 | +${WGET} https://github.com/niess/python-appimage/releases/download/python3.7/python3.7.8-cp37-cp37m-manylinux2014_x86_64.AppImage |
| 58 | +${WGET} https://github.com/AppImage/AppImageKit/releases/download/12/appimagetool-x86_64.AppImage |
| 59 | +${WGET} --output-document=squashfs4.4.tar.gz https://sourceforge.net/projects/squashfs/files/squashfs/squashfs4.4/squashfs4.4.tar.gz/download |
| 60 | + |
| 61 | +# misc windows |
| 62 | +${WGET} https://www.python.org/ftp/python/3.7.8/python-3.7.8-amd64.exe |
| 63 | + |
| 64 | +# misc macos |
| 65 | +${WGET} https://github.com/libusb/libusb/releases/download/v1.0.23/libusb-1.0.23.tar.bz2 |
| 66 | +${WGET} https://homebrew.bintray.com/bottles/wget-1.20.3_2.catalina.bottle.tar.gz |
| 67 | +${WGET} https://homebrew.bintray.com/bottles/python-3.7.8.catalina.bottle.tar.gz |
| 68 | +${WGET} https://homebrew.bintray.com/bottles/sdl2-2.0.12_1.catalina.bottle.tar.gz |
| 69 | +${WGET} https://homebrew.bintray.com/bottles/sdl2_image-2.0.5.catalina.bottle.tar.gz |
| 70 | +${WGET} https://homebrew.bintray.com/bottles/sdl2_ttf-2.0.15.catalina.bottle.tar.gz |
| 71 | +${WGET} https://homebrew.bintray.com/bottles/sdl2_mixer-2.0.4.catalina.bottle.tar.gz |
| 72 | +${WGET} https://homebrew.bintray.com/bottles/libmodplug-0.8.9.0.catalina.bottle.1.tar.gz |
| 73 | + |
| 74 | +# get checksums |
| 75 | +sha256sum * |
0 commit comments