summaryrefslogtreecommitdiff
path: root/Utilities/cmcurl
diff options
context:
space:
mode:
authorBill Hoffman <bill.hoffman@kitware.com>2006-01-17 10:21:45 -0500
committerBill Hoffman <bill.hoffman@kitware.com>2006-01-17 10:21:45 -0500
commit9891260a6dab66c9ea44b5c2e244f3128625baf5 (patch)
tree930651e4383fe1d904cc9c493bd859cb97b530af /Utilities/cmcurl
parent2694ad76c538333d3ff45613bd1201f97af003cd (diff)
downloadcmake-9891260a6dab66c9ea44b5c2e244f3128625baf5.tar.gz
ENH: add support for watcom wmake and wcl386
Diffstat (limited to 'Utilities/cmcurl')
-rw-r--r--Utilities/cmcurl/CMake/CheckTypeSize.c.in2
-rw-r--r--Utilities/cmcurl/CMake/CheckTypeSize.cmake20
-rw-r--r--Utilities/cmcurl/CMakeLists.txt1
-rw-r--r--Utilities/cmcurl/Platforms/WindowsCache.cmake1
-rw-r--r--Utilities/cmcurl/timeval.h2
5 files changed, 12 insertions, 14 deletions
diff --git a/Utilities/cmcurl/CMake/CheckTypeSize.c.in b/Utilities/cmcurl/CMake/CheckTypeSize.c.in
index 822d9c5e62..8c9a0163e5 100644
--- a/Utilities/cmcurl/CMake/CheckTypeSize.c.in
+++ b/Utilities/cmcurl/CMake/CheckTypeSize.c.in
@@ -1,7 +1,7 @@
+#cmakedefine CHECK_TYPE_SIZE_TYPE @CHECK_TYPE_SIZE_TYPE@
#ifdef CHECK_TYPE_SIZE_TYPE
@CHECK_TYPE_SIZE_PREINCLUDE@
-
#ifdef HAVE_SYS_TYPES_H
# include <sys/types.h>
#endif /* HAVE_SYS_TYPES_H */
diff --git a/Utilities/cmcurl/CMake/CheckTypeSize.cmake b/Utilities/cmcurl/CMake/CheckTypeSize.cmake
index 26c822da2c..be76154168 100644
--- a/Utilities/cmcurl/CMake/CheckTypeSize.cmake
+++ b/Utilities/cmcurl/CMake/CheckTypeSize.cmake
@@ -1,28 +1,28 @@
-#
+# - Check sizeof a type
+# CHECK_TYPE_SIZE(TYPE VARIABLE)
# Check if the type exists and determine size of type. if the type
# exists, the size will be stored to the variable.
#
-# CHECK_TYPE_SIZE - macro which checks the size of type
-# VARIABLE - variable to store size if the type exists.
-# HAVE_${VARIABLE} - does the variable exists or not
-#
+# VARIABLE - variable to store size if the type exists.
+# HAVE_${VARIABLE} - does the variable exists or not
MACRO(CHECK_TYPE_SIZE TYPE VARIABLE)
SET(CMAKE_ALLOW_UNKNOWN_VARIABLE_READ_ACCESS 1)
IF("HAVE_${VARIABLE}" MATCHES "^HAVE_${VARIABLE}$")
+ SET(CHECK_TYPE_SIZE_TYPE "${TYPE}")
SET(MACRO_CHECK_TYPE_SIZE_FLAGS
- "-DCHECK_TYPE_SIZE_TYPE=\"${TYPE}\" ${CMAKE_REQUIRED_FLAGS}")
+ "${CMAKE_REQUIRED_FLAGS}")
FOREACH(def HAVE_SYS_TYPES_H HAVE_STDINT_H HAVE_STDDEF_H)
IF("${def}")
SET(MACRO_CHECK_TYPE_SIZE_FLAGS
"${MACRO_CHECK_TYPE_SIZE_FLAGS} -D${def}")
ENDIF("${def}")
ENDFOREACH(def)
- SET(CHECK_TYPE_SIZE_PREMAIN)
+ SET(CHECK_TYPE_SIZE_PREINCLUDE)
FOREACH(def ${CMAKE_EXTRA_INCLUDE_FILES})
SET(CHECK_TYPE_SIZE_PREMAIN "${CHECK_TYPE_SIZE_PREMAIN}#include \"${def}\"\n")
ENDFOREACH(def)
- CONFIGURE_FILE("${CMAKE_CURRENT_SOURCE_DIR}/CMake/CheckTypeSize.c.in"
+ CONFIGURE_FILE("${CMAKE_ROOT}/Modules/CheckTypeSize.c.in"
"${CMAKE_BINARY_DIR}/CMakeFiles/CMakeTmp/CheckTypeSize.c" IMMEDIATE @ONLY)
FILE(READ "${CMAKE_BINARY_DIR}/CMakeFiles/CMakeTmp/CheckTypeSize.c"
CHECK_TYPE_SIZE_FILE_CONTENT)
@@ -39,11 +39,11 @@ MACRO(CHECK_TYPE_SIZE TYPE VARIABLE)
OUTPUT_VARIABLE OUTPUT)
IF(HAVE_${VARIABLE})
MESSAGE(STATUS "Check size of ${TYPE} - done")
- FILE(APPEND ${CMAKE_BINARY_DIR}/CMakeOutput.log
+ FILE(APPEND ${CMAKE_BINARY_DIR}/CMakeFiles/CMakeOutput.log
"Determining size of ${TYPE} passed with the following output:\n${OUTPUT}\n\n")
ELSE(HAVE_${VARIABLE})
MESSAGE(STATUS "Check size of ${TYPE} - failed")
- FILE(APPEND ${CMAKE_BINARY_DIR}/CMakeError.log
+ FILE(APPEND ${CMAKE_BINARY_DIR}/CMakeFiles/CMakeError.log
"Determining size of ${TYPE} failed with the following output:\n${OUTPUT}\nCheckTypeSize.c:\n${CHECK_TYPE_SIZE_FILE_CONTENT}\n\n")
ENDIF(HAVE_${VARIABLE})
ENDIF("HAVE_${VARIABLE}" MATCHES "^HAVE_${VARIABLE}$")
diff --git a/Utilities/cmcurl/CMakeLists.txt b/Utilities/cmcurl/CMakeLists.txt
index f2367e497c..b6152420e3 100644
--- a/Utilities/cmcurl/CMakeLists.txt
+++ b/Utilities/cmcurl/CMakeLists.txt
@@ -252,7 +252,6 @@ CHECK_INCLUDE_FILE_CONCAT("setjmp.h" HAVE_SETJMP_H)
CHECK_INCLUDE_FILE_CONCAT("signal.h" HAVE_SIGNAL_H)
CHECK_INCLUDE_FILE_CONCAT("sys/ioctl.h" HAVE_SYS_IOCTL_H)
CHECK_INCLUDE_FILE_CONCAT("sys/utsname.h" HAVE_SYS_UTSNAME_H)
-
CHECK_TYPE_SIZE(size_t SIZEOF_SIZE_T)
CHECK_TYPE_SIZE(ssize_t SIZEOF_SSIZE_T)
CHECK_TYPE_SIZE("long long" SIZEOF_LONG_LONG)
diff --git a/Utilities/cmcurl/Platforms/WindowsCache.cmake b/Utilities/cmcurl/Platforms/WindowsCache.cmake
index 1a84b37784..d660c0a771 100644
--- a/Utilities/cmcurl/Platforms/WindowsCache.cmake
+++ b/Utilities/cmcurl/Platforms/WindowsCache.cmake
@@ -51,7 +51,6 @@ IF(NOT UNIX)
SET(HAVE_ZLIB_H 0)
SET(HAVE_SIZEOF_LONG_DOUBLE 1)
- SET(HAVE_SIZEOF_SSIZE_T 0)
SET(SIZEOF_LONG_DOUBLE 8)
SET(HAVE_SOCKET 1)
diff --git a/Utilities/cmcurl/timeval.h b/Utilities/cmcurl/timeval.h
index 67b885ac6a..efe377e0d8 100644
--- a/Utilities/cmcurl/timeval.h
+++ b/Utilities/cmcurl/timeval.h
@@ -37,7 +37,7 @@
#endif
#ifndef HAVE_GETTIMEOFDAY
-#if !defined(_WINSOCKAPI_) && !defined(__MINGW32__) && !defined(_AMIGASF) && \
+#if !defined(_WINSOCKAPI_) && !defined(__WATCOMC__) && !defined(__MINGW32__) && !defined(_AMIGASF) && \
!defined(__LCC__)
struct timeval {
long tv_sec;