3 # 01.03.2006 Volker Quetschke
4 # If a dependency is added to a target after it is already build as an
5 # indered .INCLUDE makefile the new dependency can be lost in parallel
12 tmpfiles
="$file1 $file2"
14 trap '{ echo "trapped signal - removing temporary files" ; rm -rf $tmpfiles ; }' 1 2 3 15
16 # Remove files from prior failed run
19 # Remember to quote variables in generated makefiles( $ -> \$ ).
26 # The following line adds a dependency to %.obj when the %.dpcc is included
27 @+echo \$@ : \$(@:b).obj > \$@
29 # This has to be build if mytarget.dpcc is included and is requested
31 # Adding the wait makes sure that the unpatched dmake is ended before the
32 # next recipe line is started, therefore loosing it.
37 .INCLUDE : mytarget.dpcc
39 # Make this the main target
44 output
=`eval ${DMAKEPROG} -r -P2 -f $file1`
47 if test "$output" != "making: mytarget.obj"; then
51 test $result -eq 0 && echo "Success - Cleaning up" && rm -f ${tmpfiles}
52 test $result -ne 0 && echo "Failure! Recipe line got lost."