-
Notifications
You must be signed in to change notification settings - Fork 1
/
build
executable file
·54 lines (41 loc) · 1.29 KB
/
build
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
#! /bin/bash
echo "===================================================";
echo "= Automated Build Script"; =";
echo "===================================================";
# get the ROM
# print a menu to allow selection of specific ROM from a list
# ensure sources are fully synced and modify this to reflect whatever
# ROM source is being used
# get the device to build
echo -n "Device (what you would type for lunch): "
read DEVICE
# ask to clean
while [ "$CLEAN" != "Y" ] && [ "$CLEAN" != "N" ] && [ "$CLEAN" != "y" ] && [ "$CLEAN" != "n" ]; do
echo "Run make clean (y/n)?: ";
read CLEAN
if [ "$CLEAN" != "Y" ] && [ "$CLEAN" != "N" ] && [ "$CLEAN" != "y" ] && [ "$CLEAN" != "n" ]; then
echo "Who taught you how to read?";
fi
done
# ask to sync
while [ "$SYNC" != "Y" ] && [ "$SYNC" != "N" ] && [ "$SYNC" != "y" ] && [ "$SYNC" != "n" ]; do
echo "Sync the repo (y/n)?: ";
read SYNC
if [ "$SYNC" != "Y" ] && [ "$SYNC" != "N" ] && [ "$SYNC" != "y" ] && [ "$SYNC" != "n" ]; then
echo "Who taught you how to read?";
fi
done
# initialize the build environment
source build/envsetup.sh
# clean
case $CLEAN in
Y | y)
make clean && make clobber && rm -rf out
esac
# sync
case $SYNC in
Y | y)
repo sync
esac
# build
make bacon