COMP: More cleanups

This commit is contained in:
Andy Cedilnik 2005-03-16 13:26:36 -05:00
parent d224858e1f
commit 3768961a66
6 changed files with 39 additions and 16 deletions

View File

@ -61,6 +61,17 @@ SET(KWSYS_USE_CommandLineArguments 1)
SET(KWSYS_HEADER_ROOT ${CMake_BINARY_DIR}/Source)
SUBDIRS(Source/kwsys)
#-----------------------------------------------------------------------------
# Build zlib library for Curl, CMake, and CTest.
SUBDIRS(Utilities/cmzlib)
SET(CMAKE_ZLIB_INCLUDES
"${CMAKE_CURRENT_BINARY_DIR}/Utilities"
)
SET(CMAKE_ZLIB_LIBRARIES "cmzlib")
SET(CURL_SPECIAL_LIBZ ${CMAKE_ZLIB_LIBRARIES})
SET(CURL_SPECIAL_LIBZ_INCLUDES ${CMAKE_ZLIB_INCLUDES})
SET(CURL_SPECIAL_ZLIB_H "cmzlib/zlib.h")
#-----------------------------------------------------------------------------
# Build Curl library for CTest.
SUBDIRS(Source/CTest/Curl)
@ -69,9 +80,11 @@ SET(CMAKE_CURL_LIBRARIES "Curl")
#-----------------------------------------------------------------------------
# Build expat library for CMake and CTest.
INCLUDE_DIRECTORIES(${CMake_BINARY_DIR}/Utilities)
SUBDIRS(Utilities/cmexpat Utilities/cmzlib)
SET(CMAKE_EXPAT_INCLUDES "${CMAKE_CURRENT_BINARY_DIR}/Utilities/cmexpat")
SUBDIRS(Utilities/cmexpat)
SET(CMAKE_EXPAT_INCLUDES
"${CMAKE_CURRENT_BINARY_DIR}/Utilities"
"${CMAKE_CURRENT_BINARY_DIR}/Utilities/cmexpat"
)
SET(CMAKE_EXPAT_LIBRARIES "cmexpat")
SUBDIRS(Utilities/cmxmlrpc)

View File

@ -124,13 +124,6 @@ MACRO(CHECK_LIBRARY_EXISTS_CONCAT LIBRARY SYMBOL VARIABLE)
ENDIF(${VARIABLE})
ENDMACRO(CHECK_LIBRARY_EXISTS_CONCAT)
IF(CURL_SPECIAL_LIBZ)
SET(CURL_LIBS ${CURL_LIBS} "${CURL_SPECIAL_LIBZ}")
INCLUDE_DIRECTORIES(${CURL_SPECIAL_LIBZ_INCLUDES})
SET(HAVE_LIBZ 0)
SET(HAVE_ZLIB_H 0)
ENDIF(CURL_SPECIAL_LIBZ)
# Check for all needed libraries
CHECK_LIBRARY_EXISTS_CONCAT("dl" dlopen HAVE_LIBDL)
CHECK_LIBRARY_EXISTS_CONCAT("ucb" gethostname HAVE_LIBUCB)
@ -160,6 +153,14 @@ CHECK_LIBRARY_EXISTS("${CURL_LIBS}" dlopen "" HAVE_DLOPEN)
# For other tests to use the same libraries
SET(CMAKE_REQUIRED_LIBRARIES ${CURL_LIBS})
IF(CURL_SPECIAL_LIBZ)
SET(CURL_LIBS ${CURL_LIBS} "${CURL_SPECIAL_LIBZ}")
INCLUDE_DIRECTORIES(${CURL_SPECIAL_LIBZ_INCLUDES})
SET(HAVE_LIBZ 0)
SET(HAVE_ZLIB_H 0)
ENDIF(CURL_SPECIAL_LIBZ)
# If we have features.h, then do the _BSD_SOURCE magic
CHECK_INCLUDE_FILE("features.h" HAVE_FEATURES_H)
IF(HAVE_FEATURES_H)

View File

@ -78,7 +78,6 @@
#include "timeval.h"
#ifdef HAVE_ZLIB_H
#error goo
#include <zlib.h> /* for content-encoding */
#endif

View File

@ -10,6 +10,10 @@ SET(expat_SRCS
INCLUDE(${CMAKE_ROOT}/Modules/TestBigEndian.cmake)
TEST_BIG_ENDIAN(CMEXPAT_BIGENDIAN)
INCLUDE_DIRECTORIES(
"${CMEXPAT_BINARY_DIR}/.."
)
IF(WIN32)
IF(NOT BUILD_SHARED_LIBS)
SET (CM_EXPAT_STATIC 1)

View File

@ -49,11 +49,13 @@ ENDIF(ATTR_UNUSED_VAR)
SET(HAVE_LIBWWW_SSL)
SET(DIRECTORY_SEPARATOR "/")
FIND_PACKAGE(Threads)
SET(HAVE_PTHREADS)
IF(WIN32 OR CMAKE_USE_PTHREADS_INIT)
SET(HAVE_PTHREADS 1)
ENDIF(WIN32 OR CMAKE_USE_PTHREADS_INIT)
IF(CMAKE_BUILD_XMLRPC_WITH_THREADS)
FIND_PACKAGE(Threads)
IF(WIN32 OR CMAKE_USE_PTHREADS_INIT)
SET(HAVE_PTHREADS 1)
ENDIF(WIN32 OR CMAKE_USE_PTHREADS_INIT)
ENDIF(CMAKE_BUILD_XMLRPC_WITH_THREADS)
INCLUDE_DIRECTORIES(
"${CMAKE_CURRENT_SOURCE_DIR}"

View File

@ -1,7 +1,11 @@
PROJECT(CMZLIB)
INCLUDE_REGULAR_EXPRESSION("^(deflate|inf|trees|zconf|zlib|zutil).*$")
INCLUDE_DIRECTORIES(${CMZLIB_SOURCE_DIR})
INCLUDE_DIRECTORIES(
"${CMZLIB_SOURCE_DIR}"
"${CMZLIB_SOURCE_DIR}/.."
"${CMZLIB_BINARY_DIR}/.."
)
# Tell the header files included from the .c files that they are being
# built. Used to disable warnings since we do not want to change the