blob: 10462d45cb9dbadb7045073d9d0960207a089341 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
|
#!/bin/bash
if [ -d "$CLEAN_HOME" ]; then
rm -rf "$CLEAN_HOME.bak"
mv "$CLEAN_HOME" "$CLEAN_HOME.bak"
else
rm -rf "$CLEAN_HOME"
fi
mkdir -p "$CLEAN_HOME"
for pkg in \
base \
abc-interpreter \
lib-argenv \
lib-directory \
lib-dynamics \
lib-gast \
lib-graphcopy \
lib-itasks \
lib-platform \
lib-stdlib \
lib-tcpip \
test
do
curl ftp://ftp.cs.ru.nl/pub/Clean/builds/linux-x64/clean-$pkg-linux-x64-latest.tgz\
| tar xz --strip-components=1 -C "$CLEAN_HOME"
done
grep -h '^[[:space:]]' "$CLEAN_HOME"/etc/*.env >> "$CLEAN_HOME/etc/IDEEnvs"
cat ~/.clean/iTasksDev.env >> "$CLEAN_HOME/etc/IDEEnvs"
ln -s lib/exe "$CLEAN_HOME/exe"
# cloogletags
cloogletags -a -c -d "$CLEAN_HOME/lib" -o "$CLEAN_HOME/lib/tags"
link_local_file(){
echo "$1 -> $2"
mkdir -p "$(dirname "$CLEAN_HOME/$1")"
if [ -f "$CLEAN_HOME/$1" ]; then
mv "$CLEAN_HOME/$1" "$CLEAN_HOME/$1.org"
ln -s "$(realpath --no-symlinks "$2")" "$CLEAN_HOME/$1.new"
ln -s "$(basename "$1").new" "$CLEAN_HOME/$1"
else
ln -s "$(realpath --no-symlinks "$2")" "$CLEAN_HOME/$1"
fi
}
# Local versions of binaries
#link_local_file bin/cpm ~/projects/clean/ide/cpm/cpm
link_local_file lib/exe/cocl /home/camil/projects/clean/compiler/cocl
rm $CLEAN_HOME/lib/exe/cocl
ln -s cocl.org $CLEAN_HOME/lib/exe/cocl
link_local_file bin/cleantest ~/projects/clean/test/cleantest
link_local_file bin/testproperties ~/projects/clean/test-properties/src/testproperties
link_local_file data/cleandoc-default ~/projects/clean/doc/data/cleandoc-default
link_local_file bin/cleandoc ~/projects/clean/doc/src/cleandoc
link_local_file bin/cleanprof2callgrind ~/projects/clean/cleanprof2callgrind/cleanprof2callgrind
# ABC interpreter binaries
link_local_file lib/exe/abcopt ~/projects/clean/abc-interpreter/src/abcopt
link_local_file lib/exe/bcgen ~/projects/clean/abc-interpreter/src/bcgen
link_local_file lib/exe/bclink ~/projects/clean/abc-interpreter/src/bclink
link_local_file lib/exe/bcprelink ~/projects/clean/abc-interpreter/src/bcprelink
link_local_file lib/exe/bcstrip ~/projects/clean/abc-interpreter/src/bcstrip
# completion
for f in ~/projects/clean/bash-completion/*; do
[ -f "$f" ] || continue
base="$(basename "$f")"
if [[ "$base" == "Makefile" ]] || [[ "$base" == "README.md" ]] || [[ "$base" =~ .tar.gz$ ]]; then
continue
fi
link_local_file "etc/completion/$base" "$f"
done
|