Speedup the test
This commit is contained in:
parent
d6e6dcc3c0
commit
8d20322160
|
@ -5,24 +5,13 @@ SET (TEST_COMMAND_TEST1 1)
|
|||
|
||||
INCLUDE (${CMAKE_ROOT}/Modules/CheckSizeOf.cmake)
|
||||
CHECK_TYPE_SIZE(char SIZEOF_CHAR)
|
||||
CHECK_TYPE_SIZE(short SIZEOF_SHORT)
|
||||
CHECK_TYPE_SIZE(int SIZEOF_INT)
|
||||
CHECK_TYPE_SIZE(long SIZEOF_LONG)
|
||||
CHECK_TYPE_SIZE("long long" SIZEOF_LONG_LONG)
|
||||
CHECK_TYPE_SIZE(__int64 SIZEOF___INT64)
|
||||
|
||||
INCLUDE (${CMAKE_ROOT}/Modules/CheckFunctionExists.cmake)
|
||||
CHECK_FUNCTION_EXISTS(vsprintf HAVE_VSPRINTF)
|
||||
CHECK_FUNCTION_EXISTS(vsnprintf HAVE_VSNPRINTF)
|
||||
CHECK_FUNCTION_EXISTS(printf HAVE_PRINTF)
|
||||
CHECK_FUNCTION_EXISTS(vsblabla HAVE_VSBLABLA)
|
||||
CHECK_FUNCTION_EXISTS(gethostbyname HAVE_GETHOSTBYNAME)
|
||||
CHECK_FUNCTION_EXISTS(connect HAVE_CONNECT)
|
||||
CHECK_FUNCTION_EXISTS(remove HAVE_REMOVE)
|
||||
CHECK_FUNCTION_EXISTS(shmat HAVE_SHMAT)
|
||||
|
||||
INCLUDE (${CMAKE_ROOT}/Modules/CheckIncludeFile.cmake)
|
||||
CHECK_INCLUDE_FILE("sys/prctl.h" HAVE_SYS_PRCTL_H)
|
||||
CHECK_INCLUDE_FILE("sys/prafasdfctl.h" HAVE_SYS_PRAFASDFCTL_H)
|
||||
|
||||
INCLUDE (${CMAKE_ROOT}/Modules/CheckLibraryExists.cmake)
|
||||
CHECK_LIBRARY_EXISTS(m ceil "" HAVE_LIBM)
|
||||
|
|
|
@ -1,7 +1,18 @@
|
|||
#include "LoadedCommand.h"
|
||||
#include <stdio.h>
|
||||
|
||||
int main ()
|
||||
{
|
||||
#ifdef HAVE_VSBLABLA
|
||||
printf("Should not be able to find vsblabla\n");
|
||||
return 1;
|
||||
#endif
|
||||
|
||||
#if !defined( HAVE_PRINTF )
|
||||
printf("Should be able to find printf\n");
|
||||
return 1;
|
||||
#endif
|
||||
|
||||
#ifdef CMAKE_IS_FUN
|
||||
return SIZEOF_CHAR-1;
|
||||
#else
|
||||
|
|
|
@ -1,23 +1,12 @@
|
|||
/* Check for size of types */
|
||||
#cmakedefine SIZEOF_CHAR ${SIZEOF_CHAR}
|
||||
#cmakedefine SIZEOF_SHORT ${SIZEOF_SHORT}
|
||||
#cmakedefine SIZEOF_INT ${SIZEOF_INT}
|
||||
#cmakedefine SIZEOF_LONG ${SIZEOF_LONG}
|
||||
#cmakedefine SIZEOF_LONG_LONG ${SIZEOF_LONG_LONG}
|
||||
#cmakedefine SIZEOF___INT64 ${SIZEOF___INT64}
|
||||
|
||||
/* Check for functions */
|
||||
#cmakedefine HAVE_VSPRINTF
|
||||
#cmakedefine HAVE_VSNPRINTF
|
||||
#cmakedefine HAVE_PRINTF
|
||||
#cmakedefine HAVE_VSBLABLA
|
||||
#cmakedefine HAVE_GETHOSTBYNAME
|
||||
#cmakedefine HAVE_CONNECT
|
||||
#cmakedefine HAVE_REMOVE
|
||||
#cmakedefine HAVE_SHMAT
|
||||
|
||||
/* Check for headers */
|
||||
#cmakedefine HAVE_SYS_PRCTL_H
|
||||
#cmakedefine HAVE_SYS_PRAFASDFCTL_H
|
||||
|
||||
/* Check for libraries */
|
||||
#cmakedefine HAVE_LIBM
|
|
@ -5,24 +5,13 @@ SET (TEST_COMMAND_TEST1 1)
|
|||
|
||||
INCLUDE (${CMAKE_ROOT}/Modules/CheckSizeOf.cmake)
|
||||
CHECK_TYPE_SIZE(char SIZEOF_CHAR)
|
||||
CHECK_TYPE_SIZE(short SIZEOF_SHORT)
|
||||
CHECK_TYPE_SIZE(int SIZEOF_INT)
|
||||
CHECK_TYPE_SIZE(long SIZEOF_LONG)
|
||||
CHECK_TYPE_SIZE("long long" SIZEOF_LONG_LONG)
|
||||
CHECK_TYPE_SIZE(__int64 SIZEOF___INT64)
|
||||
|
||||
INCLUDE (${CMAKE_ROOT}/Modules/CheckFunctionExists.cmake)
|
||||
CHECK_FUNCTION_EXISTS(vsprintf HAVE_VSPRINTF)
|
||||
CHECK_FUNCTION_EXISTS(vsnprintf HAVE_VSNPRINTF)
|
||||
CHECK_FUNCTION_EXISTS(printf HAVE_PRINTF)
|
||||
CHECK_FUNCTION_EXISTS(vsblabla HAVE_VSBLABLA)
|
||||
CHECK_FUNCTION_EXISTS(gethostbyname HAVE_GETHOSTBYNAME)
|
||||
CHECK_FUNCTION_EXISTS(connect HAVE_CONNECT)
|
||||
CHECK_FUNCTION_EXISTS(remove HAVE_REMOVE)
|
||||
CHECK_FUNCTION_EXISTS(shmat HAVE_SHMAT)
|
||||
|
||||
INCLUDE (${CMAKE_ROOT}/Modules/CheckIncludeFile.cmake)
|
||||
CHECK_INCLUDE_FILE("sys/prctl.h" HAVE_SYS_PRCTL_H)
|
||||
CHECK_INCLUDE_FILE("sys/prafasdfctl.h" HAVE_SYS_PRAFASDFCTL_H)
|
||||
|
||||
INCLUDE (${CMAKE_ROOT}/Modules/CheckLibraryExists.cmake)
|
||||
CHECK_LIBRARY_EXISTS(m ceil "" HAVE_LIBM)
|
||||
|
|
|
@ -1,7 +1,18 @@
|
|||
#include "LoadedCommand.h"
|
||||
#include <stdio.h>
|
||||
|
||||
int main ()
|
||||
{
|
||||
#ifdef HAVE_VSBLABLA
|
||||
printf("Should not be able to find vsblabla\n");
|
||||
return 1;
|
||||
#endif
|
||||
|
||||
#if !defined( HAVE_PRINTF )
|
||||
printf("Should be able to find printf\n");
|
||||
return 1;
|
||||
#endif
|
||||
|
||||
#ifdef CMAKE_IS_FUN
|
||||
return SIZEOF_CHAR-1;
|
||||
#else
|
||||
|
|
|
@ -1,23 +1,12 @@
|
|||
/* Check for size of types */
|
||||
#cmakedefine SIZEOF_CHAR ${SIZEOF_CHAR}
|
||||
#cmakedefine SIZEOF_SHORT ${SIZEOF_SHORT}
|
||||
#cmakedefine SIZEOF_INT ${SIZEOF_INT}
|
||||
#cmakedefine SIZEOF_LONG ${SIZEOF_LONG}
|
||||
#cmakedefine SIZEOF_LONG_LONG ${SIZEOF_LONG_LONG}
|
||||
#cmakedefine SIZEOF___INT64 ${SIZEOF___INT64}
|
||||
|
||||
/* Check for functions */
|
||||
#cmakedefine HAVE_VSPRINTF
|
||||
#cmakedefine HAVE_VSNPRINTF
|
||||
#cmakedefine HAVE_PRINTF
|
||||
#cmakedefine HAVE_VSBLABLA
|
||||
#cmakedefine HAVE_GETHOSTBYNAME
|
||||
#cmakedefine HAVE_CONNECT
|
||||
#cmakedefine HAVE_REMOVE
|
||||
#cmakedefine HAVE_SHMAT
|
||||
|
||||
/* Check for headers */
|
||||
#cmakedefine HAVE_SYS_PRCTL_H
|
||||
#cmakedefine HAVE_SYS_PRAFASDFCTL_H
|
||||
|
||||
/* Check for libraries */
|
||||
#cmakedefine HAVE_LIBM
|
Loading…
Reference in New Issue