summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--CMakeLists.txt67
-rw-r--r--Source/CMakeLists.txt1
-rw-r--r--Source/cmDocumentCompileDefinitions.h34
-rw-r--r--Source/cmMakefile.cxx10
-rw-r--r--Source/cmSourceFile.cxx11
-rw-r--r--Source/cmTarget.cxx10
-rw-r--r--Source/kwsys/kwsysDateStamp.cmake2
-rw-r--r--Utilities/Release/v20n250_aix_release.cmake6
-rwxr-xr-xbootstrap50
9 files changed, 128 insertions, 63 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 4508e33..37e0edc 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -16,6 +16,12 @@ IF(COMMAND CMAKE_POLICY)
CMAKE_POLICY(SET CMP0003 NEW)
ENDIF(COMMAND CMAKE_POLICY)
+IF(CMAKE_BOOTSTRAP)
+ # Running from bootstrap script. Set local variable and remove from cache.
+ SET(CMAKE_BOOTSTRAP 1)
+ UNSET(CMAKE_BOOTSTRAP CACHE)
+ENDIF()
+
MARK_AS_ADVANCED(CMAKE_BACKWARDS_COMPATIBILITY)
# Allow empty endif() and such with CMake 2.4.
@@ -53,42 +59,47 @@ MACRO(CMAKE_HANDLE_SYSTEM_LIBRARIES)
OPTION(CTEST_USE_XMLRPC "Enable xmlrpc submission method in CTest." OFF)
MARK_AS_ADVANCED(CTEST_USE_XMLRPC)
- # Allow the user to enable/disable all system utility library options
- # by setting CMAKE_USE_SYSTEM_LIBRARIES on the command line.
- IF(DEFINED CMAKE_USE_SYSTEM_LIBRARIES)
- SET(CMAKE_USE_SYSTEM_LIBRARIES_USER 1)
- ENDIF(DEFINED CMAKE_USE_SYSTEM_LIBRARIES)
- IF(CMAKE_USE_SYSTEM_LIBRARIES)
- SET(CMAKE_USE_SYSTEM_LIBRARIES ON)
- ELSE(CMAKE_USE_SYSTEM_LIBRARIES)
- SET(CMAKE_USE_SYSTEM_LIBRARIES OFF)
- ENDIF(CMAKE_USE_SYSTEM_LIBRARIES)
- IF(CMAKE_USE_SYSTEM_LIBRARIES_USER)
- SET(CMAKE_USE_SYSTEM_CURL "${CMAKE_USE_SYSTEM_LIBRARIES}"
- CACHE BOOL "Use system-installed curl" FORCE)
- SET(CMAKE_USE_SYSTEM_EXPAT "${CMAKE_USE_SYSTEM_LIBRARIES}"
- CACHE BOOL "Use system-installed expat" FORCE)
- SET(CMAKE_USE_SYSTEM_ZLIB "${CMAKE_USE_SYSTEM_LIBRARIES}"
- CACHE BOOL "Use system-installed zlib" FORCE)
- SET(CMAKE_USE_SYSTEM_BZIP2 "${CMAKE_USE_SYSTEM_LIBRARIES}"
- CACHE BOOL "Use system-installed bzip2" FORCE)
- SET(CMAKE_USE_SYSTEM_LIBARCHIVE "${CMAKE_USE_SYSTEM_LIBRARIES}"
- CACHE BOOL "Use system-installed libarchive" FORCE)
- ENDIF(CMAKE_USE_SYSTEM_LIBRARIES_USER)
+ # Allow the user to enable/disable all system utility library options by
+ # defining CMAKE_USE_SYSTEM_LIBRARIES or CMAKE_USE_SYSTEM_LIBRARY_${util}.
+ SET(UTILITIES BZIP2 CURL EXPAT LIBARCHIVE ZLIB)
+ FOREACH(util ${UTILITIES})
+ IF(NOT DEFINED CMAKE_USE_SYSTEM_LIBRARY_${util}
+ AND DEFINED CMAKE_USE_SYSTEM_LIBRARIES)
+ SET(CMAKE_USE_SYSTEM_LIBRARY_${util} "${CMAKE_USE_SYSTEM_LIBRARIES}")
+ ENDIF()
+ IF(DEFINED CMAKE_USE_SYSTEM_LIBRARY_${util})
+ IF(CMAKE_USE_SYSTEM_LIBRARY_${util})
+ SET(CMAKE_USE_SYSTEM_LIBRARY_${util} ON)
+ ELSE()
+ SET(CMAKE_USE_SYSTEM_LIBRARY_${util} OFF)
+ ENDIF()
+ IF(CMAKE_BOOTSTRAP)
+ UNSET(CMAKE_USE_SYSTEM_LIBRARY_${util} CACHE)
+ ENDIF()
+ STRING(TOLOWER "${util}" lutil)
+ SET(CMAKE_USE_SYSTEM_${util} "${CMAKE_USE_SYSTEM_LIBRARY_${util}}"
+ CACHE BOOL "Use system-installed ${lutil}" FORCE)
+ ELSE()
+ SET(CMAKE_USE_SYSTEM_LIBRARY_${util} OFF)
+ ENDIF()
+ ENDFOREACH(util)
+ IF(CMAKE_BOOTSTRAP)
+ UNSET(CMAKE_USE_SYSTEM_LIBRARIES CACHE)
+ ENDIF()
# Optionally use system utility libraries.
- OPTION(CMAKE_USE_SYSTEM_LIBARCHIVE "Use system-installed libarchive" ${CMAKE_USE_SYSTEM_LIBRARIES})
+ OPTION(CMAKE_USE_SYSTEM_LIBARCHIVE "Use system-installed libarchive" "${CMAKE_USE_SYSTEM_LIBRARY_LIBARCHIVE}")
CMAKE_DEPENDENT_OPTION(CMAKE_USE_SYSTEM_CURL "Use system-installed curl"
- ${CMAKE_USE_SYSTEM_LIBRARIES} "NOT CTEST_USE_XMLRPC" ON)
+ "${CMAKE_USE_SYSTEM_LIBRARY_CURL}" "NOT CTEST_USE_XMLRPC" ON)
CMAKE_DEPENDENT_OPTION(CMAKE_USE_SYSTEM_EXPAT "Use system-installed expat"
- ${CMAKE_USE_SYSTEM_LIBRARIES} "NOT CTEST_USE_XMLRPC" ON)
+ "${CMAKE_USE_SYSTEM_LIBRARY_EXPAT}" "NOT CTEST_USE_XMLRPC" ON)
CMAKE_DEPENDENT_OPTION(CMAKE_USE_SYSTEM_ZLIB "Use system-installed zlib"
- ${CMAKE_USE_SYSTEM_LIBRARIES} "NOT CMAKE_USE_SYSTEM_LIBARCHIVE;NOT CMAKE_USE_SYSTEM_CURL" ON)
+ "${CMAKE_USE_SYSTEM_LIBRARY_ZLIB}" "NOT CMAKE_USE_SYSTEM_LIBARCHIVE;NOT CMAKE_USE_SYSTEM_CURL" ON)
CMAKE_DEPENDENT_OPTION(CMAKE_USE_SYSTEM_BZIP2 "Use system-installed bzip2"
- ${CMAKE_USE_SYSTEM_LIBRARIES} "NOT CMAKE_USE_SYSTEM_LIBARCHIVE" ON)
+ "${CMAKE_USE_SYSTEM_LIBRARY_BZIP2}" "NOT CMAKE_USE_SYSTEM_LIBARCHIVE" ON)
# Mention to the user what system libraries are being used.
- FOREACH(util BZIP2 CURL EXPAT LIBARCHIVE ZLIB)
+ FOREACH(util ${UTILITIES})
IF(CMAKE_USE_SYSTEM_${util})
MESSAGE(STATUS "Using system-installed ${util}")
ENDIF(CMAKE_USE_SYSTEM_${util})
diff --git a/Source/CMakeLists.txt b/Source/CMakeLists.txt
index f183eb4..7722c19 100644
--- a/Source/CMakeLists.txt
+++ b/Source/CMakeLists.txt
@@ -158,6 +158,7 @@ SET(SRCS
cmDocumentationFormatterText.cxx
cmDocumentationFormatterUsage.cxx
cmDocumentationSection.cxx
+ cmDocumentCompileDefinitions.h
cmDocumentGeneratorExpressions.h
cmDocumentVariables.cxx
cmDynamicLoader.cxx
diff --git a/Source/cmDocumentCompileDefinitions.h b/Source/cmDocumentCompileDefinitions.h
new file mode 100644
index 0000000..ef3b3e7
--- /dev/null
+++ b/Source/cmDocumentCompileDefinitions.h
@@ -0,0 +1,34 @@
+/*============================================================================
+ CMake - Cross Platform Makefile Generator
+ Copyright 2000-2011 Kitware, Inc., Insight Software Consortium
+
+ Distributed under the OSI-approved BSD License (the "License");
+ see accompanying file Copyright.txt for details.
+
+ This software is distributed WITHOUT ANY WARRANTY; without even the
+ implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
+ See the License for more information.
+============================================================================*/
+#ifndef cmDocumentCompileDefinitions_h
+#define cmDocumentCompileDefinitions_h
+
+#define CM_DOCUMENT_COMPILE_DEFINITIONS_DISCLAIMER \
+ "Disclaimer: Most native build tools have poor support for escaping " \
+ "certain values. CMake has work-arounds for many cases but some " \
+ "values may just not be possible to pass correctly. If a value " \
+ "does not seem to be escaped correctly, do not attempt to " \
+ "work-around the problem by adding escape sequences to the value. " \
+ "Your work-around may break in a future version of CMake that " \
+ "has improved escape support. Instead consider defining the macro " \
+ "in a (configured) header file. Then report the limitation. " \
+ "Known limitations include:\n" \
+ " # - broken almost everywhere\n" \
+ " ; - broken in VS IDE and Borland Makefiles\n" \
+ " , - broken in VS IDE\n" \
+ " % - broken in some cases in NMake\n" \
+ " & | - broken in some cases on MinGW\n" \
+ " ^ < > \\\" - broken in most Make tools on Windows\n" \
+ "CMake does not reject these values outright because they do work " \
+ "in some cases. Use with caution. "
+
+#endif
diff --git a/Source/cmMakefile.cxx b/Source/cmMakefile.cxx
index 53f4c3c..41d36dc 100644
--- a/Source/cmMakefile.cxx
+++ b/Source/cmMakefile.cxx
@@ -22,6 +22,7 @@
#include "cmFunctionBlocker.h"
#include "cmListFileCache.h"
#include "cmCommandArgumentParserHelper.h"
+#include "cmDocumentCompileDefinitions.h"
#include "cmTest.h"
#ifdef CMAKE_BUILD_WITH_CMAKE
# include "cmVariableWatch.h"
@@ -3492,14 +3493,7 @@ void cmMakefile::DefineProperties(cmake *cm)
"are not supported by the native build tool. "
"The VS6 IDE does not support definition values with spaces "
"(but NMake does).\n"
- "Dislaimer: Most native build tools have poor support for escaping "
- "certain values. CMake has work-arounds for many cases but some "
- "values may just not be possible to pass correctly. If a value "
- "does not seem to be escaped correctly, do not attempt to "
- "work-around the problem by adding escape sequences to the value. "
- "Your work-around may break in a future version of CMake that "
- "has improved escape support. Instead consider defining the macro "
- "in a (configured) header file. Then report the limitation.");
+ CM_DOCUMENT_COMPILE_DEFINITIONS_DISCLAIMER);
cm->DefineProperty
("COMPILE_DEFINITIONS_<CONFIG>", cmProperty::DIRECTORY,
diff --git a/Source/cmSourceFile.cxx b/Source/cmSourceFile.cxx
index 26328cf..84b728e 100644
--- a/Source/cmSourceFile.cxx
+++ b/Source/cmSourceFile.cxx
@@ -16,6 +16,7 @@
#include "cmMakefile.h"
#include "cmSystemTools.h"
#include "cmake.h"
+#include "cmDocumentCompileDefinitions.h"
//----------------------------------------------------------------------------
cmSourceFile::cmSourceFile(cmMakefile* mf, const char* name):
@@ -411,15 +412,7 @@ void cmSourceFile::DefineProperties(cmake *cm)
"The VS6 IDE does not support definition values with spaces "
"(but NMake does). Xcode does not support per-configuration "
"definitions on source files.\n"
- "Disclaimer: Most native build tools have poor support for escaping "
- "certain values. CMake has work-arounds for many cases but some "
- "values may just not be possible to pass correctly. If a value "
- "does not seem to be escaped correctly, do not attempt to "
- "work-around the problem by adding escape sequences to the value. "
- "Your work-around may break in a future version of CMake that "
- "has improved escape support. Instead consider defining the macro "
- "in a (configured) header file. Then report the limitation.");
-
+ CM_DOCUMENT_COMPILE_DEFINITIONS_DISCLAIMER);
cm->DefineProperty
("COMPILE_DEFINITIONS_<CONFIG>", cmProperty::SOURCE_FILE,
diff --git a/Source/cmTarget.cxx b/Source/cmTarget.cxx
index 52574e2..72efce3 100644
--- a/Source/cmTarget.cxx
+++ b/Source/cmTarget.cxx
@@ -16,6 +16,7 @@
#include "cmLocalGenerator.h"
#include "cmGlobalGenerator.h"
#include "cmComputeLinkInformation.h"
+#include "cmDocumentCompileDefinitions.h"
#include "cmListFileCache.h"
#include "cmGeneratorExpression.h"
#include <cmsys/RegularExpression.hxx>
@@ -146,14 +147,7 @@ void cmTarget::DefineProperties(cmake *cm)
"are not supported by the native build tool. "
"The VS6 IDE does not support definition values with spaces "
"(but NMake does).\n"
- "Dislaimer: Most native build tools have poor support for escaping "
- "certain values. CMake has work-arounds for many cases but some "
- "values may just not be possible to pass correctly. If a value "
- "does not seem to be escaped correctly, do not attempt to "
- "work-around the problem by adding escape sequences to the value. "
- "Your work-around may break in a future version of CMake that "
- "has improved escape support. Instead consider defining the macro "
- "in a (configured) header file. Then report the limitation.");
+ CM_DOCUMENT_COMPILE_DEFINITIONS_DISCLAIMER);
cm->DefineProperty
("COMPILE_DEFINITIONS_<CONFIG>", cmProperty::TARGET,
diff --git a/Source/kwsys/kwsysDateStamp.cmake b/Source/kwsys/kwsysDateStamp.cmake
index 7640db0..64abcb3 100644
--- a/Source/kwsys/kwsysDateStamp.cmake
+++ b/Source/kwsys/kwsysDateStamp.cmake
@@ -18,4 +18,4 @@ SET(KWSYS_DATE_STAMP_YEAR 2011)
SET(KWSYS_DATE_STAMP_MONTH 01)
# KWSys version date day component. Format is DD.
-SET(KWSYS_DATE_STAMP_DAY 12)
+SET(KWSYS_DATE_STAMP_DAY 19)
diff --git a/Utilities/Release/v20n250_aix_release.cmake b/Utilities/Release/v20n250_aix_release.cmake
index 88eb8d0..7a5c8b9 100644
--- a/Utilities/Release/v20n250_aix_release.cmake
+++ b/Utilities/Release/v20n250_aix_release.cmake
@@ -1,9 +1,9 @@
-set(CMAKE_RELEASE_DIRECTORY "/bench1/noibm34/CMakeReleaseDirectory" )
+set(CMAKE_RELEASE_DIRECTORY "/bench1/noibm34/CMakeReleaseDirectory")
set(FINAL_PATH /u/noibm34/cmake-release)
set(PROCESSORS 2)
set(CVS_COMMAND /vol/local/bin/cvs)
-set(HOST "sshserv.centers.ihost.com" )
-set(EXTRA_HOP "rsh v20n250" )
+set(HOST "sshserv.centers.ihost.com")
+set(EXTRA_HOP "rsh p90n03")
set(MAKE_PROGRAM "make")
set(CC "xlc_r")
set(CXX "xlC_r")
diff --git a/bootstrap b/bootstrap
index b4e19ef..b95e36a 100755
--- a/bootstrap
+++ b/bootstrap
@@ -26,6 +26,11 @@ cmake_date_stamp_component()
"
}
+cmake_toupper()
+{
+ echo "$1" | sed 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'
+}
+
# Detect system and directory information.
cmake_system=`uname`
cmake_source_dir=`cd "\`dirname \"$0\"\`";pwd`
@@ -294,11 +299,23 @@ Configuration:
--verbose display more information
--parallel=n bootstrap cmake in parallel, where n is
number of nodes [1]
- --init=FILE use FILE for cmake initialization
- --system-libs use system-installed third-party libraries
+ --enable-ccache Enable ccache when building cmake
+ --init=FILE load FILE as script to populate cache
+ --system-libs use all system-installed third-party libraries
(for use only by package maintainers)
- --no-system-libs use cmake-provided third-party libraries
+ --no-system-libs use all cmake-provided third-party libraries
(default)
+ --system-curl use system-installed curl library
+ --no-system-curl use cmake-provided curl library (default)
+ --system-expat use system-installed expat library
+ --no-system-expat use cmake-provided expat library (default)
+ --system-zlib use system-installed zlib library
+ --no-system-zlib use cmake-provided zlib library (default)
+ --system-bzip2 use system-installed bzip2 library
+ --no-system-bzip2 use cmake-provided bzip2 library (default)
+ --system-libarchive use system-installed libarchive library
+ --no-system-libarchive use cmake-provided libarchive library (default)
+
--qt-gui build the Qt-based GUI (requires Qt >= 4.2)
--no-qt-gui do not build the Qt-based GUI (default)
--qt-qmake=<qmake> use <qmake> as the qmake executable to find Qt
@@ -507,6 +524,7 @@ cmake_try_make ()
# Parse arguments
cmake_verbose=
cmake_parallel_make=
+cmake_ccache_enabled=
cmake_prefix_dir="${cmake_default_prefix}"
for a in "$@"; do
if echo $a | grep "^--prefix=" > /dev/null 2> /dev/null; then
@@ -528,11 +546,20 @@ for a in "$@"; do
if echo $a | grep "^--init=" > /dev/null 2> /dev/null; then
cmake_init_file=`echo $a | sed "s/^--init=//"`
fi
+ for lib in bzip2 curl expat libarchive zlib; do
+ if echo $a | grep "^--system-${lib}" > /dev/null 2> /dev/null; then
+ cmake_bootstrap_system_libs="${cmake_bootstrap_system_libs} -DCMAKE_USE_SYSTEM_LIBRARY_`cmake_toupper ${lib}`=1"
+ break
+ elif echo $a | grep "^--no-system-${lib}" > /dev/null 2> /dev/null; then
+ cmake_bootstrap_system_libs="${cmake_bootstrap_system_libs} -DCMAKE_USE_SYSTEM_LIBRARY_`cmake_toupper ${lib}`=0"
+ break
+ fi
+ done
if echo $a | grep "^--system-libs" > /dev/null 2> /dev/null; then
- cmake_bootstrap_system_libs="-DCMAKE_USE_SYSTEM_LIBRARIES=1"
+ cmake_bootstrap_system_libs="${cmake_bootstrap_system_libs} -DCMAKE_USE_SYSTEM_LIBRARIES=1"
fi
if echo $a | grep "^--no-system-libs" > /dev/null 2> /dev/null; then
- cmake_bootstrap_system_libs="-DCMAKE_USE_SYSTEM_LIBRARIES=0"
+ cmake_bootstrap_system_libs="${cmake_bootstrap_system_libs} -DCMAKE_USE_SYSTEM_LIBRARIES=0"
fi
if echo $a | grep "^--qt-gui" > /dev/null 2> /dev/null; then
cmake_bootstrap_qt_gui="1"
@@ -553,6 +580,9 @@ for a in "$@"; do
if echo $a | grep "^--verbose" > /dev/null 2> /dev/null; then
cmake_verbose=TRUE
fi
+ if echo $a | grep "^--enable-ccache" > /dev/null 2> /dev/null; then
+ cmake_ccache_enabled=TRUE
+ fi
done
# If verbose, display some information about bootstrap
@@ -1488,13 +1518,21 @@ cd "${cmake_binary_dir}"
# build with same compiler and make
CC="${cmake_c_compiler}"
CXX="${cmake_cxx_compiler}"
+if [ -n "${cmake_ccache_enabled}" ]; then
+ CC="ccache ${CC}"
+ CXX="ccache ${CXX}"
+fi
MAKE="${cmake_make_processor}"
export CC
export CXX
export MAKE
# Run bootstrap CMake to configure real CMake
-"${cmake_bootstrap_dir}/cmake" "${cmake_source_dir}" "-C${cmake_bootstrap_dir}/InitialCacheFlags.cmake" "-G${cmake_bootstrap_generator}" ${cmake_bootstrap_system_libs}
+cmake_options="-DCMAKE_BOOTSTRAP=1"
+if [ -n "${cmake_verbose}" ]; then
+ cmake_options="${cmake_options} -DCMAKE_VERBOSE_MAKEFILE=1"
+fi
+"${cmake_bootstrap_dir}/cmake" "${cmake_source_dir}" "-C${cmake_bootstrap_dir}/InitialCacheFlags.cmake" "-G${cmake_bootstrap_generator}" ${cmake_options} ${cmake_bootstrap_system_libs}
RES=$?
if [ "${RES}" -ne "0" ]; then
cmake_error 11 "Problem while running initial CMake"