3 # Check to see how make treats includes.
4 AC_DEFUN([AM_MAKE_INCLUDE],
10 # If we don't find an include directive, just comment out the code.
11 AC_MSG_CHECKING([for style of include used by $am_make])
15 # First try GNU make style include.
16 echo "include confinc" > confmf
17 # We grep out `Entering directory' and `Leaving directory'
18 # messages which can occur if `w' ends up in MAKEFLAGS.
19 # In particular we don't look at `^make:' because GNU make might
20 # be invoked under some other name (usually "gmake"), in which
21 # case it prints its new name instead of `make'.
22 if test "`$am_make -s -f confmf 2> /dev/null | fgrep -v 'ing directory'`" = "done"; then
27 # Now try BSD make style include.
28 if test "$_am_include" = "#"; then
29 echo '.include "confinc"' > confmf
30 if test "`$am_make -s -f confmf 2> /dev/null`" = "done"; then
38 AC_MSG_RESULT($_am_result)