summaryrefslogtreecommitdiff
path: root/update-luahbtex
blob: 5971d958653122e7ad41719f3ea83654ca765a61 (plain)
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
#!/bin/bash

server=http://dl.contextgarden.net/build/luatex/

archs="
amd64-freebsd
armhf-linux
i386-darwin
i386-freebsd
i386-linux
i386-solaris
sparc-solaris
x86_64-darwinlegacy
x86_64-linux
x86_64-solaris
"

check_and_move() {
  f=$1
  a=$2
  if [ ! -r $f.$a ] ; then
    echo "Cannot find $f.$a"
  fi
  sz=$(stat -c %s $f.$a)
  if [ $sz -lt 1000000 ] ; then
    echo "file size suspicious for $f.$a: $sz"
  else
    mkdir -p bin/$a
    mv $f.$a bin/$a/$f
  fi
}
for a in $archs ; do
  wget -O luahbtex.$a $server$a/luahbtex 
  check_and_move luahbtex $a
  wget -O luajithbtex.$a $server$a/luajithbtex 
  check_and_move luajithbtex $a
done