Merge branch 'policy-CMP0017' into resolve/python-versions/policy-CMP0017
Conflicts: Modules/FindPythonInterp.cmake
This commit is contained in:
commit
784d5ce0f8
|
@ -35,7 +35,7 @@ find_library(ALSA_LIBRARY NAMES asound
|
|||
|
||||
# handle the QUIETLY and REQUIRED arguments and set ALSA_FOUND to TRUE if
|
||||
# all listed variables are TRUE
|
||||
include("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
include(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(ALSA DEFAULT_MSG ALSA_LIBRARY ALSA_INCLUDE_DIR)
|
||||
|
||||
if(ALSA_FOUND)
|
||||
|
|
|
@ -26,7 +26,7 @@ FIND_LIBRARY(ASPELL_LIBRARIES NAMES aspell aspell-15 libaspell-15 libaspell)
|
|||
|
||||
# handle the QUIETLY and REQUIRED arguments and set ASPELL_FOUND to TRUE if
|
||||
# all listed variables are TRUE
|
||||
INCLUDE("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
INCLUDE(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(ASPELL DEFAULT_MSG ASPELL_LIBRARIES ASPELL_INCLUDE_DIR)
|
||||
|
||||
MARK_AS_ADVANCED(ASPELL_INCLUDE_DIR ASPELL_LIBRARIES)
|
||||
|
|
|
@ -37,7 +37,7 @@ ENDIF (UNIX)
|
|||
|
||||
# handle the QUIETLY and REQUIRED arguments and set AVIFILE_FOUND to TRUE if
|
||||
# all listed variables are TRUE
|
||||
INCLUDE("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
INCLUDE(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(AVIFile DEFAULT_MSG AVIFILE_INCLUDE_DIR AVIFILE_AVIPLAY_LIBRARY)
|
||||
|
||||
IF (AVIFILE_FOUND)
|
||||
|
|
|
@ -158,7 +158,7 @@ IF(BISON_EXECUTABLE)
|
|||
|
||||
ENDIF(BISON_EXECUTABLE)
|
||||
|
||||
INCLUDE("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
INCLUDE(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(BISON REQUIRED_VARS BISON_EXECUTABLE
|
||||
VERSION_VAR BISON_VERSION)
|
||||
|
||||
|
|
|
@ -26,7 +26,7 @@ FIND_LIBRARY(BZIP2_LIBRARIES NAMES bz2 bzip2 )
|
|||
|
||||
# handle the QUIETLY and REQUIRED arguments and set BZip2_FOUND to TRUE if
|
||||
# all listed variables are TRUE
|
||||
INCLUDE("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
INCLUDE(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(BZip2 DEFAULT_MSG BZIP2_LIBRARIES BZIP2_INCLUDE_DIR)
|
||||
|
||||
IF (BZIP2_FOUND)
|
||||
|
|
|
@ -70,7 +70,7 @@ _FIND_BULLET_LIBRARY(BULLET_SOFTBODY_LIBRARY_DEBUG BulletSoftBody_d)
|
|||
|
||||
# handle the QUIETLY and REQUIRED arguments and set BULLET_FOUND to TRUE if
|
||||
# all listed variables are TRUE
|
||||
include("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
include(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(Bullet DEFAULT_MSG
|
||||
BULLET_DYNAMICS_LIBRARY BULLET_COLLISION_LIBRARY BULLET_MATH_LIBRARY
|
||||
BULLET_SOFTBODY_LIBRARY BULLET_INCLUDE_DIR)
|
||||
|
|
|
@ -684,7 +684,7 @@ set(CUDA_TOOLKIT_ROOT_DIR_INTERNAL "${CUDA_TOOLKIT_ROOT_DIR}" CACHE INTERNAL
|
|||
set(CUDA_SDK_ROOT_DIR_INTERNAL "${CUDA_SDK_ROOT_DIR}" CACHE INTERNAL
|
||||
"This is the value of the last time CUDA_SDK_ROOT_DIR was set successfully." FORCE)
|
||||
|
||||
include("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
include(FindPackageHandleStandardArgs)
|
||||
find_package_handle_standard_args(CUDA
|
||||
REQUIRED_VARS
|
||||
CUDA_TOOLKIT_ROOT_DIR
|
||||
|
|
|
@ -34,7 +34,7 @@ MARK_AS_ADVANCED(CURL_LIBRARY)
|
|||
|
||||
# handle the QUIETLY and REQUIRED arguments and set CURL_FOUND to TRUE if
|
||||
# all listed variables are TRUE
|
||||
INCLUDE("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
INCLUDE(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(CURL DEFAULT_MSG CURL_LIBRARY CURL_INCLUDE_DIR)
|
||||
|
||||
IF(CURL_FOUND)
|
||||
|
|
|
@ -65,5 +65,5 @@ mark_as_advanced(CVS_EXECUTABLE)
|
|||
# Handle the QUIETLY and REQUIRED arguments and set CVS_FOUND to TRUE if
|
||||
# all listed variables are TRUE
|
||||
|
||||
include("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
include(FindPackageHandleStandardArgs)
|
||||
find_package_handle_standard_args(CVS DEFAULT_MSG CVS_EXECUTABLE)
|
||||
|
|
|
@ -76,7 +76,7 @@ ENDIF (WIN32)
|
|||
|
||||
# handle the QUIETLY and REQUIRED arguments and set COIN3D_FOUND to TRUE if
|
||||
# all listed variables are TRUE
|
||||
INCLUDE("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
INCLUDE(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(Coin3D DEFAULT_MSG COIN3D_LIBRARIES COIN3D_INCLUDE_DIRS)
|
||||
|
||||
MARK_AS_ADVANCED(COIN3D_INCLUDE_DIRS COIN3D_LIBRARIES )
|
||||
|
|
|
@ -155,7 +155,7 @@ SET(CURSES_INCLUDE_DIR ${CURSES_INCLUDE_PATH})
|
|||
|
||||
# handle the QUIETLY and REQUIRED arguments and set CURSES_FOUND to TRUE if
|
||||
# all listed variables are TRUE
|
||||
INCLUDE("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
INCLUDE(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(Curses DEFAULT_MSG
|
||||
CURSES_LIBRARY CURSES_INCLUDE_PATH)
|
||||
|
||||
|
|
|
@ -165,7 +165,7 @@ find_program(CXXTEST_PERL_TESTGEN_EXECUTABLE cxxtestgen.pl
|
|||
PATHS ${CXXTEST_INCLUDE_DIR})
|
||||
|
||||
if(PYTHONINTERP_FOUND OR PERL_FOUND)
|
||||
include("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
include(FindPackageHandleStandardArgs)
|
||||
|
||||
if(PYTHONINTERP_FOUND AND (CXXTEST_USE_PYTHON OR NOT PERL_FOUND))
|
||||
set(CXXTEST_TESTGEN_EXECUTABLE ${CXXTEST_PYTHON_TESTGEN_EXECUTABLE})
|
||||
|
|
|
@ -132,7 +132,7 @@ if(DCMTK_ofstd_INCLUDE_DIR)
|
|||
mark_as_advanced(DCMTK_dcmtk_INCLUDE_DIR)
|
||||
endif()
|
||||
|
||||
include("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
include(FindPackageHandleStandardArgs)
|
||||
find_package_handle_standard_args(DCMTK DEFAULT_MSG
|
||||
DCMTK_config_INCLUDE_DIR
|
||||
DCMTK_ofstd_INCLUDE_DIR
|
||||
|
|
|
@ -30,7 +30,7 @@ FIND_PATH(DART_ROOT README.INSTALL
|
|||
|
||||
# handle the QUIETLY and REQUIRED arguments and set DART_FOUND to TRUE if
|
||||
# all listed variables are TRUE
|
||||
INCLUDE("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
INCLUDE(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(Dart DEFAULT_MSG DART_ROOT)
|
||||
|
||||
MARK_AS_ADVANCED(DART_ROOT)
|
||||
|
|
|
@ -25,7 +25,7 @@
|
|||
# TODO: Add version support.
|
||||
# Tested under Linux and Windows (MSVC)
|
||||
|
||||
INCLUDE("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
INCLUDE(FindPackageHandleStandardArgs)
|
||||
|
||||
FIND_PATH(IL_INCLUDE_DIR il.h
|
||||
PATH_SUFFIXES include IL
|
||||
|
|
|
@ -76,7 +76,7 @@ FIND_PROGRAM(DOXYGEN_EXECUTABLE
|
|||
DOC "Doxygen documentation generation tool (http://www.doxygen.org)"
|
||||
)
|
||||
|
||||
include("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
include(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(Doxygen DEFAULT_MSG DOXYGEN_EXECUTABLE)
|
||||
|
||||
#
|
||||
|
|
|
@ -26,7 +26,7 @@ FIND_LIBRARY(EXPAT_LIBRARY NAMES expat libexpat)
|
|||
|
||||
# handle the QUIETLY and REQUIRED arguments and set EXPAT_FOUND to TRUE if
|
||||
# all listed variables are TRUE
|
||||
INCLUDE("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
INCLUDE(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(EXPAT DEFAULT_MSG EXPAT_LIBRARY EXPAT_INCLUDE_DIR)
|
||||
|
||||
# Copy the results to the output variables.
|
||||
|
|
|
@ -143,7 +143,7 @@ IF(FLEX_EXECUTABLE)
|
|||
|
||||
ENDIF(FLEX_EXECUTABLE)
|
||||
|
||||
INCLUDE("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
INCLUDE(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(FLEX REQUIRED_VARS FLEX_EXECUTABLE
|
||||
VERSION_VAR FLEX_VERSION)
|
||||
|
||||
|
|
|
@ -292,7 +292,7 @@ ENDIF(NOT FLTK_DIR)
|
|||
ENDIF()
|
||||
LIST(APPEND FLTK_LIBRARIES ${FLTK_BASE_LIBRARY})
|
||||
|
||||
INCLUDE("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
INCLUDE(FindPackageHandleStandardArgs)
|
||||
IF(FLTK_SKIP_FLUID)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(FLTK DEFAULT_MSG FLTK_LIBRARIES FLTK_INCLUDE_DIR)
|
||||
ELSE()
|
||||
|
|
|
@ -88,7 +88,7 @@ SET(FREETYPE_LIBRARIES "${FREETYPE_LIBRARY}")
|
|||
|
||||
# handle the QUIETLY and REQUIRED arguments and set FREETYPE_FOUND to TRUE if
|
||||
# all listed variables are TRUE
|
||||
INCLUDE("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
INCLUDE(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(Freetype DEFAULT_MSG FREETYPE_LIBRARY FREETYPE_INCLUDE_DIRS)
|
||||
|
||||
|
||||
|
|
|
@ -100,7 +100,7 @@ FIND_LIBRARY(GDAL_LIBRARY
|
|||
/usr/freeware
|
||||
)
|
||||
|
||||
include("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
include(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(GDAL DEFAULT_MSG GDAL_LIBRARY GDAL_INCLUDE_DIR)
|
||||
|
||||
set(GDAL_LIBRARIES ${GDAL_LIBRARY})
|
||||
|
|
|
@ -60,7 +60,7 @@ SET(GIF_LIBRARIES ${GIF_LIBRARY})
|
|||
|
||||
# handle the QUIETLY and REQUIRED arguments and set GIF_FOUND to TRUE if
|
||||
# all listed variables are TRUE
|
||||
INCLUDE("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
INCLUDE(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(GIF DEFAULT_MSG GIF_LIBRARY GIF_INCLUDE_DIR)
|
||||
|
||||
MARK_AS_ADVANCED(GIF_INCLUDE_DIR GIF_LIBRARY)
|
||||
|
|
|
@ -521,7 +521,7 @@ endif()
|
|||
|
||||
set(_GTK2_did_we_find_everything true) # This gets set to GTK2_FOUND
|
||||
|
||||
include("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
include(FindPackageHandleStandardArgs)
|
||||
|
||||
foreach(_GTK2_component ${GTK2_FIND_COMPONENTS})
|
||||
string(TOUPPER ${_GTK2_component} _COMPONENT_UPPER)
|
||||
|
|
|
@ -146,7 +146,7 @@ else()
|
|||
_gtest_find_library(GTEST_MAIN_LIBRARY_DEBUG gtest_maind)
|
||||
endif()
|
||||
|
||||
include("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
include(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(GTest DEFAULT_MSG GTEST_LIBRARY GTEST_INCLUDE_DIR GTEST_MAIN_LIBRARY)
|
||||
|
||||
if(GTEST_FOUND)
|
||||
|
|
|
@ -42,5 +42,5 @@ mark_as_advanced(GIT_EXECUTABLE)
|
|||
# Handle the QUIETLY and REQUIRED arguments and set GIT_FOUND to TRUE if
|
||||
# all listed variables are TRUE
|
||||
|
||||
include("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
include(FindPackageHandleStandardArgs)
|
||||
find_package_handle_standard_args(Git DEFAULT_MSG GIT_EXECUTABLE)
|
||||
|
|
|
@ -56,7 +56,7 @@ MARK_AS_ADVANCED(GNUTLS_INCLUDE_DIR GNUTLS_LIBRARY)
|
|||
|
||||
# handle the QUIETLY and REQUIRED arguments and set GNUTLS_FOUND to TRUE if
|
||||
# all listed variables are TRUE
|
||||
INCLUDE("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
INCLUDE(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(GnuTLS DEFAULT_MSG GNUTLS_LIBRARY GNUTLS_INCLUDE_DIR)
|
||||
|
||||
IF(GNUTLS_FOUND)
|
||||
|
|
|
@ -34,7 +34,7 @@ SET(GNUPLOT ${GNUPLOT_EXECUTABLE})
|
|||
|
||||
# handle the QUIETLY and REQUIRED arguments and set GNUPLOT_FOUND to TRUE if
|
||||
# all listed variables are TRUE
|
||||
INCLUDE("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
INCLUDE(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(Gnuplot DEFAULT_MSG GNUPLOT_EXECUTABLE)
|
||||
|
||||
MARK_AS_ADVANCED( GNUPLOT_EXECUTABLE )
|
||||
|
|
|
@ -57,7 +57,7 @@
|
|||
# This module is maintained by Will Dicharry <wdicharry@stellarscience.com>.
|
||||
|
||||
include(SelectLibraryConfigurations)
|
||||
include("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
include(FindPackageHandleStandardArgs)
|
||||
|
||||
# List of the valid HDF5 components
|
||||
set( HDF5_VALID_COMPONENTS
|
||||
|
|
|
@ -36,7 +36,7 @@ ENDIF()
|
|||
|
||||
# handle the QUIETLY and REQUIRED arguments and set HSPELL_FOUND to TRUE if
|
||||
# all listed variables are TRUE
|
||||
INCLUDE("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
INCLUDE(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(HSPELL DEFAULT_MSG HSPELL_LIBRARIES HSPELL_INCLUDE_DIR)
|
||||
|
||||
MARK_AS_ADVANCED(HSPELL_INCLUDE_DIR HSPELL_LIBRARIES)
|
||||
|
|
|
@ -171,7 +171,7 @@ SET(ImageMagick_LIBRARIES ${ImageMagick_LIBRARIES})
|
|||
#---------------------------------------------------------------------
|
||||
# Standard Package Output
|
||||
#---------------------------------------------------------------------
|
||||
INCLUDE("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
INCLUDE(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(
|
||||
ImageMagick DEFAULT_MSG ImageMagick_FOUND
|
||||
)
|
||||
|
|
|
@ -232,7 +232,7 @@ FIND_PATH(JAVA_AWT_INCLUDE_PATH jawt.h
|
|||
${JAVA_INCLUDE_PATH}
|
||||
)
|
||||
|
||||
INCLUDE("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
INCLUDE(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(JNI DEFAULT_MSG JAVA_AWT_LIBRARY JAVA_JVM_LIBRARY
|
||||
JAVA_INCLUDE_PATH JAVA_INCLUDE_PATH2 JAVA_AWT_INCLUDE_PATH)
|
||||
|
||||
|
|
|
@ -27,7 +27,7 @@ FIND_LIBRARY(JPEG_LIBRARY NAMES ${JPEG_NAMES} )
|
|||
|
||||
# handle the QUIETLY and REQUIRED arguments and set JPEG_FOUND to TRUE if
|
||||
# all listed variables are TRUE
|
||||
INCLUDE("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
INCLUDE(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(JPEG DEFAULT_MSG JPEG_LIBRARY JPEG_INCLUDE_DIR)
|
||||
|
||||
IF(JPEG_FOUND)
|
||||
|
|
|
@ -27,7 +27,7 @@ FIND_LIBRARY(JASPER_LIBRARY NAMES jasper libjasper)
|
|||
|
||||
# handle the QUIETLY and REQUIRED arguments and set JASPER_FOUND to TRUE if
|
||||
# all listed variables are TRUE
|
||||
INCLUDE("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
INCLUDE(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(Jasper DEFAULT_MSG JASPER_LIBRARY JASPER_INCLUDE_DIR JPEG_LIBRARIES)
|
||||
|
||||
IF (JASPER_FOUND)
|
||||
|
|
|
@ -150,7 +150,7 @@ FIND_PROGRAM(Java_JAVAC_EXECUTABLE
|
|||
PATHS ${_JAVA_PATHS}
|
||||
)
|
||||
|
||||
include("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
include(FindPackageHandleStandardArgs)
|
||||
if(Java_FIND_COMPONENTS)
|
||||
foreach(component ${Java_FIND_COMPONENTS})
|
||||
# User just want to execute some Java byte-compiled
|
||||
|
|
|
@ -50,7 +50,7 @@ endif()
|
|||
|
||||
# Handle the QUIETLY and REQUIRED arguments and set LIBARCHIVE_FOUND
|
||||
# to TRUE if all listed variables are TRUE.
|
||||
include("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
include(FindPackageHandleStandardArgs)
|
||||
find_package_handle_standard_args(LibArchive DEFAULT_MSG
|
||||
LibArchive_LIBRARY LibArchive_INCLUDE_DIR
|
||||
)
|
||||
|
|
|
@ -46,7 +46,7 @@ SET(XMLLINT_EXECUTABLE "${LIBXML2_XMLLINT_EXECUTABLE}")
|
|||
|
||||
# handle the QUIETLY and REQUIRED arguments and set LIBXML2_FOUND to TRUE if
|
||||
# all listed variables are TRUE
|
||||
INCLUDE("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
INCLUDE(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(LibXml2 DEFAULT_MSG LIBXML2_LIBRARIES LIBXML2_INCLUDE_DIR)
|
||||
|
||||
MARK_AS_ADVANCED(LIBXML2_INCLUDE_DIR LIBXML2_LIBRARIES LIBXML2_XMLLINT_EXECUTABLE)
|
||||
|
|
|
@ -40,7 +40,7 @@ FIND_LIBRARY(LIBXSLT_LIBRARIES NAMES xslt libxslt
|
|||
|
||||
# handle the QUIETLY and REQUIRED arguments and set LIBXML2_FOUND to TRUE if
|
||||
# all listed variables are TRUE
|
||||
INCLUDE("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
INCLUDE(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(LibXslt DEFAULT_MSG LIBXSLT_LIBRARIES LIBXSLT_INCLUDE_DIR)
|
||||
|
||||
MARK_AS_ADVANCED(LIBXSLT_INCLUDE_DIR LIBXSLT_LIBRARIES)
|
||||
|
|
|
@ -87,7 +87,7 @@ ELSE(${LUA_LIBRARY_lua} MATCHES "framework")
|
|||
ENDIF(${LUA_LIBRARY_lua} MATCHES "framework")
|
||||
|
||||
|
||||
INCLUDE("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
INCLUDE(FindPackageHandleStandardArgs)
|
||||
# handle the QUIETLY and REQUIRED arguments and set LUA_FOUND to TRUE if
|
||||
# all listed variables are TRUE
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(Lua50 DEFAULT_MSG LUA_LIBRARIES LUA_INCLUDE_DIR)
|
||||
|
|
|
@ -66,7 +66,7 @@ IF(LUA_LIBRARY)
|
|||
ENDIF(UNIX AND NOT APPLE)
|
||||
ENDIF(LUA_LIBRARY)
|
||||
|
||||
INCLUDE("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
INCLUDE(FindPackageHandleStandardArgs)
|
||||
# handle the QUIETLY and REQUIRED arguments and set LUA_FOUND to TRUE if
|
||||
# all listed variables are TRUE
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(Lua51 DEFAULT_MSG LUA_LIBRARIES LUA_INCLUDE_DIR)
|
||||
|
|
|
@ -34,7 +34,7 @@ FIND_LIBRARY( MPEG_vo_LIBRARY vo
|
|||
|
||||
# handle the QUIETLY and REQUIRED arguments and set MPEG2_FOUND to TRUE if
|
||||
# all listed variables are TRUE
|
||||
INCLUDE("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
INCLUDE(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(MPEG DEFAULT_MSG MPEG_INCLUDE_DIR MPEG_mpeg2_LIBRARY MPEG_vo_LIBRARY)
|
||||
|
||||
IF(MPEG_FOUND)
|
||||
|
|
|
@ -36,7 +36,7 @@ FIND_LIBRARY( MPEG2_vo_LIBRARY vo
|
|||
|
||||
# handle the QUIETLY and REQUIRED arguments and set MPEG2_FOUND to TRUE if
|
||||
# all listed variables are TRUE
|
||||
INCLUDE("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
INCLUDE(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(MPEG2 DEFAULT_MSG MPEG2_mpeg2_LIBRARY MPEG2_INCLUDE_DIR)
|
||||
|
||||
IF(MPEG2_FOUND)
|
||||
|
|
|
@ -346,7 +346,7 @@ else (MPI_INCLUDE_PATH AND MPI_LIBRARY)
|
|||
set(MPI_FOUND FALSE)
|
||||
endif (MPI_INCLUDE_PATH AND MPI_LIBRARY)
|
||||
|
||||
include("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
include(FindPackageHandleStandardArgs)
|
||||
# handle the QUIETLY and REQUIRED arguments
|
||||
find_package_handle_standard_args(MPI DEFAULT_MSG MPI_LIBRARY MPI_INCLUDE_PATH)
|
||||
|
||||
|
|
|
@ -34,7 +34,7 @@ ENDIF(UNIX)
|
|||
|
||||
# handle the QUIETLY and REQUIRED arguments and set MOTIF_FOUND to TRUE if
|
||||
# all listed variables are TRUE
|
||||
INCLUDE("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
INCLUDE(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(Motif DEFAULT_MSG MOTIF_LIBRARIES MOTIF_INCLUDE_DIR)
|
||||
|
||||
|
||||
|
|
|
@ -97,7 +97,7 @@ FIND_LIBRARY(OPENAL_LIBRARY
|
|||
|
||||
# handle the QUIETLY and REQUIRED arguments and set OPENAL_FOUND to TRUE if
|
||||
# all listed variables are TRUE
|
||||
INCLUDE("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
INCLUDE(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(OpenAL DEFAULT_MSG OPENAL_LIBRARY OPENAL_INCLUDE_DIR)
|
||||
|
||||
MARK_AS_ADVANCED(OPENAL_LIBRARY OPENAL_INCLUDE_DIR)
|
||||
|
|
|
@ -26,7 +26,7 @@
|
|||
|
||||
include(CheckCSourceCompiles)
|
||||
include(CheckCXXSourceCompiles)
|
||||
include("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
include(FindPackageHandleStandardArgs)
|
||||
|
||||
set(OpenMP_C_FLAG_CANDIDATES
|
||||
#Gnu
|
||||
|
|
|
@ -113,7 +113,7 @@ ELSE(WIN32 AND NOT CYGWIN)
|
|||
|
||||
ENDIF(WIN32 AND NOT CYGWIN)
|
||||
|
||||
include("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
include(FindPackageHandleStandardArgs)
|
||||
find_package_handle_standard_args(OpenSSL DEFAULT_MSG
|
||||
OPENSSL_LIBRARIES
|
||||
OPENSSL_INCLUDE_DIR
|
||||
|
|
|
@ -231,7 +231,7 @@ else()
|
|||
endif()
|
||||
endif()
|
||||
|
||||
include("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
include(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(OpenSceneGraph DEFAULT_MSG OPENSCENEGRAPH_LIBRARIES OPENSCENEGRAPH_INCLUDE_DIR)
|
||||
endif()
|
||||
|
||||
|
|
|
@ -118,6 +118,6 @@ else()
|
|||
set(OPENTHREADS_LIBRARIES ${OPENTHREADS_LIBRARY})
|
||||
endif()
|
||||
|
||||
include("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
include(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(OpenThreads DEFAULT_MSG
|
||||
OPENTHREADS_LIBRARY OPENTHREADS_INCLUDE_DIR)
|
||||
|
|
|
@ -81,5 +81,5 @@ IF(APPLE)
|
|||
ENDFOREACH(symbol)
|
||||
ENDIF(APPLE)
|
||||
|
||||
INCLUDE("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
INCLUDE(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(PHP4 DEFAULT_MSG PHP4_EXECUTABLE PHP4_INCLUDE_PATH)
|
||||
|
|
|
@ -55,7 +55,7 @@ endif(ZLIB_FOUND)
|
|||
|
||||
# handle the QUIETLY and REQUIRED arguments and set PNG_FOUND to TRUE if
|
||||
# all listed variables are TRUE
|
||||
include("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
include(FindPackageHandleStandardArgs)
|
||||
find_package_handle_standard_args(PNG DEFAULT_MSG PNG_LIBRARY PNG_PNG_INCLUDE_DIR)
|
||||
|
||||
mark_as_advanced(PNG_PNG_INCLUDE_DIR PNG_LIBRARY )
|
||||
|
|
|
@ -44,7 +44,7 @@ SET(PERL ${PERL_EXECUTABLE})
|
|||
|
||||
# handle the QUIETLY and REQUIRED arguments and set PERL_FOUND to TRUE if
|
||||
# all listed variables are TRUE
|
||||
INCLUDE("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
INCLUDE(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(Perl DEFAULT_MSG PERL_EXECUTABLE)
|
||||
|
||||
MARK_AS_ADVANCED(PERL_EXECUTABLE)
|
||||
|
|
|
@ -258,7 +258,7 @@ endif (PERL_EXECUTABLE)
|
|||
|
||||
# handle the QUIETLY and REQUIRED arguments and set PERLLIBS_FOUND to TRUE if
|
||||
# all listed variables are TRUE
|
||||
include("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
include(FindPackageHandleStandardArgs)
|
||||
find_package_handle_standard_args(PerlLibs REQUIRED_VARS PERL_LIBRARY PERL_INCLUDE_PATH
|
||||
VERSION_VAR PERL_VERSION)
|
||||
|
||||
|
|
|
@ -56,6 +56,6 @@ FIND_LIBRARY(PHYSFS_LIBRARY
|
|||
|
||||
# handle the QUIETLY and REQUIRED arguments and set PHYSFS_FOUND to TRUE if
|
||||
# all listed variables are TRUE
|
||||
INCLUDE("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
INCLUDE(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(PhysFS DEFAULT_MSG PHYSFS_LIBRARY PHYSFS_INCLUDE_DIR)
|
||||
|
||||
|
|
|
@ -77,6 +77,6 @@ FIND_LIBRARY(PRODUCER_LIBRARY
|
|||
/opt
|
||||
)
|
||||
|
||||
include("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
include(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(Producer DEFAULT_MSG
|
||||
PRODUCER_LIBRARY PRODUCER_INCLUDE_DIR)
|
||||
|
|
|
@ -111,7 +111,7 @@ if(WIN32)
|
|||
set(CMAKE_FIND_LIBRARY_PREFIXES "${PROTOBUF_ORIG_FIND_LIBRARY_PREFIXES}")
|
||||
endif()
|
||||
|
||||
include("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
include(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(PROTOBUF DEFAULT_MSG
|
||||
PROTOBUF_LIBRARY PROTOBUF_INCLUDE_DIR)
|
||||
|
||||
|
|
|
@ -45,7 +45,7 @@ endif()
|
|||
|
||||
# handle the QUIETLY and REQUIRED arguments and set PYTHONINTERP_FOUND to TRUE if
|
||||
# all listed variables are TRUE
|
||||
include("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
include(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(PythonInterp DEFAULT_MSG PYTHON_EXECUTABLE)
|
||||
|
||||
mark_as_advanced(PYTHON_EXECUTABLE)
|
||||
|
|
|
@ -104,7 +104,7 @@ SET(PYTHON_LIBRARIES "${PYTHON_LIBRARY}")
|
|||
SET(PYTHON_DEBUG_LIBRARIES "${PYTHON_DEBUG_LIBRARY}")
|
||||
|
||||
|
||||
INCLUDE("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
INCLUDE(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(PythonLibs DEFAULT_MSG PYTHON_LIBRARIES PYTHON_INCLUDE_DIRS)
|
||||
|
||||
|
||||
|
|
|
@ -43,5 +43,5 @@ ENDIF(APPLE)
|
|||
|
||||
# handle the QUIETLY and REQUIRED arguments and set QUICKTIME_FOUND to TRUE if
|
||||
# all listed variables are TRUE
|
||||
INCLUDE("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
INCLUDE(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(QuickTime DEFAULT_MSG QUICKTIME_LIBRARY QUICKTIME_INCLUDE_DIR)
|
||||
|
|
|
@ -95,7 +95,7 @@ ENDIF (RTI_INCLUDE_DIR)
|
|||
# Set the modified system variables back to the original value.
|
||||
SET(CMAKE_FIND_LIBRARY_PREFIXES "${RTI_OLD_FIND_LIBRARY_PREFIXES}")
|
||||
|
||||
INCLUDE("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
INCLUDE(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(RTI DEFAULT_MSG
|
||||
RTI_LIBRARY RTI_INCLUDE_DIR)
|
||||
|
||||
|
|
|
@ -209,7 +209,7 @@ ENDIF(WIN32)
|
|||
|
||||
FIND_LIBRARY(RUBY_LIBRARY NAMES ${_RUBY_POSSIBLE_LIB_NAMES} HINTS ${RUBY_POSSIBLE_LIB_DIR} )
|
||||
|
||||
INCLUDE("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
INCLUDE(FindPackageHandleStandardArgs)
|
||||
SET(_RUBY_REQUIRED_VARS RUBY_EXECUTABLE RUBY_INCLUDE_DIR RUBY_LIBRARY)
|
||||
IF(_RUBY_VERSION_SHORT_NODOT GREATER 18)
|
||||
LIST(APPEND _RUBY_REQUIRED_VARS RUBY_CONFIG_INCLUDE_DIR)
|
||||
|
|
|
@ -62,6 +62,6 @@ IF(SWIG_EXECUTABLE)
|
|||
ENDIF(SWIG_swiglib_result)
|
||||
ENDIF(SWIG_EXECUTABLE)
|
||||
|
||||
INCLUDE("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
INCLUDE(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(SWIG REQUIRED_VARS SWIG_EXECUTABLE SWIG_DIR
|
||||
VERSION_VAR SWIG_VERSION )
|
||||
|
|
|
@ -122,7 +122,7 @@ IF(Subversion_SVN_EXECUTABLE)
|
|||
|
||||
ENDIF(Subversion_SVN_EXECUTABLE)
|
||||
|
||||
INCLUDE("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
INCLUDE(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(Subversion REQUIRED_VARS Subversion_SVN_EXECUTABLE
|
||||
VERSION_VAR Subversion_VERSION_SVN )
|
||||
|
||||
|
|
|
@ -197,7 +197,7 @@ FIND_PATH(TK_INCLUDE_PATH
|
|||
|
||||
# handle the QUIETLY and REQUIRED arguments and set TCL_FOUND to TRUE if
|
||||
# all listed variables are TRUE
|
||||
INCLUDE("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
INCLUDE(FindPackageHandleStandardArgs)
|
||||
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(TCL DEFAULT_MSG TCL_LIBRARY TCL_INCLUDE_PATH)
|
||||
SET(TCLTK_FIND_REQUIRED ${TCL_FIND_REQUIRED})
|
||||
|
|
|
@ -27,7 +27,7 @@ FIND_LIBRARY(TIFF_LIBRARY NAMES ${TIFF_NAMES} )
|
|||
|
||||
# handle the QUIETLY and REQUIRED arguments and set TIFF_FOUND to TRUE if
|
||||
# all listed variables are TRUE
|
||||
INCLUDE("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
INCLUDE(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(TIFF DEFAULT_MSG TIFF_LIBRARY TIFF_INCLUDE_DIR)
|
||||
|
||||
IF(TIFF_FOUND)
|
||||
|
|
|
@ -84,7 +84,7 @@ FIND_PROGRAM(TCL_TCLSH
|
|||
|
||||
# handle the QUIETLY and REQUIRED arguments and set TIFF_FOUND to TRUE if
|
||||
# all listed variables are TRUE
|
||||
INCLUDE("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
INCLUDE(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(Tclsh DEFAULT_MSG TCL_TCLSH)
|
||||
|
||||
MARK_AS_ADVANCED(TCL_TCLSH)
|
||||
|
|
|
@ -153,5 +153,5 @@ IF(CMAKE_USE_PTHREADS_INIT)
|
|||
ENDIF()
|
||||
ENDIF(CMAKE_USE_PTHREADS_INIT)
|
||||
|
||||
INCLUDE("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
INCLUDE(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(Threads DEFAULT_MSG Threads_FOUND)
|
||||
|
|
|
@ -26,7 +26,7 @@ FIND_PROGRAM(WGET_EXECUTABLE
|
|||
|
||||
# handle the QUIETLY and REQUIRED arguments and set WGET_FOUND to TRUE if
|
||||
# all listed variables are TRUE
|
||||
INCLUDE("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
INCLUDE(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(Wget DEFAULT_MSG WGET_EXECUTABLE)
|
||||
|
||||
MARK_AS_ADVANCED( WGET_EXECUTABLE )
|
||||
|
|
|
@ -66,7 +66,7 @@ ENDIF()
|
|||
|
||||
# handle the QUIETLY and REQUIRED arguments and set ZLIB_FOUND to TRUE if
|
||||
# all listed variables are TRUE
|
||||
INCLUDE("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
INCLUDE(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(ZLIB REQUIRED_VARS ZLIB_INCLUDE_DIR ZLIB_LIBRARY
|
||||
VERSION_VAR ZLIB_VERSION_STRING)
|
||||
|
||||
|
|
|
@ -50,5 +50,5 @@ include(Findosg_functions)
|
|||
OSG_FIND_PATH (OSG osg/PositionAttitudeTransform)
|
||||
OSG_FIND_LIBRARY(OSG osg)
|
||||
|
||||
include("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
include(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(osg DEFAULT_MSG OSG_LIBRARY OSG_INCLUDE_DIR)
|
||||
|
|
|
@ -46,6 +46,6 @@ include(Findosg_functions)
|
|||
OSG_FIND_PATH (OSGANIMATION osgAnimation/Animation)
|
||||
OSG_FIND_LIBRARY(OSGANIMATION osgAnimation)
|
||||
|
||||
include("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
include(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(osgAnimation DEFAULT_MSG
|
||||
OSGANIMATION_LIBRARY OSGANIMATION_INCLUDE_DIR)
|
||||
|
|
|
@ -46,6 +46,6 @@ include(Findosg_functions)
|
|||
OSG_FIND_PATH (OSGDB osgDB/DatabasePager)
|
||||
OSG_FIND_LIBRARY(OSGDB osgDB)
|
||||
|
||||
include("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
include(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(osgDB DEFAULT_MSG
|
||||
OSGDB_LIBRARY OSGDB_INCLUDE_DIR)
|
||||
|
|
|
@ -46,6 +46,6 @@ include(Findosg_functions)
|
|||
OSG_FIND_PATH (OSGFX osgFX/BumpMapping)
|
||||
OSG_FIND_LIBRARY(OSGFX osgFX)
|
||||
|
||||
include("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
include(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(osgFX DEFAULT_MSG
|
||||
OSGFX_LIBRARY OSGFX_INCLUDE_DIR)
|
||||
|
|
|
@ -46,6 +46,6 @@ include(Findosg_functions)
|
|||
OSG_FIND_PATH (OSGGA osgGA/FlightManipulator)
|
||||
OSG_FIND_LIBRARY(OSGGA osgGA)
|
||||
|
||||
include("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
include(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(osgGA DEFAULT_MSG
|
||||
OSGGA_LIBRARY OSGGA_INCLUDE_DIR)
|
||||
|
|
|
@ -46,6 +46,6 @@ include(Findosg_functions)
|
|||
OSG_FIND_PATH (OSGINTROSPECTION osgIntrospection/Reflection)
|
||||
OSG_FIND_LIBRARY(OSGINTROSPECTION osgIntrospection)
|
||||
|
||||
include("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
include(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(osgIntrospection DEFAULT_MSG
|
||||
OSGINTROSPECTION_LIBRARY OSGINTROSPECTION_INCLUDE_DIR)
|
||||
|
|
|
@ -46,6 +46,6 @@ include(Findosg_functions)
|
|||
OSG_FIND_PATH (OSGMANIPULATOR osgManipulator/TrackballDragger)
|
||||
OSG_FIND_LIBRARY(OSGMANIPULATOR osgManipulator)
|
||||
|
||||
include("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
include(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(osgManipulator DEFAULT_MSG
|
||||
OSGMANIPULATOR_LIBRARY OSGMANIPULATOR_INCLUDE_DIR)
|
||||
|
|
|
@ -46,6 +46,6 @@ include(Findosg_functions)
|
|||
OSG_FIND_PATH (OSGPARTICLE osgParticle/FireEffect)
|
||||
OSG_FIND_LIBRARY(OSGPARTICLE osgParticle)
|
||||
|
||||
include("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
include(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(osgParticle DEFAULT_MSG
|
||||
OSGPARTICLE_LIBRARY OSGPARTICLE_INCLUDE_DIR)
|
||||
|
|
|
@ -46,6 +46,6 @@ include(Findosg_functions)
|
|||
OSG_FIND_PATH (OSGPRODUCER osgProducer/OsgSceneHandler)
|
||||
OSG_FIND_LIBRARY(OSGPRODUCER osgProducer)
|
||||
|
||||
include("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
include(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(osgProducer DEFAULT_MSG
|
||||
OSGPRODUCER_LIBRARY OSGPRODUCER_INCLUDE_DIR)
|
||||
|
|
|
@ -46,6 +46,6 @@ include(Findosg_functions)
|
|||
OSG_FIND_PATH (OSGSHADOW osgShadow/ShadowTexture)
|
||||
OSG_FIND_LIBRARY(OSGSHADOW osgShadow)
|
||||
|
||||
include("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
include(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(osgShadow DEFAULT_MSG
|
||||
OSGSHADOW_LIBRARY OSGSHADOW_INCLUDE_DIR)
|
||||
|
|
|
@ -46,6 +46,6 @@ include(Findosg_functions)
|
|||
OSG_FIND_PATH (OSGSIM osgSim/ImpostorSprite)
|
||||
OSG_FIND_LIBRARY(OSGSIM osgSim)
|
||||
|
||||
include("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
include(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(osgSim DEFAULT_MSG
|
||||
OSGSIM_LIBRARY OSGSIM_INCLUDE_DIR)
|
||||
|
|
|
@ -46,6 +46,6 @@ include(Findosg_functions)
|
|||
OSG_FIND_PATH (OSGTERRAIN osgTerrain/Terrain)
|
||||
OSG_FIND_LIBRARY(OSGTERRAIN osgTerrain)
|
||||
|
||||
include("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
include(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(osgTerrain DEFAULT_MSG
|
||||
OSGTERRAIN_LIBRARY OSGTERRAIN_INCLUDE_DIR)
|
||||
|
|
|
@ -46,6 +46,6 @@ include(Findosg_functions)
|
|||
OSG_FIND_PATH (OSGTEXT osgText/Text)
|
||||
OSG_FIND_LIBRARY(OSGTEXT osgText)
|
||||
|
||||
include("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
include(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(osgText DEFAULT_MSG
|
||||
OSGTEXT_LIBRARY OSGTEXT_INCLUDE_DIR)
|
||||
|
|
|
@ -46,6 +46,6 @@ include(Findosg_functions)
|
|||
OSG_FIND_PATH (OSGUTIL osgUtil/SceneView)
|
||||
OSG_FIND_LIBRARY(OSGUTIL osgUtil)
|
||||
|
||||
include("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
include(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(osgUtil DEFAULT_MSG
|
||||
OSGUTIL_LIBRARY OSGUTIL_INCLUDE_DIR)
|
||||
|
|
|
@ -46,6 +46,6 @@ include(Findosg_functions)
|
|||
OSG_FIND_PATH (OSGVIEWER osgViewer/Viewer)
|
||||
OSG_FIND_LIBRARY(OSGVIEWER osgViewer)
|
||||
|
||||
include("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
include(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(osgViewer DEFAULT_MSG
|
||||
OSGVIEWER_LIBRARY OSGVIEWER_INCLUDE_DIR)
|
||||
|
|
|
@ -46,6 +46,6 @@ include(Findosg_functions)
|
|||
OSG_FIND_PATH (OSGVOLUME osgVolume/Volume)
|
||||
OSG_FIND_LIBRARY(OSGVOLUME osgVolume)
|
||||
|
||||
include("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
include(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(osgVolume DEFAULT_MSG
|
||||
OSGVOLUME_LIBRARY OSGVOLUME_INCLUDE_DIR)
|
||||
|
|
|
@ -46,6 +46,6 @@ include(Findosg_functions)
|
|||
OSG_FIND_PATH (OSGWIDGET osgWidget/Widget)
|
||||
OSG_FIND_LIBRARY(OSGWIDGET osgWidget)
|
||||
|
||||
include("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
include(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(osgWidget DEFAULT_MSG
|
||||
OSGWIDGET_LIBRARY OSGWIDGET_INCLUDE_DIR)
|
||||
|
|
|
@ -827,7 +827,7 @@ DBG_MSG("wxWidgets_USE_FILE : ${wxWidgets_USE_FILE}")
|
|||
|
||||
#=====================================================================
|
||||
#=====================================================================
|
||||
INCLUDE("${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake")
|
||||
INCLUDE(FindPackageHandleStandardArgs)
|
||||
FIND_PACKAGE_HANDLE_STANDARD_ARGS(wxWidgets DEFAULT_MSG wxWidgets_FOUND)
|
||||
# Maintain consistency with all other variables.
|
||||
SET(wxWidgets_FOUND ${WXWIDGETS_FOUND})
|
||||
|
|
|
@ -85,7 +85,8 @@ public:
|
|||
"given version of CMake. "
|
||||
"All policies introduced in the specified version or earlier "
|
||||
"will be set to use NEW behavior. "
|
||||
"All policies introduced after the specified version will be unset. "
|
||||
"All policies introduced after the specified version will be unset "
|
||||
"(unless variable CMAKE_POLICY_DEFAULT_CMP<NNNN> sets a default). "
|
||||
"This effectively requests behavior preferred as of a given CMake "
|
||||
"version and tells newer CMake versions to warn about their new "
|
||||
"policies. "
|
||||
|
|
|
@ -464,6 +464,25 @@ void cmDocumentVariables::DefineVariables(cmake* cm)
|
|||
|
||||
// Variables defined by cmake, that change the behavior
|
||||
// of cmake
|
||||
|
||||
cm->DefineProperty
|
||||
("CMAKE_POLICY_DEFAULT_CMP<NNNN>", cmProperty::VARIABLE,
|
||||
"Default for CMake Policy CMP<NNNN> when it is otherwise left unset.",
|
||||
"Commands cmake_minimum_required(VERSION) and cmake_policy(VERSION) "
|
||||
"by default leave policies introduced after the given version unset. "
|
||||
"Set CMAKE_POLICY_DEFAULT_CMP<NNNN> to OLD or NEW to specify the "
|
||||
"default for policy CMP<NNNN>, where <NNNN> is the policy number."
|
||||
"\n"
|
||||
"This variable should not be set by a project in CMake code; "
|
||||
"use cmake_policy(SET) instead. "
|
||||
"Users running CMake may set this variable in the cache "
|
||||
"(e.g. -DCMAKE_POLICY_DEFAULT_CMP<NNNN>=<OLD|NEW>) "
|
||||
"to set a policy not otherwise set by the project. "
|
||||
"Set to OLD to quiet a policy warning while using old behavior "
|
||||
"or to NEW to try building the project with new behavior.",
|
||||
false,
|
||||
"Variables That Change Behavior");
|
||||
|
||||
cm->DefineProperty
|
||||
("CMAKE_FIND_LIBRARY_PREFIXES", cmProperty::VARIABLE,
|
||||
"Prefixes to prepend when looking for libraries.",
|
||||
|
|
|
@ -26,10 +26,10 @@ bool cmIncludeCommand
|
|||
bool noPolicyScope = false;
|
||||
std::string fname = args[0];
|
||||
std::string resultVarName;
|
||||
|
||||
|
||||
for (unsigned int i=1; i<args.size(); i++)
|
||||
{
|
||||
if (args[i] == "OPTIONAL")
|
||||
if (args[i] == "OPTIONAL")
|
||||
{
|
||||
if (optional)
|
||||
{
|
||||
|
@ -60,10 +60,10 @@ bool cmIncludeCommand
|
|||
{
|
||||
noPolicyScope = true;
|
||||
}
|
||||
else if(i > 1) // compat.: in previous cmake versions the second
|
||||
else if(i > 1) // compat.: in previous cmake versions the second
|
||||
// parameter was ignore if it wasn't "OPTIONAL"
|
||||
{
|
||||
std::string errorText = "called with invalid argument: ";
|
||||
std::string errorText = "called with invalid argument: ";
|
||||
errorText += args[i];
|
||||
this->SetError(errorText.c_str());
|
||||
return false;
|
||||
|
@ -82,15 +82,15 @@ bool cmIncludeCommand
|
|||
}
|
||||
}
|
||||
std::string fullFilePath;
|
||||
bool readit =
|
||||
this->Makefile->ReadListFile( this->Makefile->GetCurrentListFile(),
|
||||
bool readit =
|
||||
this->Makefile->ReadListFile( this->Makefile->GetCurrentListFile(),
|
||||
fname.c_str(), &fullFilePath,
|
||||
noPolicyScope);
|
||||
|
||||
|
||||
// add the location of the included file if a result variable was given
|
||||
if (resultVarName.size())
|
||||
{
|
||||
this->Makefile->AddDefinition(resultVarName.c_str(),
|
||||
this->Makefile->AddDefinition(resultVarName.c_str(),
|
||||
readit?fullFilePath.c_str():"NOTFOUND");
|
||||
}
|
||||
|
||||
|
|
|
@ -15,7 +15,7 @@
|
|||
#include "cmCommand.h"
|
||||
|
||||
/** \class cmIncludeCommand
|
||||
* \brief
|
||||
* \brief
|
||||
*
|
||||
* cmIncludeCommand defines a list of distant
|
||||
* files that can be "included" in the current list file.
|
||||
|
@ -28,7 +28,7 @@ public:
|
|||
/**
|
||||
* This is a virtual constructor for the command.
|
||||
*/
|
||||
virtual cmCommand* Clone()
|
||||
virtual cmCommand* Clone()
|
||||
{
|
||||
return new cmIncludeCommand;
|
||||
}
|
||||
|
@ -49,15 +49,15 @@ public:
|
|||
* The name of the command as specified in CMakeList.txt.
|
||||
*/
|
||||
virtual const char* GetName() {return "include";}
|
||||
|
||||
|
||||
/**
|
||||
* Succinct documentation.
|
||||
*/
|
||||
virtual const char* GetTerseDocumentation()
|
||||
virtual const char* GetTerseDocumentation()
|
||||
{
|
||||
return "Read CMake listfile code from the given file.";
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* More documentation.
|
||||
*/
|
||||
|
@ -73,13 +73,17 @@ public:
|
|||
"the variable will be set to the full filename which "
|
||||
"has been included or NOTFOUND if it failed.\n"
|
||||
"If a module is specified instead of a file, the file with name "
|
||||
"<modulename>.cmake is searched in the CMAKE_MODULE_PATH."
|
||||
"<modulename>.cmake is searched first in CMAKE_MODULE_PATH, then in the "
|
||||
"CMake module directory. There is one exception to this: if the file "
|
||||
"which calls include() is located itself in the CMake module directory, "
|
||||
"then first the CMake module directory is searched and "
|
||||
"CMAKE_MODULE_PATH afterwards. See also policy CMP0017."
|
||||
"\n"
|
||||
"See the cmake_policy() command documentation for discussion of the "
|
||||
"NO_POLICY_SCOPE option."
|
||||
;
|
||||
}
|
||||
|
||||
|
||||
cmTypeMacro(cmIncludeCommand, cmCommand);
|
||||
};
|
||||
|
||||
|
|
|
@ -2825,35 +2825,100 @@ void cmMakefile::DisplayStatus(const char* message, float s)
|
|||
|
||||
std::string cmMakefile::GetModulesFile(const char* filename)
|
||||
{
|
||||
std::vector<std::string> modulePath;
|
||||
const char* def = this->GetDefinition("CMAKE_MODULE_PATH");
|
||||
if(def)
|
||||
{
|
||||
cmSystemTools::ExpandListArgument(def, modulePath);
|
||||
}
|
||||
std::string result;
|
||||
|
||||
// Also search in the standard modules location.
|
||||
def = this->GetDefinition("CMAKE_ROOT");
|
||||
if(def)
|
||||
// We search the module always in CMAKE_ROOT and in CMAKE_MODULE_PATH,
|
||||
// and then decide based on the policy setting which one to return.
|
||||
// See CMP0017 for more details.
|
||||
// The specific problem was that KDE 4.5.0 installs a
|
||||
// FindPackageHandleStandardArgs.cmake which doesn't have the new features
|
||||
// of FPHSA.cmake introduced in CMake 2.8.3 yet, and by setting
|
||||
// CMAKE_MODULE_PATH also e.g. FindZLIB.cmake from cmake included
|
||||
// FPHSA.cmake from kdelibs and not from CMake, and tried to use the
|
||||
// new features, which were not there in the version from kdelibs, and so
|
||||
// failed ("
|
||||
std::string moduleInCMakeRoot;
|
||||
std::string moduleInCMakeModulePath;
|
||||
|
||||
// Always search in CMAKE_MODULE_PATH:
|
||||
const char* cmakeModulePath = this->GetDefinition("CMAKE_MODULE_PATH");
|
||||
if(cmakeModulePath)
|
||||
{
|
||||
std::string rootModules = def;
|
||||
rootModules += "/Modules";
|
||||
modulePath.push_back(rootModules);
|
||||
}
|
||||
//std::string Look through the possible module directories.
|
||||
for(std::vector<std::string>::iterator i = modulePath.begin();
|
||||
i != modulePath.end(); ++i)
|
||||
{
|
||||
std::string itempl = *i;
|
||||
cmSystemTools::ConvertToUnixSlashes(itempl);
|
||||
itempl += "/";
|
||||
itempl += filename;
|
||||
if(cmSystemTools::FileExists(itempl.c_str()))
|
||||
std::vector<std::string> modulePath;
|
||||
cmSystemTools::ExpandListArgument(cmakeModulePath, modulePath);
|
||||
|
||||
//Look through the possible module directories.
|
||||
for(std::vector<std::string>::iterator i = modulePath.begin();
|
||||
i != modulePath.end(); ++i)
|
||||
{
|
||||
return itempl;
|
||||
std::string itempl = *i;
|
||||
cmSystemTools::ConvertToUnixSlashes(itempl);
|
||||
itempl += "/";
|
||||
itempl += filename;
|
||||
if(cmSystemTools::FileExists(itempl.c_str()))
|
||||
{
|
||||
moduleInCMakeModulePath = itempl;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
return "";
|
||||
|
||||
// Always search in the standard modules location.
|
||||
const char* cmakeRoot = this->GetDefinition("CMAKE_ROOT");
|
||||
if(cmakeRoot)
|
||||
{
|
||||
moduleInCMakeRoot = cmakeRoot;
|
||||
moduleInCMakeRoot += "/Modules/";
|
||||
moduleInCMakeRoot += filename;
|
||||
cmSystemTools::ConvertToUnixSlashes(moduleInCMakeRoot);
|
||||
if(!cmSystemTools::FileExists(moduleInCMakeRoot.c_str()))
|
||||
{
|
||||
moduleInCMakeRoot = "";
|
||||
}
|
||||
}
|
||||
|
||||
// Normally, prefer the files found in CMAKE_MODULE_PATH. Only when the file
|
||||
// from which we are being called is located itself in CMAKE_ROOT, then
|
||||
// prefer results from CMAKE_ROOT depending on the policy setting.
|
||||
result = moduleInCMakeModulePath;
|
||||
if (result.size() == 0)
|
||||
{
|
||||
result = moduleInCMakeRoot;
|
||||
}
|
||||
|
||||
if ((moduleInCMakeModulePath.size()>0) && (moduleInCMakeRoot.size()>0))
|
||||
{
|
||||
const char* currentFile = this->GetDefinition("CMAKE_CURRENT_LIST_FILE");
|
||||
if (currentFile && (strstr(currentFile, cmakeRoot) == currentFile))
|
||||
{
|
||||
switch (this->GetPolicyStatus(cmPolicies::CMP0017))
|
||||
{
|
||||
case cmPolicies::WARN:
|
||||
{
|
||||
cmOStringStream e;
|
||||
e << "File " << currentFile << " includes "
|
||||
<< moduleInCMakeModulePath
|
||||
<< " (found via CMAKE_MODULE_PATH) which shadows "
|
||||
<< moduleInCMakeRoot << ". This may cause errors later on .\n"
|
||||
<< this->GetPolicies()->GetPolicyWarning(cmPolicies::CMP0017);
|
||||
|
||||
this->IssueMessage(cmake::AUTHOR_WARNING, e.str());
|
||||
// break; // fall through to OLD behaviour
|
||||
}
|
||||
case cmPolicies::OLD:
|
||||
result = moduleInCMakeModulePath;
|
||||
break;
|
||||
case cmPolicies::REQUIRED_IF_USED:
|
||||
case cmPolicies::REQUIRED_ALWAYS:
|
||||
case cmPolicies::NEW:
|
||||
default:
|
||||
result = moduleInCMakeRoot;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
void cmMakefile::ConfigureString(const std::string& input,
|
||||
|
|
|
@ -446,6 +446,23 @@ cmPolicies::cmPolicies()
|
|||
"wasn't a valid target. "
|
||||
"In CMake 2.8.3 and above it reports an error in this case.",
|
||||
2,8,3,0, cmPolicies::WARN);
|
||||
|
||||
this->DefinePolicy(
|
||||
CMP0017, "CMP0017",
|
||||
"Prefer files from the CMake module directory when including from there.",
|
||||
"Starting with CMake 2.8.4, if a cmake-module shipped with CMake (i.e. "
|
||||
"located in the CMake module directory) calls include() or "
|
||||
"find_package(), the files located in the the CMake module directory are "
|
||||
"prefered over the files in CMAKE_MODULE_PATH. "
|
||||
"This makes sure that the modules belonging to "
|
||||
"CMake always get those files included which they expect, and against "
|
||||
"which they were developed and tested. "
|
||||
"In call other cases, the files found in "
|
||||
"CMAKE_MODULE_PATH still take precedence over the ones in "
|
||||
"the CMake module directory. "
|
||||
"The OLD behaviour is to always prefer files from CMAKE_MODULE_PATH over "
|
||||
"files from the CMake modules directory.",
|
||||
2,8,4,0, cmPolicies::WARN);
|
||||
}
|
||||
|
||||
cmPolicies::~cmPolicies()
|
||||
|
@ -495,9 +512,9 @@ bool cmPolicies::ApplyPolicyVersion(cmMakefile *mf,
|
|||
std::string ver = "2.4.0";
|
||||
|
||||
if (version && strlen(version) > 0)
|
||||
{
|
||||
{
|
||||
ver = version;
|
||||
}
|
||||
}
|
||||
|
||||
unsigned int majorVer = 2;
|
||||
unsigned int minorVer = 0;
|
||||
|
@ -556,29 +573,33 @@ bool cmPolicies::ApplyPolicyVersion(cmMakefile *mf,
|
|||
|
||||
// now loop over all the policies and set them as appropriate
|
||||
std::vector<cmPolicies::PolicyID> ancientPolicies;
|
||||
std::map<cmPolicies::PolicyID,cmPolicy *>::iterator i
|
||||
= this->Policies.begin();
|
||||
for (;i != this->Policies.end(); ++i)
|
||||
{
|
||||
if (i->second->IsPolicyNewerThan(majorVer,minorVer,patchVer,tweakVer))
|
||||
for(std::map<cmPolicies::PolicyID,cmPolicy *>::iterator i
|
||||
= this->Policies.begin(); i != this->Policies.end(); ++i)
|
||||
{
|
||||
if (i->second->IsPolicyNewerThan(majorVer,minorVer,patchVer,tweakVer))
|
||||
{
|
||||
if(i->second->Status == cmPolicies::REQUIRED_ALWAYS)
|
||||
{
|
||||
{
|
||||
ancientPolicies.push_back(i->first);
|
||||
}
|
||||
else
|
||||
{
|
||||
cmPolicies::PolicyStatus status = cmPolicies::WARN;
|
||||
if(!this->GetPolicyDefault(mf, i->second->IDString, &status) ||
|
||||
!mf->SetPolicy(i->second->ID, status))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
else if (!mf->SetPolicy(i->second->ID, cmPolicies::WARN))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if (!mf->SetPolicy(i->second->ID, cmPolicies::NEW))
|
||||
{
|
||||
if (!mf->SetPolicy(i->second->ID, cmPolicies::NEW))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Make sure the project does not use any ancient policies.
|
||||
if(!ancientPolicies.empty())
|
||||
|
@ -592,6 +613,36 @@ bool cmPolicies::ApplyPolicyVersion(cmMakefile *mf,
|
|||
return true;
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------
|
||||
bool cmPolicies::GetPolicyDefault(cmMakefile* mf, std::string const& policy,
|
||||
cmPolicies::PolicyStatus* defaultSetting)
|
||||
{
|
||||
std::string defaultVar = "CMAKE_POLICY_DEFAULT_" + policy;
|
||||
std::string defaultValue = mf->GetSafeDefinition(defaultVar.c_str());
|
||||
if(defaultValue == "NEW")
|
||||
{
|
||||
*defaultSetting = cmPolicies::NEW;
|
||||
}
|
||||
else if(defaultValue == "OLD")
|
||||
{
|
||||
*defaultSetting = cmPolicies::OLD;
|
||||
}
|
||||
else if(defaultValue == "")
|
||||
{
|
||||
*defaultSetting = cmPolicies::WARN;
|
||||
}
|
||||
else
|
||||
{
|
||||
cmOStringStream e;
|
||||
e << defaultVar << " has value \"" << defaultValue
|
||||
<< "\" but must be \"OLD\", \"NEW\", or \"\" (empty).";
|
||||
mf->IssueMessage(cmake::FATAL_ERROR, e.str().c_str());
|
||||
return false;
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
bool cmPolicies::GetPolicyID(const char *id, cmPolicies::PolicyID &pid)
|
||||
{
|
||||
if (!id || strlen(id) < 1)
|
||||
|
|
|
@ -52,6 +52,7 @@ public:
|
|||
CMP0014, // Input directories must have CMakeLists.txt
|
||||
CMP0015, // link_directories() treats paths relative to source dir
|
||||
CMP0016, // target_link_libraries() fails if only argument is not a target
|
||||
CMP0017, // Prefer files in CMAKE_ROOT when including from CMAKE_ROOT
|
||||
|
||||
// Always the last entry. Useful mostly to avoid adding a comma
|
||||
// the last policy when adding a new one.
|
||||
|
@ -102,6 +103,10 @@ public:
|
|||
void DiagnoseAncientPolicies(std::vector<PolicyID> const& ancient,
|
||||
unsigned int majorVer, unsigned int minorVer,
|
||||
unsigned int patchVer, cmMakefile* mf);
|
||||
|
||||
bool GetPolicyDefault(cmMakefile* mf, std::string const& policy,
|
||||
cmPolicies::PolicyStatus* defaultStatus);
|
||||
|
||||
};
|
||||
|
||||
#endif
|
||||
|
|
|
@ -1,6 +1,15 @@
|
|||
cmake_minimum_required (VERSION 2.6)
|
||||
PROJECT(FindPackageTest)
|
||||
|
||||
LIST(APPEND CMAKE_MODULE_PATH ${CMAKE_CURRENT_SOURCE_DIR})
|
||||
|
||||
# Look for a package which uses FindPackageHandleStandardArgs.cmake with the
|
||||
# new (as of cmake 2.8.3) syntax. This works only if CMP0017 is set to NEW,
|
||||
# because otherwise FindPackageHandleStandardArgs.cmake from the current
|
||||
# directory is included (via CMAKE_MODULE_PATH).
|
||||
CMAKE_POLICY(SET CMP0017 NEW)
|
||||
FIND_PACKAGE(ZLIB QUIET)
|
||||
|
||||
# Look for a package that has a find module and may be found.
|
||||
FIND_PACKAGE(OpenGL QUIET)
|
||||
|
||||
|
@ -23,7 +32,6 @@ IF(NOT FOO_DIR)
|
|||
CMAKE_PREFIX_PATH = ${CMAKE_PREFIX_PATH}")
|
||||
ENDIF(NOT FOO_DIR)
|
||||
|
||||
LIST(APPEND CMAKE_MODULE_PATH ${CMAKE_CURRENT_SOURCE_DIR})
|
||||
FIND_PACKAGE(VersionTestA 1)
|
||||
FIND_PACKAGE(VersionTestB 1.2)
|
||||
FIND_PACKAGE(VersionTestC 1.2.3)
|
||||
|
|
|
@ -0,0 +1 @@
|
|||
message(FATAL_ERROR "This file (${CMAKE_CURRENT_LIST_FILE}) must not be included, but FindPackageHandleStandardArgs.cmake from Modules/ instead !")
|
|
@ -81,6 +81,24 @@ macro1()
|
|||
cmake_policy(GET CMP0002 cmp)
|
||||
check(CMP0002 "OLD" "${cmp}")
|
||||
|
||||
#-----------------------------------------------------------------------------
|
||||
# Test CMAKE_POLICY_DEFAULT_CMP<NNNN> variable.
|
||||
cmake_policy(PUSH)
|
||||
set(CMAKE_POLICY_DEFAULT_CMP0010 OLD) # ignored
|
||||
set(CMAKE_POLICY_DEFAULT_CMP0012 OLD) # honored
|
||||
set(CMAKE_POLICY_DEFAULT_CMP0013 NEW) # honored
|
||||
set(CMAKE_POLICY_DEFAULT_CMP0014 "") # noop
|
||||
cmake_policy(VERSION 2.6.3)
|
||||
cmake_policy(GET CMP0010 cmp)
|
||||
check(CMP0010 "NEW" "${cmp}")
|
||||
cmake_policy(GET CMP0012 cmp)
|
||||
check(CMP0012 "OLD" "${cmp}")
|
||||
cmake_policy(GET CMP0013 cmp)
|
||||
check(CMP0013 "NEW" "${cmp}")
|
||||
cmake_policy(GET CMP0014 cmp)
|
||||
check(CMP0014 "" "${cmp}")
|
||||
cmake_policy(POP)
|
||||
|
||||
#-----------------------------------------------------------------------------
|
||||
# Dummy executable so the project can build and run.
|
||||
add_executable(PolicyScope main.c)
|
||||
|
|
Loading…
Reference in New Issue