-
Notifications
You must be signed in to change notification settings - Fork 166
Expand file tree
/
Copy pathmake_linux.sh
More file actions
executable file
·57 lines (48 loc) · 1.08 KB
/
Copy pathmake_linux.sh
File metadata and controls
executable file
·57 lines (48 loc) · 1.08 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
#!/bin/bash
TT_BUILD_32=TinyTracer32.so
TT_BUILD_64=TinyTracer64.so
TT_32=./obj-ia32/$TT_BUILD_32
TT_64=./obj-intel64/$TT_BUILD_64
TARGET_DIR=./install32_64
if [ -f $TT_32 ]; then
rm $TT_32
fi
if [ -f $TT_64 ]; then
rm $TT_64
fi
if [ -f $TARGET_DIR/$TT_BUILD_32 ]; then
rm $TARGET_DIR/$TT_BUILD_32
fi
if [ -f $TARGET_DIR/$TT_BUILD_64 ]; then
rm $TARGET_DIR/$TT_BUILD_64
fi
make all TARGET=ia32
make all TARGET=intel64
APP_TYPE32=$(file "$TT_32")
APP_TYPE64=$(file "$TT_64")
if [[ $APP_TYPE64 == *"ELF 64-bit"* ]];
then
echo "[+] 64 bit build ok."
cp "$TT_64" $TARGET_DIR/$TT_BUILD_64
if [[ $? == 0 ]];
then
echo "[+] 64 bit install ok."
else
echo "ERROR: 64 bit install failed."
fi
else
echo "ERROR: Could not build the 64-bit TinyTracer"
fi
if [[ $APP_TYPE32 == *"ELF 32-bit"* ]];
then
echo "[+] 32 bit build ok."
cp "$TT_32" $TARGET_DIR/$TT_BUILD_32
if [[ $? == 0 ]];
then
echo "[+] 32 bit install ok."
else
echo "ERROR: 32 bit install failed."
fi
else
echo "ERROR: Could not build the 32-bit TinyTracer"
fi