-
Notifications
You must be signed in to change notification settings - Fork 15
/
build_all.sh
executable file
·53 lines (51 loc) · 1.21 KB
/
build_all.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
#!/bin/bash
[ "$#" -gt "1" ] && echo "Too many args." && exit 1
[ "$#" -lt "1" ] && set -- "$@" "lite"
case "$(echo "$1" | tr "[:upper:]" "[:lower:]")" in
lite|light)
cp -p config.h.lite config.h
cp -p Makefile.lite Makefile
make
;;
v2)
if [ "X$MLCA_PATH" = "X" ]; then
echo "Must set MLCA_PATH env variable to point to mlca_framework repository"
exit 1
fi
cp -p config.h.lite config.h
cp -p Makefile.v2 Makefile
make
;;
gnu)
autoreconf -i -Wno-unsupported && \
./configure && \
make
;;
aix)
cp -p config.h.aix config.h
cp -p Makefile.aix Makefile
gnu-make
;;
gnuv2)
if [ "X$MLCA_PATH" = "X" ]; then
echo "Must set MLCA_PATH env variable to point to mlca_framework repository"
exit 1
fi
autoreconf -i -Wno-unsupported && \
./configure --enable-sign-v2 && \
make
;;
gnuv3)
if [ "X$MLCA_PATH" = "X" ]; then
echo "Must set MLCA_PATH env variable to point to mlca_framework repository"
exit 1
fi
autoreconf -i -Wno-unsupported && \
./configure --enable-sign-v2 && \
make
;;
*)
echo "Unknown build type: $1"
exit 1
;;
esac