blob: fca9d957bd704123982b883f681b8ad66984b4bc (
plain)
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
|
#!/bin/bash
grep "TEST_BEGIN" *.cc > tmp
echo -n "TESTFILES="
while read LINE
do
FILE=`echo $LINE | cut -d':' -f1`
NAME=`echo $FILE | cut -d'.' -f1`
TEST=test_$NAME
echo -ne "$TEST "
done < tmp
echo ""
echo ""
while read LINE
do
FILE=`echo $LINE | cut -d':' -f1`
NAME=`echo $FILE | cut -d'.' -f1`
DEPS=`cat $FILE | grep "deps:" | cut -d':' -f2`
LIBS=`cat $FILE | grep "libs:" | cut -d':' -f2`
CFLAGS=`cat $FILE | grep "cflags:" | cut -d':' -f2`
TEST=test_$NAME
echo "$TEST: $FILE $DEPS"
echo -e "\t@../../tools/test $FILE $DEPS $CFLAGS $LIBS"
echo ""
done < tmp
rm -f tmp
|