Version 3.6.0.4, tag libreoffice-3.6.0.4
[LibreOffice.git] / dmake / tests / targets-8
blob1bb31959a4f6ed0e44d212c973eaedad088fc24d
1 #!/bin/sh
3 # 13.06.2006 Volker Quetschke
4 # .SETDIR used to fail for multiple percent targets.
5 # (issue 64431)
7 : ${DMAKEPROG:=dmake}
8 file1="mfile1.mk"
9 tmpfiles="$file1"
11 trap '{ echo "trapped signal - removing temporary files" ; rm -rf $tmpfiles ; }' 1 2 3 15
13 # Remove files from prior failed run
14 rm -rf $tmpfiles
16 # Remember to quote variables in generated makefiles( $ -> \$ ).
17 # Expect xxx.1 and xxx.2 to be build
18 # that gets build.
19 cat > $file1 <<EOT
20 SHELL*:=/bin/sh
21 SHELLFLAGS*:=-ce
23 all : xxx.1 xxx.2
25 xxx.% .SETDIR=. :
26 @+printf "OK"
28 EOT
30 output1=`eval ${DMAKEPROG} -r -f $file1 2>&1 `
31 result1=$?
33 if echo $output1 | grep 'OKOK' > /dev/null 2>&1 ; then
34 dummy=1
35 # OK
36 else
37 echo "Test 1: Wrong result: $output1"
38 echo
39 result1=1
42 if test $result1 -eq 0 ; then
43 echo "Success - Cleaning up"
44 rm -rf $tmpfiles
45 result=0
46 else
47 echo "Failure!"
48 result=1
50 exit $result