diff options
Diffstat (limited to 'Modules')
-rw-r--r-- | Modules/CMakeDetermineCompilerABI.cmake | 5 | ||||
-rw-r--r-- | Modules/CMakeMinGWFindMake.cmake | 4 | ||||
-rw-r--r-- | Modules/CPackWIX.cmake | 26 | ||||
-rw-r--r-- | Modules/FindCUDA.cmake | 6 | ||||
-rw-r--r-- | Modules/FindQt4.cmake | 30 | ||||
-rw-r--r-- | Modules/SelectLibraryConfigurations.cmake | 74 | ||||
-rw-r--r-- | Modules/UseJava.cmake | 2 |
7 files changed, 80 insertions, 67 deletions
diff --git a/Modules/CMakeDetermineCompilerABI.cmake b/Modules/CMakeDetermineCompilerABI.cmake index 44cc04a..e9ae995 100644 --- a/Modules/CMakeDetermineCompilerABI.cmake +++ b/Modules/CMakeDetermineCompilerABI.cmake @@ -41,6 +41,7 @@ function(CMAKE_DETERMINE_COMPILER_ABI lang src) "--no-warn-unused-cli" OUTPUT_VARIABLE OUTPUT COPY_FILE "${BIN}" + COPY_FILE_ERROR _copy_error ) # Move result from cache to normal variable. set(CMAKE_${lang}_ABI_COMPILED ${CMAKE_${lang}_ABI_COMPILED}) @@ -48,7 +49,7 @@ function(CMAKE_DETERMINE_COMPILER_ABI lang src) set(CMAKE_${lang}_ABI_COMPILED ${CMAKE_${lang}_ABI_COMPILED} PARENT_SCOPE) # Load the resulting information strings. - if(CMAKE_${lang}_ABI_COMPILED) + if(CMAKE_${lang}_ABI_COMPILED AND NOT _copy_error) message(STATUS "Detecting ${lang} compiler ABI info - done") file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeOutput.log "Detecting ${lang} compiler ABI info compiled with the following output:\n${OUTPUT}\n\n") @@ -131,7 +132,7 @@ function(CMAKE_DETERMINE_COMPILER_ABI lang src) else() message(STATUS "Detecting ${lang} compiler ABI info - failed") file(APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log - "Detecting ${lang} compiler ABI info failed to compile with the following output:\n${OUTPUT}\n\n") + "Detecting ${lang} compiler ABI info failed to compile with the following output:\n${OUTPUT}\n${_copy_error}\n\n") endif() endif() endfunction() diff --git a/Modules/CMakeMinGWFindMake.cmake b/Modules/CMakeMinGWFindMake.cmake index efba20a..d7298dc 100644 --- a/Modules/CMakeMinGWFindMake.cmake +++ b/Modules/CMakeMinGWFindMake.cmake @@ -14,7 +14,9 @@ find_program(CMAKE_MAKE_PROGRAM mingw32-make.exe PATHS "[HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Uninstall\\MinGW;InstallLocation]/bin" - c:/MinGW/bin /MinGW/bin) + c:/MinGW/bin /MinGW/bin + "[HKEY_CURRENT_USER\\Software\\CodeBlocks;Path]/MinGW/bin" + ) find_program(CMAKE_SH sh.exe ) if(CMAKE_SH) message(FATAL_ERROR "sh.exe was found in your PATH, here:\n${CMAKE_SH}\nFor MinGW make to work correctly sh.exe must NOT be in your path.\nRun cmake from a shell that does not have sh.exe in your PATH.\nIf you want to use a UNIX shell, then use MSYS Makefiles.\n") diff --git a/Modules/CPackWIX.cmake b/Modules/CPackWIX.cmake index 0c0a8f1..fce25f0 100644 --- a/Modules/CPackWIX.cmake +++ b/Modules/CPackWIX.cmake @@ -76,6 +76,32 @@ # This image must be 493 by 312 pixels. # ##end +# +##variable +# CPACK_WIX_PROGRAM_MENU_FOLDER - Start menu folder name for launcher. +# +# If this variable is not set, it will be initialized with CPACK_PACKAGE_NAME +# +##end +##variable +# CPACK_WIX_CULTURES - Language(s) of the installer +# +# Languages are compiled into the WixUI extension library. To use them, +# simply provide the name of the culture. If you specify more than one +# culture identifier in a comma or semicolon delimited list, the first one +# that is found will be used. You can find a list of supported languages at: +# http://wix.sourceforge.net/manual-wix3/WixUI_localization.htm +# +##end +##variable +# CPACK_WIX_TEMPLATE - Template file for WiX generation +# +# If this variable is set, the specified template will be used to generate the WiX wxs file. +# This should be used if further customization of the output is required. +# +# If this variable is not set, the default MSI template included with CMake will be used. +# +##end #============================================================================= # Copyright 2012 Kitware, Inc. diff --git a/Modules/FindCUDA.cmake b/Modules/FindCUDA.cmake index 5a680e3..0390ae4 100644 --- a/Modules/FindCUDA.cmake +++ b/Modules/FindCUDA.cmake @@ -607,7 +607,11 @@ macro(cuda_find_library_local_first_with_path_ext _var _names _doc _path_ext ) NO_DEFAULT_PATH ) # Search default search paths, after we search our own set of paths. - find_library(${_var} NAMES ${_names} DOC ${_doc}) + find_library(${_var} + NAMES ${_names} + PATHS "/usr/lib/nvidia-current" + DOC ${_doc} + ) endmacro() macro(cuda_find_library_local_first _var _names _doc) diff --git a/Modules/FindQt4.cmake b/Modules/FindQt4.cmake index 7b37e1e..7e9caa2 100644 --- a/Modules/FindQt4.cmake +++ b/Modules/FindQt4.cmake @@ -886,20 +886,16 @@ if (QT_QMAKE_EXECUTABLE AND QTVERSION) endforeach() if(Q_WS_WIN) - if (QT_QAXCONTAINER_FOUND) - set(QT_MODULES ${QT_MODULES} QAxContainer) - # Set QT_AXCONTAINER_INCLUDE_DIR and QT_AXSERVER_INCLUDE_DIR - find_path(QT_QAXCONTAINER_INCLUDE_DIR ActiveQt - PATHS ${QT_HEADERS_DIR}/ActiveQt - NO_DEFAULT_PATH NO_CMAKE_FIND_ROOT_PATH - ) - endif() - if (QT_QAXSERVER_FOUND) - find_path(QT_QAXSERVER_INCLUDE_DIR ActiveQt - PATHS ${QT_HEADERS_DIR}/ActiveQt - NO_DEFAULT_PATH NO_CMAKE_FIND_ROOT_PATH - ) - endif() + set(QT_MODULES ${QT_MODULES} QAxContainer) + # Set QT_AXCONTAINER_INCLUDE_DIR and QT_AXSERVER_INCLUDE_DIR + find_path(QT_QAXCONTAINER_INCLUDE_DIR ActiveQt + PATHS ${QT_HEADERS_DIR}/ActiveQt + NO_DEFAULT_PATH NO_CMAKE_FIND_ROOT_PATH + ) + find_path(QT_QAXSERVER_INCLUDE_DIR ActiveQt + PATHS ${QT_HEADERS_DIR}/ActiveQt + NO_DEFAULT_PATH NO_CMAKE_FIND_ROOT_PATH + ) endif() # Set QT_QTDESIGNERCOMPONENTS_INCLUDE_DIR @@ -1060,8 +1056,8 @@ if (QT_QMAKE_EXECUTABLE AND QTVERSION) if(Q_WS_WIN) _QT4_ADJUST_LIB_VARS(qtmain) + _QT4_ADJUST_LIB_VARS(QAxServer) if(QT_QAXSERVER_FOUND) - _QT4_ADJUST_LIB_VARS(QAxServer) set_property(TARGET Qt4::QAxServer PROPERTY INTERFACE_QT4_NO_LINK_QTMAIN ON ) @@ -1069,9 +1065,7 @@ if (QT_QMAKE_EXECUTABLE AND QTVERSION) COMPATIBLE_INTERFACE_BOOL QT4_NO_LINK_QTMAIN) endif() - if(QT_QAXCONTAINER_FOUND) - _QT4_ADJUST_LIB_VARS(QAxContainer) - endif() + _QT4_ADJUST_LIB_VARS(QAxContainer) endif() # Only public dependencies are listed here. diff --git a/Modules/SelectLibraryConfigurations.cmake b/Modules/SelectLibraryConfigurations.cmake index 5bca064..297e1d3 100644 --- a/Modules/SelectLibraryConfigurations.cmake +++ b/Modules/SelectLibraryConfigurations.cmake @@ -3,16 +3,18 @@ # This macro takes a library base name as an argument, and will choose good # values for basename_LIBRARY, basename_LIBRARIES, basename_LIBRARY_DEBUG, and # basename_LIBRARY_RELEASE depending on what has been found and set. If only -# basename_LIBRARY_RELEASE is defined, basename_LIBRARY, basename_LIBRARY_DEBUG, -# and basename_LIBRARY_RELEASE will be set to the release value. If only -# basename_LIBRARY_DEBUG is defined, then basename_LIBRARY, -# basename_LIBRARY_DEBUG and basename_LIBRARY_RELEASE will take the debug value. +# basename_LIBRARY_RELEASE is defined, basename_LIBRARY will be set to the +# release value, and basename_LIBRARY_DEBUG will be set to +# basename_LIBRARY_DEBUG-NOTFOUND. If only basename_LIBRARY_DEBUG is defined, +# then basename_LIBRARY will take the debug value, and basename_LIBRARY_RELEASE +# will be set to basename_LIBRARY_RELEASE-NOTFOUND. # # If the generator supports configuration types, then basename_LIBRARY and # basename_LIBRARIES will be set with debug and optimized flags specifying the # library to be used for the given configuration. If no build type has been set # or the generator in use does not support configuration types, then -# basename_LIBRARY and basename_LIBRARIES will take only the release values. +# basename_LIBRARY and basename_LIBRARIES will take only the release value, or +# the debug value if the release one is not set. #============================================================================= # Copyright 2009 Will Dicharry <wdicharry@stellarscience.com> @@ -31,57 +33,41 @@ # This macro was adapted from the FindQt4 CMake module and is maintained by Will # Dicharry <wdicharry@stellarscience.com>. -# Utility macro to check if one variable exists while another doesn't, and set -# one that doesn't exist to the one that exists. -macro( _set_library_name basename GOOD BAD ) - if( ${basename}_LIBRARY_${GOOD} AND NOT ${basename}_LIBRARY_${BAD} ) - set( ${basename}_LIBRARY_${BAD} ${${basename}_LIBRARY_${GOOD}} ) - set( ${basename}_LIBRARY ${${basename}_LIBRARY_${GOOD}} ) - set( ${basename}_LIBRARIES ${${basename}_LIBRARY_${GOOD}} ) - endif() -endmacro() - macro( select_library_configurations basename ) - # if only the release version was found, set the debug to be the release - # version. - _set_library_name( ${basename} RELEASE DEBUG ) - # if only the debug version was found, set the release value to be the - # debug value. - _set_library_name( ${basename} DEBUG RELEASE ) - - # Set a default case, which will come into effect if - # -no build type is set and the generator only supports one build type - # at a time (i.e. CMAKE_CONFIGURATION_TYPES is false) - # -${basename}_LIBRARY_DEBUG and ${basename}_LIBRARY_RELEASE are the same - # -${basename}_LIBRARY_DEBUG and ${basename}_LIBRARY_RELEASE are both empty - set( ${basename}_LIBRARY ${${basename}_LIBRARY_RELEASE} ) - set( ${basename}_LIBRARIES ${${basename}_LIBRARY_RELEASE} ) + if(NOT ${basename}_LIBRARY_RELEASE) + set(${basename}_LIBRARY_RELEASE "${basename}_LIBRARY_RELEASE-NOTFOUND" CACHE FILEPATH "Path to a library.") + endif() + if(NOT ${basename}_LIBRARY_DEBUG) + set(${basename}_LIBRARY_DEBUG "${basename}_LIBRARY_DEBUG-NOTFOUND" CACHE FILEPATH "Path to a library.") + endif() if( ${basename}_LIBRARY_DEBUG AND ${basename}_LIBRARY_RELEASE AND - NOT ${basename}_LIBRARY_DEBUG STREQUAL ${basename}_LIBRARY_RELEASE ) + NOT ${basename}_LIBRARY_DEBUG STREQUAL ${basename}_LIBRARY_RELEASE AND + ( CMAKE_CONFIGURATION_TYPES OR CMAKE_BUILD_TYPE ) ) # if the generator supports configuration types or CMAKE_BUILD_TYPE # is set, then set optimized and debug options. - if( CMAKE_CONFIGURATION_TYPES OR CMAKE_BUILD_TYPE ) - set( ${basename}_LIBRARY "" ) - foreach( _libname IN LISTS ${basename}_LIBRARY_RELEASE ) - list( APPEND ${basename}_LIBRARY optimized "${_libname}" ) - endforeach() - foreach( _libname IN LISTS ${basename}_LIBRARY_DEBUG ) - list( APPEND ${basename}_LIBRARY debug "${_libname}" ) - endforeach() - set( ${basename}_LIBRARIES "${${basename}_LIBRARY}" ) - endif() + set( ${basename}_LIBRARY "" ) + foreach( _libname IN LISTS ${basename}_LIBRARY_RELEASE ) + list( APPEND ${basename}_LIBRARY optimized "${_libname}" ) + endforeach() + foreach( _libname IN LISTS ${basename}_LIBRARY_DEBUG ) + list( APPEND ${basename}_LIBRARY debug "${_libname}" ) + endforeach() + elseif( ${basename}_LIBRARY_RELEASE ) + set( ${basename}_LIBRARY ${${basename}_LIBRARY_RELEASE} ) + elseif( ${basename}_LIBRARY_DEBUG ) + set( ${basename}_LIBRARY ${${basename}_LIBRARY_DEBUG} ) + else() + set( ${basename}_LIBRARY "${basename}_LIBRARY-NOTFOUND") endif() - set( ${basename}_LIBRARY ${${basename}_LIBRARY} CACHE FILEPATH - "The ${basename} library" ) + set( ${basename}_LIBRARIES "${${basename}_LIBRARY}" ) if( ${basename}_LIBRARY ) set( ${basename}_FOUND TRUE ) endif() - mark_as_advanced( ${basename}_LIBRARY - ${basename}_LIBRARY_RELEASE + mark_as_advanced( ${basename}_LIBRARY_RELEASE ${basename}_LIBRARY_DEBUG ) endmacro() diff --git a/Modules/UseJava.cmake b/Modules/UseJava.cmake index f518b14..c0fd07c 100644 --- a/Modules/UseJava.cmake +++ b/Modules/UseJava.cmake @@ -192,7 +192,7 @@ #============================================================================= # Copyright 2013 OpenGamma Ltd. <graham@opengamma.com> # Copyright 2010-2011 Andreas schneider <asn@redhat.com> -# Copyright 2010 Ben Boeckel <ben.boeckel@kitware.com> +# Copyright 2010-2013 Kitware, Inc. # # Distributed under the OSI-approved BSD License (the "License"); # see accompanying file Copyright.txt for details. |