CMakeExportBuildSettings.cmake 1.2 KB

1234567891011121314151617181920212223
  1. # This module is purposely no longer documented. It does nothing useful.
  2. IF(NOT "${CMAKE_MINIMUM_REQUIRED_VERSION}" VERSION_LESS 2.7)
  3. MESSAGE(FATAL_ERROR
  4. "The functionality of this module has been dropped as of CMake 2.8. "
  5. "It was deemed harmful (confusing users by changing their compiler). "
  6. "Please remove calls to the CMAKE_EXPORT_BUILD_SETTINGS macro and "
  7. "stop including this module. "
  8. "If this project generates any files for use by external projects, "
  9. "remove any use of the CMakeImportBuildSettings module from them.")
  10. ENDIF()
  11. # This macro used to store build settings of a project in a file to be
  12. # loaded by another project using CMAKE_IMPORT_BUILD_SETTINGS. Now it
  13. # creates a file that refuses to load (with comment explaining why).
  14. MACRO(CMAKE_EXPORT_BUILD_SETTINGS SETTINGS_FILE)
  15. IF(${SETTINGS_FILE} MATCHES ".+")
  16. CONFIGURE_FILE(${CMAKE_ROOT}/Modules/CMakeBuildSettings.cmake.in
  17. ${SETTINGS_FILE} @ONLY IMMEDIATE)
  18. ELSE(${SETTINGS_FILE} MATCHES ".+")
  19. MESSAGE(SEND_ERROR "CMAKE_EXPORT_BUILD_SETTINGS called with no argument.")
  20. ENDIF(${SETTINGS_FILE} MATCHES ".+")
  21. ENDMACRO(CMAKE_EXPORT_BUILD_SETTINGS)