X-Git-Url: https://git.martlubbers.net/?a=blobdiff_plain;f=clean%2F.local%2Fbin%2Finstall_clean.sh;h=0bcd7f3e31405218783561704117a49584d0d15d;hb=3204decf4f5e3c96c02055af97a83a3f19f4d49d;hp=745a9e110d1ad4c9539cedfca688864b00ccf207;hpb=32a0f89bc0eea5252e432f626d16b7ecdddcc97f;p=dotfiles.git diff --git a/clean/.local/bin/install_clean.sh b/clean/.local/bin/install_clean.sh index 745a9e1..0bcd7f3 100755 --- a/clean/.local/bin/install_clean.sh +++ b/clean/.local/bin/install_clean.sh @@ -1,9 +1,28 @@ -#!/bin/sh -cd /tmp -curl ftp://ftp.cs.ru.nl/pub/Clean/builds/linux-x64/clean-bundle-complete-linux-x64-latest.tgz | tar -xz -rm -rf /opt/clean -mv clean-bundle-complete /opt/clean +#!/bin/bash +set -e +DISTRO="https://ftp.cs.ru.nl/Clean/builds/linux-x64/clean-bundle-complete-linux-x64-latest.tgz" +TAGS="https://gitlab.science.ru.nl/cloogle/cloogle-tags/-/jobs/artifacts/master/raw/cloogletags?job=build" +CLM="https://gitlab.science.ru.nl/mlubbers/clm/builds/artifacts/master/raw/clm?job=compile" +CLM1="https://gitlab.science.ru.nl/mlubbers/clm/builds/artifacts/master/raw/clm.1?job=compile" +CLEAN_HOME="${CLEAN_HOME:-/opt/clean}" + +echo "Cleaning up the old distro" +rm -rf "$CLEAN_HOME"/* +echo "Downloading clean" +curl -sSL "$DISTRO" | tar -C "$CLEAN_HOME" --strip-components=1 -xz +echo "Replacing clm" +curl -sSLo "$CLEAN_HOME/bin/clm" "$CLM" +echo "Installing manpages" +mkdir -p ~/.local/man/man1 +curl -sSLo ~/.local/man/man1/clm.1 "$CLM1" +echo "Downloading cloogletags" +curl -sSLo "$CLEAN_HOME"/bin/cloogletags "$TAGS" +chmod +x "$CLEAN_HOME"/bin/cloogletags +echo "Generating tags" +cloogletags -a -c -d "$CLEAN_HOME"/lib -o "$CLEAN_HOME"/lib/tags 2>/dev/null + +echo "Patching StdEnv for binumap" patch /opt/clean/lib/StdEnv/StdGeneric.dcl <