ENH: add a try compile test for makedev_three_args

This commit is contained in:
Bill Hoffman 2006-08-01 15:26:04 -04:00
parent 612d2f667b
commit e0e32400af
1 changed files with 19 additions and 1 deletions

View File

@ -236,7 +236,25 @@ SET (HAVE_LIBZ 1)
#SET (HAVE_UNISTD_H 1)
SET (MAJOR_IN_MKDEV 0)
SET (MAJOR_IN_SYSMACROS 0)
SET (MAKEDEV_THREE_ARGS 0)
SET(CMAKE_MAKEDEV_SOURCE)
FOREACH(FILE ${HEADER_INCLUDES})
SET(CMAKE_MAKEDEV_SOURCE
"${CMAKE_MAKEDEV_SOURCE}#include <${FILE}>\n")
ENDFOREACH(FILE)
SET(CMAKE_MAKEDEV_SOURCE
"${CMAKE_MAKEDEV_SOURCE}
int main ()
{
major_t maj = 5;
minor_t min = 7;
makedev(0, maj, min);
return 0;
}
")
INCLUDE(CheckCSourceCompiles)
CHECK_C_SOURCE_COMPILES("${CMAKE_MAKEDEV_SOURCE}" MAKEDEV_THREE_ARGS)
#SET (MAKEDEV_THREE_ARGS 0)
#SET (NEED_BASENAME 0)
#SET (NEED_DIRNAME 0)
#SET (NEED_FNMATCH 1)