generated from nilhoel1/ES-CPSF-Fixed-Point-WS22
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathhelper.sh
executable file
·44 lines (39 loc) · 872 Bytes
/
helper.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
#!/bin/bash
clean () {
rm -rf build/
rm compile_commands.json
}
config () {
rm -rf build ; rm compile_commands.json ; mkdir build ; cd build ; cmake -DCMAKE_EXPORT_COMPILE_COMMANDS=1 .. ; mv compile_commands.json ../
}
compile () {
cd build ; make
}
test () {
./build/bin/UnitTest --gtest_brief=1
}
case $1 in
clean)
clean
;;
config)
config
;;
c | compile | build)
compile
;;
t | test)
test
;;
*)
if [ $1 ]; then
echo "Unknown argument: $1"
fi
echo "Please provide one of the following arguments:"
echo " clean Deletes the build folder"
echo " config Creates build folder and configures build System"
echo " c | compile | build Compiles the Project"
echo " t | test Execute Unit tests, only test that Fail are printed."
exit
;;
esac