forked from n-ando/OpenRTM-aist-Java
-
Notifications
You must be signed in to change notification settings - Fork 5
/
buildTests.sh
executable file
·51 lines (45 loc) · 1.17 KB
/
buildTests.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
45
46
47
48
49
50
51
#!/bin/sh
#
#
#------------------------------------------------------------
# find_anthome
#
# This function estimate ANT_HOME from ant, which usually
# is a symbolic link to $ANT_HOME/bin/ant.
#------------------------------------------------------------
find_anthome()
{
if test ! "x$ANT_HOME" = "x" ; then
if test -d $ANT_HOME && test -f $ANT_HOME/bin/ant ; then
return 0
fi
echo "ant cannot be found under ANT_HOME: $ANT_HOME"
fi
echo "Valid Environment variable ANT_HOME is not set. Searching..."
tmp=`readlink -e $(which ant)`
ant_path=`dirname $tmp | sed 's/\/bin$//'`
if test "x$ant_path" = "x" ; then
echo "Ant not found. Please install Ant and set ANT_HOME."
exit 1
fi
export ANT_HOME=$ant_path
return 0
}
find_anthome
export JUNIT_HOME=$ANT_HOME/lib
echo "------------------------------------------------------------"
echo "Environment variables:"
echo "ANT_HOME: $ANT_HOME"
echo "------------------------------------------------------------"
#
#
#
cd jp.go.aist.rtm.RTC
ant compile_tests -lib $ANT_HOME/lib/
ant junit -lib $ANT_HOME/lib/
if [ $? -ne 0 ];
then
exit 1
fi
echo "--"
cd ..