-
-
Notifications
You must be signed in to change notification settings - Fork 0
/
beskow_install_autotools.sh
executable file
·63 lines (51 loc) · 1.24 KB
/
beskow_install_autotools.sh
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
#!/bin/bash -l
source beskow_env.sh
pkgdir=$pkgdir
srcdir=$srcdir/autotools
gnu_install() {
cd $srcdir
local pkgname=$1
local pkgver=$2
local pkgdir=$3
mkdir -p $pkgdir
if [ ! -d ./$pkgname ]
then
[ ! -f ${pkgname}-${pkgver}.tar.gz ] && wget ftp://ftp.gnu.org/gnu/${pkgname}/${pkgname}-${pkgver}.tar.gz
tar xvf ${pkgname}-${pkgver}.tar.gz
mv ${pkgname}-${pkgver} ${pkgname}
# git clone git://git.savannah.gnu.org/$pkgname.git --depth=1
fi
cd $pkgname
rm -rf ${pkgdir}
./bootstrap
$CONFIGURE --prefix=${pkgdir} CC=gcc
$MAKE
# $MAKE check
$MAKE install
}
package() {
mkdir -p $srcdir
local LOCALDIR=$(dirname ${pkgdir})
# Install GNU stow - a symlink manager: useful to manage local installations
gnu_install stow "2.2.2" "$LOCALDIR"
export PATH=$LOCALDIR/bin:$PATH
rehash
echo "End of installation: stow"
sleep 3
# Install GNU autotools one by one
for i in autoconf,"2.69" automake,"1.15.1" libtool,"2.4.5"
do
pkgname=${i%,*};
pkgver=${i#*,};
gnu_install $pkgname $pkgver "$pkgdir/$pkgname"
cd $pkgdir
rm $pkgname/share/info/dir
echo "stow -v $pkgname"
stow -v $pkgname
rehash
echo "End of installation: $pkgname"
sleep 3
done
}
# Execute
package