INTEGRATION: CWS dmake43p01 (1.1.2); FILE ADDED

2005/06/04 18:07:42 vq 1.1.2.1: #i39248# Add another testcase.
This commit is contained in:
Jens-Heiner Rechtien 2006-04-20 11:16:15 +00:00
parent 05068400ec
commit ed70e0dd45

34
dmake/tests/misc-1 Executable file
View file

@ -0,0 +1,34 @@
#!/bin/sh
# 04.06.2005 Volker Quetschke
# Test for a bug that dmake complained about a continuation char followed
# by a newline. This could happen if /<nl> was used in an imported
# environment variable.
# This bug was <http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=310107?>
: ${DMAKEPROG:=dmake}
file1="mymakefile.mk"
tmpfiles="$file1"
trap '{ echo "trapped signal - removing temporary files" ; rm -rf $tmpfiles ; }' 1 2 3 15
trap 'rm -rf $tmpfiles' 1 2 3 15
# Remember to quote variables in generated makefiles( $ -> \$ ).
cat > $file1 <<EOT
# Testing continuation char in recipes
SHELL*:=/bin/sh
SHELLFLAGS*:=-ce
.IMPORT : MYMACRO
all:
+echo "\$(MYMACRO)"
EOT
export MYMACRO="aa\\
aa"; ${DMAKEPROG} -r -f $file1
result=$?
test $result -eq 0 && echo "Success - Cleaning up" && rm -f ${tmpfiles}
test $result -ne 0 && echo "Failure!"
exit $result