forked from nightingale-media-player/nightingale-deps
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathsetup_win_packages.sh
59 lines (45 loc) · 1.37 KB
/
setup_win_packages.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
#!/bin/bash
TOPDIR=$(pwd)
# Setup bundled build deps
echo "cd $TOPDIR/packages/win32"
cd $TOPDIR/packages/win32
# Precompiled things
echo "Extracting packages"
unzip bison-2.4.1.zip
unzip cmake-2.8.12.2-win32-x86.zip
unzip nasm-2.11.02-win32.zip
mkdir flex-2.5.33 regex-0.12 binutils-2.24-1
tar -j -x -f flex-2.5.33-MSYS-1.0.11-1.tar.bz2 -C flex-2.5.33
tar -j -x -f regex-0.12-MSYS-1.0.11-1.tar.bz2 -C regex-0.12
tar -j -x -f binutils-2.24-1-mingw32-bin.tar.bz2 -C binutils-2.24-1
echo "Setting up packages"
mkdir /c/ng-deps
mv bison-2.4.1 /c/ng-deps/bison-2.4.1
mv cmake-2.8.12.2-win32-x86/cmake-2.8.12.2-win32-x86 /c/ng-deps/cmake-2.8.12.2
mv nasm-2.11.02-win32/nasm-2.11.02 /c/ng-deps/nasm-2.11.02
mv flex-2.5.33 /c/ng-deps/flex-2.5.33
mv regex-0.12 /c/ng-deps/regex-0.12
mv binutils-2.24-1 /c/ng-deps/binutils-2.24-1
echo "Cleaing up"
rmdir cmake-2.8.12.2-win32-x86
rmdir nasm-2.11.02-win32
# Need to build libffi for glib
echo "Extracting libffi"
tar -x -f libffi-3.0.13.tar.gz
echo "Building libffi"
cd libffi-3.0.13
./configure --prefix=/local && make && make install
cd ..
# Need to build libtool to prevent linking problems
echo "Extracting libtool"
tar -x -f libtool-2.4.2.tar.gz
echo "Building libtool"
cd libtool-2.4.2
./configure --prefix=/local && make && make install
cd ..
echo "Cleaing up"
rm -rf libffi-3.0.13
rm -rf libtool-2.4.2
echo "cd $TOPDIR"
cd $TOPDIR
echo "Done"