-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathnameless
More file actions
executable file
·79 lines (65 loc) · 1.97 KB
/
nameless
File metadata and controls
executable file
·79 lines (65 loc) · 1.97 KB
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
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
#!/bin/bash
#
#****************************************************************
## Start timer:
START=$(date +%s)
#****************************************************************
## Check for missing parameters:
if [ "$1" != "s" ] && [ "$1" != "hh" ] && [ "$1" != "m7" ] && [ "$1" != "tf" ]
then
echo "No target device defined"
exit 0
fi
#****************************************************************
## Set target:
if [ "$1" = "s" ]
then
trgt=galaxysmtd
fi
if [ "$1" = "hh" ]
then
trgt=hammerhead
fi
if [ "$1" = "m7" ]
then
trgt=m7ul
fi
if [ "$1" = "tf" ]
then
trgt=tf201
fi
#****************************************************************
## Set basic folder parameters:
echo "Setting folders"
finalout=~/android/nameless/out/target/product/$trgt
androidtop=~/android/nameless
secsign=~/android/nameless/build/target/product/security
#****************************************************************
## Start the build:
echo "A nameless ROM will be build for $trgt"
#****************************************************************
## Clean environment:
cd $androidtop
make installclean
rm $finalout/system/build.prop
rm $finalout/obj/PACKAGING/target_files_intermediates/nameless_`echo $trgt`-target_files-eng.kasper.zip
rm $finalout/obj/PACKAGING/target_files_intermediates/nameless_`echo $trgt`-target_files-eng.kasper/SYSTEM/build.prop
#****************************************************************
## Make the build:
cd $androidtop/
. build/envsetup.sh
export USE_CCACHE=1
brunch `echo $trgt`
#****************************************************************
## Copy the build:
echo "Copying fininalized build to AndroidFlash directory"
mv $finalout/nameless-*.zip ~/AndroidFlash/$trgt
#****************************************************************
## Report timer:
END=$(date +%s)
ELAPSED=$((END - START))
E_MIN=$((ELAPSED / 60))
E_SEC=$((ELAPSED - E_MIN * 60))
printf "${txtgrn}Elapsed: "
[ $E_MIN != 0 ] && printf "%d min(s) " $E_MIN
printf "%d sec(s)\n ${txtrst}" $E_SEC