Merge branch 'fix-genex-HEAD-target' into release
diff --git a/ChangeLog.manual b/ChangeLog.manual
index 90c9162..a0da0d5 100644
--- a/ChangeLog.manual
+++ b/ChangeLog.manual
@@ -1,3 +1,649 @@
+Changes in CMake 2.8.11 (since 2.8.11-rc4)
+----------------------------------------
+None
+
+Changes in CMake 2.8.11-rc4 (since 2.8.11-rc3)
+----------------------------------------------
+Brad King (1):
+ target_link_libraries: Update usage requirements documentation
+
+Stephen Kelly (3):
+ Centralize maintenance of usage requirement include directories
+ Fix include dir propagation from conditionally linked targets
+ Memoize usage requirement include directories in a config-specific map
+
+Changes in CMake 2.8.11-rc3 (since 2.8.11-rc2)
+----------------------------------------------
+Brad King (1):
+ get_filename_component: Document path components more clearly (#14091)
+
+Rolf Eike Beer (1):
+ try_compile: add missing fclose() to recently added error case
+
+Stephen Kelly (1):
+ Fix clearing of the INCLUDE_DIRECTORIES DIRECTORY property.
+
+Changes in CMake 2.8.11-rc2 (since 2.8.11-rc1)
+----------------------------------------------
+Alex Neundorf (6):
+ Determine C/CXX/Fortran compiler: minor restructuring
+ Determine C/CXX/Fortran compiler: fix indentation
+ rename TI_DSP toolchain to TI, since it works also for the ARM compiler
+ TI compiler: add automatic detection of prefix and suffixes
+ Modules/readme.txt: switch from "XXX" to "Xxx"
+ Modules/readme.txt: make lines a bit shorter for easier readability
+
+Ben Boeckel (1):
+ Clang: Add -isystem flag support everywhere
+
+Bill Hoffman (1):
+ ExternalProject: Retry on a failed git clone
+
+Brad King (8):
+ string: Fix regex documentation of '^' and '$' (#14028)
+ Rename variable for including current directory in interfaces
+ Replace <TARGET> in CMAKE_<LANG>_COMPILE_OBJECT rule variables
+ Test evaluation of per-config COMPILE_DEFINITIONS (#14037)
+ VS: Fix VS 10/11 .sln headers (#14038)
+ add_dependencies: Distinguish target v. file dependencies in error (#14050)
+ automoc: Use a pre-build event in VS >= 7
+ Handle usr-move without forcing absolute paths (#14041)
+
+Clinton Stimpson (2):
+ FindQt4: If Qt5 is in CMAKE_PREFIX_PATH, be sure to find Qt4 includes.
+ Qt4: Fix typo setting a variable for FindThreads.
+
+James Bigler (1):
+ FindCUDA: Use the PRE_LINK mode only for MSVC >= 10
+
+Matthew Woehlke (4):
+ UseJava.cmake: simplify path logic
+ UseJava.cmake: fix passing jars to add_jar
+ UseJava.cmake: accept jar targets in add_jar
+ UseJava.cmake: require explicit request to include jars
+
+Paul Kunysch (1):
+ CPack: Avoid "format expects 'unsigned int'" warnings
+
+Petr Kmoch (1):
+ cmSystemTools: Generalize TrimWhitespace to all whitespace
+
+Rex Dieter (1):
+ FindImageMagick: Search versioned suffixes (#14012)
+
+Rolf Eike Beer (1):
+ FindRuby: improve version selection
+
+Stephen Kelly (13):
+ FindQt4: Set the Qt4_FOUND variable if Qt4 is found
+ FindQt4: Set the INTERFACE_QT_MAJOR_VERSION for Qt4::QtCore
+ Document that CMAKE_AUTOMOC works with Qt 5.
+ FPHSA: Fix FOUND_VAR check to work with if() auto-dereference
+ Fix cmGeneratorExpression::Preprocess for interleaved inputs.
+ cmake-gui: Use the QStandardItemModel workaround until 5.1.0.
+ Automoc: append implicit includes after user-specified dirs
+ Fix the evaluation of per-config COMPILE_DEFINITIONS (#14037)
+ Fix new target commands documentation.
+ install(EXPORT): Ensure clean INTERFACE_INCLUDE_DIRECTORIES
+ Report an error on IMPORTED targets with a faulty INTERFACE
+ Error if linked target has relative paths in INTERFACE_INCLUDE_DIRECTORIES
+ Fix the Qt 5 version required to run the IncompatibleQt test.
+
+Changes in CMake 2.8.11-rc1 (since 2.8.10.2)
+----------------------------------------------
+Alan Witkowski (1):
+ FindBullet: Search in per-config dirs on Windows (#13738)
+
+Aleksey Avdeev (1):
+ Add module FindIcotool
+
+Alex Neundorf (30):
+ Eclipse: add switch to disable linked resources (#13189)
+ Eclipse: set source path once to fix Eclipse indexer (#13596)
+ cmDependsC: remove unused member variable
+ cmDependsC: remove code duplication
+ cmDependsC: fix indentation
+ cmDepends: allow multiple dependees per depender
+ AddCustomCommand: Handle multiple IMPLICIT_DEPENDS files (#10048)
+ Add support for Texas Instruments DSP compiler (#12405)
+ Squish: detect version
+ Squish: use FPHSA
+ Squish: find executables also under Windows
+ Squish: rename squish_add_test() to squish_v3_add_test() and fix docs a bit
+ Squish: use ${CMAKE_CURRENT_LIST_DIR}
+ Squish: add support for squish 4 (#9734)
+ Squish: fix new squish_v4_add_test() macro
+ Automoc: "inherit" FOLDER target property from target (#13688)
+ FPHSA: don't succeed if only checking for XX_FOUND (#13755)
+ CONFIGURE_PACKAGE_CONFIG_FILE(): improve generated comments
+ Automoc: get include dirs without stripping implicit include dirs off
+ configure_package_config_file: force absolute paths for usr-move
+ configure_package_config_file(): fix indentation
+ configure_package_config_file(): extend documentation
+ documentation: handling of relative paths by include- and link_directories()
+ automoc: use a std::vector<> instead a std::list
+ automoc: use the header extensions from cmMakefile
+ Eclipse: also detect include dirs and macro for clang (#13823)
+ cmLocalGenerator: remove "virtual" where not used
+ export files: rewrite the code for checking required targets
+ FPHSA: Add FOUND_VAR option to specify _FOUND variable name
+ FPHSA: improve documentation
+
+Alexander Chehovsky (2):
+ Xcode: Fix nested source group handling (#12943)
+ Xcode: Sort source files
+
+Amine Chadly (2):
+ file: remove dead code
+ Add test to secure the file(GLOB empty) behavior.
+
+Amit Kulkarni (6):
+ OpenBSD: Install shared libraries without executable permission
+ OpenBSD: Add paths for Java 1.6.0/1.7.0 JRE/JDK
+ OpenBSD: Add path for Freetype under X.org
+ OpenBSD: Add paths for Tcl/Tk 8.4/8.5
+ OpenBSD: Add path for Lua 5.1
+ OpenBSD: Add paths for Qt3/Qt4
+
+Andreas Mohr (4):
+ Documentation: Correct typos and grammar
+ Documentation: Clarify some command descriptions
+ Correct string literal typo (have "(NULL)" like all other cases).
+ Remove seemingly bogus duplicate CPACK_PACKAGE_FILE_NAME call.
+
+Anton Helwart (1):
+ VS: Avoid empty source groups in some cases (#3474)
+
+Benjamin Eikel (2):
+ Swap linking order of SDLmain and SDL (#0013769)
+ FindSDL_...: Restore dropped search paths (#13819)
+
+Brad King (109):
+ find_library: Refactor internal name iteration
+ find_library: Simplify framework search logic
+ find_library: Generalize helper macro in test case
+ find_library: Optionally consider all names in each directory
+ FindBoost: Remove extra indentation level
+ FindBoost: Mark Boost_DIR cache entry as advanced
+ FindBoost: Use PATH_SUFFIXES to look in "Program Files"
+ FindBoost: Overhaul caching and search repeat behavior
+ FindBoost: Construct a clean Boost_LIBRARIES value
+ FindBoost: Refactor Boost_FOUND computation and version check
+ FindBoost: Rewrite documentation
+ BSD: Do not require dlfcn.h to build shared libs (#13573)
+ Xcode: Fix ReRunCMake.make path to cmake.check_cache (#13603)
+ VS10: Refactor link options collection
+ VS10: Honor /DELAYSIGN and /KEYFILE flags (#13601)
+ Document external language support policy
+ CTest: Allow SUBMIT_INDEX with CDash
+ KWSys: Submit dashboard builds to PublicDashboard
+ pre-commit: Update KWSys rejection message for new workflow
+ CTestCustom: Suppress LNK4089 warning about PSAPI
+ load_command: Deprecate and document pending removal
+ Documentation: Clarify configure_file behavior
+ OS X: Warn about known SDK breakage by Xcode 3.2.6
+ Optionally skip link dependencies on shared library files
+ Teach BuildDepends test to cover LINK_DEPENDS_NO_SHARED
+ Serialize tests for EXCLUDE_FROM_DEFAULT_BUILD
+ MSVC: Drop default use of /Zm1000 for VS >= 7.1
+ Teach find_(path|file) about Linux multiarch (#13742)
+ Test find_path multiarch support (#13742)
+ Add policy CMP0019 to skip include/link variable re-expansion
+ Xcode: Add frameworks search paths from link dependeny closure (#13397)
+ Makefile: Use modern link information for framework search paths
+ Documentation: Clarify handling of implicit link directories
+ Remove references to KWSys Process Win9x support
+ add_library: Document object library portability suggestion
+ OS X: Link with all framework search paths, not just the last
+ OS X: Detect implicit link directories on modern toolchains
+ OS X: Detect implicit linker framework search paths
+ Revert "load_command: Deprecate and document pending removal"
+ VS11: Simplify external object file handling (#13831)
+ KWIML: Teach ABI about 'long long' on older GNU
+ CMake: Skip empty link.txt lines (#13845)
+ ExternalProject: Allow DEPENDS on normal targets (#13849)
+ VS11: Fix VSExternalInclude test
+ target_link_libraries: Document that new sigs privatize old (#13876)
+ Tests: Avoid CTestLimitDashJ crash on Borland 5.8 builds
+ Fix use of cmTypeMacro in new command classes
+ Fix cmSystemTools::RenameFile race on Windows
+ VS 6: Create .rule file directory before file
+ Add ExternalData module
+ ExternalData: Remove compatibility with CMake < 2.8.5
+ ExternalData: Do not match directory names when resolving DATA{}
+ ExternalData: Cleanup stray TODO and typo in comments
+ ExternalData: Remove unused private interface
+ ExternalData: Improve series matching using an explicit syntax
+ ExternalData: Add tests covering interfaces and errors
+ ExternalData: Allow ()-groups in series match regex
+ ExternalData: Allow DATA{} syntax to reference directories
+ ExternalData: Generalize hash algo/ext handling
+ ExternalData: Add support for SHA 1 and 2 hash algorithms
+ ExternalData: Collapse ../ components in DATA{} paths
+ Fix Module.ExternalData test on Cygwin
+ Fix Module.ExternalData test on VS 6
+ ExternalData: Attach download rules to content links in IDEs
+ find_package: Reword <package>_NO_INTERFACES documentation
+ Normalize full paths in implicit link library list
+ Fail early if no current working directory exists
+ MSVC: Fix CMAKE_CL_64 in CXX-only projects (#13896)
+ ExternalProject: Simplify CMake command line generation
+ Tests: Run ctest custom commands with VERBATIM
+ CMake: Add -T option to choose a generator toolset
+ VS: Implement generator toolset selection (#10722, #13774)
+ Xcode: Implement generator toolset selection (#9831, #13802)
+ CTest: Add options to set generator toolset
+ ExternalProject: Propagate the generator toolset
+ Tests: Consolidate ctest --build-and-test generator options
+ Tests: Add generator toolset support
+ Fix crash on empty CMAKE_<lang>_COMPILER value (#13901)
+ file: Do not remove symlinked directories recursively (#10538)
+ Embarcadero: Fix default link stack/heap flags (#13912)
+ Avoid duplicate RPATH entries
+ AIX-GNU: Put implicit link directories in runtime libpath (#13909)
+ VS: Replace generation timestamp file atomically
+ VS,Xcode: Remove unused CMAKE_GENERATOR_* variables
+ Delete entire CMakeFiles directory when deleting CMakeCache.txt (#13756)
+ Tests/RunCMake: Allow tests to control build tree behavior
+ Test Unix Makefiles generator support for changing compilers
+ Xcode: Drop check for circular target dependencies
+ Xcode: Each target dependency edge needs a unique object (#13935)
+ Tests: Replace exec_program with execute_process
+ Tests: Generalize decision for 'make' tool supporting spaces
+ ExternalData: Test content link with a space in its name
+ FPHSA: Convert FOUND_VAR failure test to RunCMake
+ VS: Restore CMAKE_GENERATOR_FC variable
+ Xcode: Generate recommended artwork setting (#13954)
+ CTest: Fix ctest_update with 'HEAD' file in source tree
+ VS 10: Fix CMAKE_<LANG>_STACK_SIZE implementation (#13968)
+ install(EXPORT): Force absolute paths for usr-move
+ AIX: Do not use -brtl to create shared libraries (#13997)
+ add_subdirectory: Compute output dir with consistent slashes (#10072)
+ ExternalData: Preserve escaped semicolons during argument expansion
+ Avoid crash when checking property link dependencies without link info
+ Avoid crash when checking property compatibility without link info
+ Refactor RunCMake.build_command test to allow more cases
+ build_command: Fail early without CMAKE_MAKE_PROGRAM (#14005)
+ CTest: Fail early without PROJECT_BINARY_DIR (#14005)
+ FindQt4: Fix QT_QMAKE{_QMAKE => }_EXECUTABLE typo
+ XL: Use -qpic for position independent code (#14010)
+ Configure Tests/CMakeTests only with BUILD_TESTING ON
+
+Casey Goodlett (1):
+ CTest: Prevent creation of unbounded number of tests in ctest (#12904)
+
+Clemens Heppner (1):
+ CMake: source_group needs to check its own regex after its children (#13611)
+
+Clinton Stimpson (5):
+ Fix for possible Rez errors when creating dmg.
+ PackageMaker: Enable postflight script in component mode (#12375)
+ CPack: Fix RPM/Deb package names to not include "ALL_COMPONENTS_IN_ONE"
+ Qt4: Add SYSTEM option to include_directories.
+ FindQt4: set QT_VERSION_* variables sooner.
+
+David Cole (19):
+ Begin post-2.8.10 development
+ CPack: Add automatic detection of the Unicode makensis (#9629)
+ BundleUtilities: Use a more inclusive REGEX for frameworks (#13600)
+ VS: Avoid empty, unreferenced solution folders... (#13571)
+ NMake: Add a test to demonstrate EmptyDepends issue (#13392)
+ NMake: Fix problem with empty DEPENDS args (#13392)
+ CMake: Remove "/STACK:10000000" from default linker flags (#12437)
+ Watcom: Avoid prompt from wmake about dll with no exports...
+ Tests: Use the right path to CPack value for running CPack tests
+ VS11: Allow using folders with the VS11 Express Edition (#13770)
+ CPack: Fix dashboard errors (#11575)
+ CPack: Fix dashboard warnings (#11575)
+ CPack: Fix dashboard errors and warnings (#11575)
+ CMake: Stylistic changes and documentation tweaks
+ CMake: Fix dashboard warnings
+ CMake: Fix dashboard test failure
+ CMake: Fix dashboard build errors and warnings
+ CTest: Coverage handler: expect certain output lines from gcov 4.7 (#13657)
+ Add CTestLimitDashJ test (#12904)
+
+David Golub (2):
+ CPack/NSIS: Fix compatibility issues with prerelease NSIS (#13202)
+ CPack/NSIS: Add support for 64-bit NSIS (#13203)
+
+Eric LaFranchi (1):
+ CPack: WIX Product Icon, UI Banner, UI Dialog support (#13789)
+
+Eric NOULARD (1):
+ CPackRPM fix #13898 uses IF(DEFINED var) to avoid wrong var value logic
+
+Gerald Hofmann (1):
+ CPack: Fix NSIS version check without release version (#9721)
+
+James Bigler (4):
+ Use PRE_LINK instead of PRE_BUILD when testing PRE_LINK.
+ FindCUDA: Remove linkage against CUDA driver library (#13084)
+ FindCUDA: Add support for separable compilation
+ FindCUDA: Added cupti library.
+
+Janne Rönkkö (1):
+ FindQt4: Do not use qmake from Qt5
+
+Jean-Christophe Fillion-Robin (1):
+ Add $<SEMICOLON> generator expression.
+
+Marcus D. Hanwell (1):
+ Removed GenerateExportHeader warnings about old compilers
+
+Mark Salisbury (2):
+ VS: Specify WinCE subsystem also for DLLs
+ VS: Specify WinCE subsystems correctly in VS 9 2008
+
+Mathias Gaunard (2):
+ enable CTEST_USE_LAUNCHERS with Ninja too
+ Ninja: fix usage of cldeps with ctest launchers
+
+Matt McCormick (7):
+ ExternalProject: Only run 'git fetch' when required.
+ ExternalProject: Do smoke tests for Git Tutorial builds.
+ ExternalProject: Add tests for UPDATE_COMMAND.
+ ExternalProject: Always do a git fetch for a remote ref.
+ ExternalProject: Make sure the ExternalProjectUpdate setup is available.
+ ExternalProject: Verify when a fetch occurs during update test.
+ ExternalProjectUpdateTest: Only support Git 1.6.5 and greater.
+
+Matthew Woehlke (1):
+ ccmake: Allow DEL key in first column
+
+Michael Tänzer (4):
+ GetPrerequisites: Move tool search paths up
+ GetPrerequisites: Add support for objdump
+ GetPrerequisites: Enable test for BundleUtilities on MinGW
+ GetPrerequisites: Add documentation for objdump
+
+Michael Wild (1):
+ cmDepends: No dependency-vector erasure in CheckDependencies
+
+Morné Chamberlain (15):
+ Added a generator for Sublime Text 2 project files.
+ Added some support for sublimeclang_options in the generated project file.
+ Changed SublimeClang include path generation to expand to absolute paths.
+ Cleaned up the Sublime Text 2 Generator code a bit.
+ Fixed support for the Ninja build system.
+ Added and cleaned up some comments.
+ The generator no longer generates an explicit list of source files.
+ The generator no longer generates absolute paths to the ninja.build/Makefiles.
+ Added a CMAKE_SUBLIMECLANG_DISABLED variable that disables SublimeClang.
+ Fixed Sublime Text project generation for in-source builds
+ Define flags in CMAKE_C(XX)_FLAGS are now included in SublimeClang settings.
+ SublimeText2 Gen: Improved use of define, include flags from CMAKE_C(XX)_FLAGS
+ SublimeText2 Gen: Fixed the issue where include directory flags used -D
+ Sublime Text 2 Gen: Per-source Compile flags are now saved in a separate file.
+ SublimeText 2 Gen: Set the sublimeclang_options_script property.
+
+Neil Carlson (1):
+ NAG: Use -PIC for Fortran position-independent code (#13932)
+
+Nils Gladitz (2):
+ CPack: Add a WiX Generator (#11575)
+ CMake: Add TIMESTAMP subcommand to string and file commands
+
+Patrick Gansterer (28):
+ Introduce the abstract class cmGlobalGeneratorFactory
+ Add cmGlobalGeneratorFactory::GetGenerators()
+ Search generator in cmake::ExtraGenerators before in cmake::Generators
+ Allow a GeneratorFactory handling of more than one generator
+ Make cmGlobalGenerator::GetDocumentation() a static function
+ VS: Remove AddPlatformDefinitions from platform-specific generators
+ VS: Fix ArchitectureId of Visual Studio 10 IA64 generator
+ VS: Remove GetPlatformName from platform-specific generators
+ VS: Remove EnableLanguage from platform-specific generators
+ VS: Remove platform specific generator files
+ FindBISON: Add support for the Win flex-bison distribution
+ FindFLEX: Add support for the Win flex-bison distribution
+ VS: Remove TargetMachine for linker when checking compiler id
+ VS: Add CMAKE_VS_PLATFORM_NAME definition to cmMakefile
+ VS: Add static method to get the base of the registry
+ VS: Change variable type of ArchitectureId from const char* to string
+ VS: Change variable type of Name from const char* to string
+ VS: Support setting correct subsystem and entry point for WinCE
+ VS: Add parser for WCE.VCPlatform.config to read WinCE platforms
+ VS: Allow setting the name of the target platform
+ VS: Make DetermineCompilerId working with WinCE too
+ VS: Added "Deploy" at project configuration for WindowsCE targets
+ Add command to generate environment for a Windows CE SDK
+ VS: Set the correct SubSystem when determinating the CompilerId
+ VS: Add the entry point when compiling for WindowsCE
+ VS: Ignore LIBC.lib when linking the CompilerId executables
+ Set WINCE to 1 when building for WindowsCE
+ Ninja: Avoid LNK1170 linker error
+
+Peter Kümmel (6):
+ Ninja: encode LINK_FLAGS to handle bash variables
+ Ninja: fix building from Codeblocks GUI
+ Ninja: remove implicit dependency on custom command outputs
+ Ninja: use MinGW generator code in EnableLanguage()
+ Ninja: the Ninja generator does not support Fortran yet.
+ Ninja: escape line breaks in literals
+
+Petr Kmoch (11):
+ Add tests for list() argument count
+ Add tests for list() invalid arguments
+ Consolidate list() argument count testing
+ Add several get_property() tests
+ Add tests for EXCLUDE_FROM_DEFAULT_BUILD
+ Add property EXCLUDE_FROM_DEFAULT_BUILD_<CONFIG>
+ Define property EXCLUDE_FROM_DEFAULT_BUILD
+ Add tests for VS_SOLUTION_GLOBAL_SECTIONS
+ Implement properties VS_GLOBAL_SECTION_*
+ Define properties VS_GLOBAL_SECTION_*
+ Documentation: Clarify a few subtleties
+
+Riku Voipio (1):
+ KWIML: Teach ABI.h about Aarch64
+
+Robert Maynard (4):
+ XCode generator won't infinitely parse compiler flags (bug #13354).
+ Correct missing parameter to CMP0018Flags call.
+ Remove ability to generate sublime clang files.
+ Update generator to use new cmGeneratorTarget api.
+
+Rodolfo Schulz de Lima (1):
+ FindGTK2: Fix GTK2_LIBRARIES order for static gtk libraries
+
+Rolf Eike Beer (21):
+ FindQt: improve version selection
+ FindQt: add some more places to look for Qt3
+ Tests: add MajorVersionSelection tests
+ Linux/PA-RISC: Link with --unique=.text.* to help binutils
+ FindQt: add to MajorVersionSelection test
+ CMakeTests: allow to call the check_cmake_test macro with a given file
+ list: add tests for CMP0007 behavior
+ GetProperty test: move doc property tests into main process
+ Find* (and some other): use ${CMAKE_CURRENT_LIST_DIR} in include()
+ bootstrap: use better defaults for Haiku
+ Haiku no longer defines __BEOS__
+ check for Haiku only with __HAIKU__
+ FindLua51: do not try to link libm on BeOS
+ FindGLUT: BeOS does not have libXi and libXmu
+ FindOpenGL: add Haiku paths
+ doc: fix linebreaks in generator expression documentation
+ ProcessorCount test: fix path to cmsysTestsCxx executable
+ ProcessorCount test: require SystemInformation process to work
+ FindOpenMP: improve documentation (#13895)
+ properly detect processor architecture on Windows
+ fix Windows processor detection
+
+Sean McBride (1):
+ libarchive: fixed undefined left shift with signed ints
+
+Slava Sysoltsev (1):
+ FindImageMagick: Search quantum depth suffixes (#13859)
+
+Stephen Kelly (158):
+ GenEx: Test early determination of AND and OR
+ Enable some compiler warnings when building CMake.
+ Resolve warnings about unused variables.
+ Resolve warnings about used enum values in switch blocks.
+ Resolve warnings about shadowing parameters and local variables.
+ Resolve ambiguity warning regarding use of && and ||.
+ Remove references to ancient and removed parts of the code.
+ Always use the auto_ptr from cmsys.
+ Port cmGeneratorExpression to cmTarget from cmGeneratorTarget.
+ Split link information processing into two steps.
+ Revert "Move GetLinkInformation to cmGeneratorTarget"
+ Genex: Extract a method to parse parameters.
+ Genex: Ensure that $<0:...> has a parameter.
+ Genex: Don't segfault on $<FOO,>
+ Generate an early-return guard in target Export files.
+ Fix some warnings from -Wundef
+ Make targets depend on the link interface of their dependees.
+ Use cmsys::auto_ptr to manage cmCompiledGeneratorExpressions
+ Keep track of INCLUDE_DIRECTORIES as a vector of structs.
+ Add a way to print the origins of used include directories.
+ Tests: Fix warning about unused variable
+ Qt4: Add module dependencies to the IMPORTED targets
+ Don't crash when a target is expected but is not available.
+ Add test for custom command with a genex referring to a target.
+ GenEx: Add expressions to specify build- or install-only values
+ Allow generator expressions to require literals.
+ Add the TARGET_NAME generator expression.
+ Add API to extract target names from a genex string.
+ Add API to populate INTERFACE properties in exported targets.
+ Make all relevant targets available in the genex context.
+ Use mapped config properties to evaluate $<CONFIG>
+ Make cycles in target properties ignored, not an error.
+ Populate the ExportedTargets member early in GenerateMainFile
+ Handle INTERFACE properties transitively for includes and defines.
+ Add CMAKE_BUILD_INTERFACE_INCLUDES build-variable.
+ Make linking APIs aware of 'head' target
+ Add LINK_LIBRARIES property for direct target link dependencies
+ Allow target_link_libraries with IMPORTED targets.
+ Add the -Wundef flag when compiling CMake.
+ FindQt4: Add INTERFACE includes and defines to Qt4 targets
+ Add the target_include_directories command.
+ Add the target_compile_definitions command.
+ Keep track of properties used to determine linker libraries.
+ Add API to calculate link-interface-dependent bool properties or error.
+ Process the INTERFACE_PIC property from linked dependencies
+ Fix linking to imported libraries test.
+ Add cmGeneratorExpression::Split() API.
+ Don't pass a position when determining if a target name is a literal.
+ Extract the AddTargetNamespace method.
+ Split the generator expression before extracting targets.
+ Split LINK_INTERFACE_LIBRARIES export handling into dedicated method.
+ Allow generator expressions in LINK_INTERFACE_LIBRARIES.
+ Add a way to check INTERFACE user property compatibility.
+ Don't include generator expressions in old-style link handling.
+ Document the use of generator expressions in new commands.
+ Add the TARGET_DEFINED generator expression
+ Strip consecutive semicolons when preprocessing genex strings.
+ Don't write a comment in the export file without the code.
+ Only generate one check per missing target.
+ Move the exported check for dependencies of targets
+ Move the exported check for file existence.
+ Add a test for the interfaces in targets exported from the build tree.
+ Make the BUILD_INTERFACE of export()ed targets work.
+ Export the INTERFACE_PIC property.
+ Test evaluation target via export for generator expressions
+ Make sure generator expressions can be used with target_include_directories.
+ Populate the link information cache before checking dependent properties.
+ Exit early if we find an inconsistent property.
+ Make INTERFACE determined properties readable in generator expressions.
+ Clear the link information in ClearLinkMaps.
+ Export the COMPATIBLE_INTERFACE_BOOL content properties
+ Add the $<TARGET_POLICY> expression
+ Automatically link to the qtmain library when linking to QtCore.
+ Don't wrap all targets in LINK_LIBRARIES in a TARGET_NAME genex.
+ Generate new-style cmake code during export.
+ Store includes from the same include_directories call together.
+ Only output includes once after the start of 'generate-time' when debugging.
+ Specify the target whose includes are being listed.
+ Output include directories as LOG messages, not warnings.
+ Revert "Allow target_link_libraries with IMPORTED targets."
+ Disallow porcelain to populate includes and defines of IMPORTED targets.
+ Exclude the LINK_LIBRARIES related properties from INTERFACE evaluation.
+ Make calculation of link-interface-dependent properties type-sensitive.
+ Add the COMPATIBLE_INTERFACE_STRING property.
+ Move GetCompileDefinitions to cmTarget.
+ Process COMPILE_DEFINITIONS as generator expressions in QtAutomoc.
+ Generate the _IMPORT_PREFIX in the non-config export file.
+ Add the INSTALL_PREFIX genex.
+ Fix TARGET_PROPERTY target extractions.
+ Make the Property name protected so that subclasses can use it.
+ Don't allow targets args in the new target commands.
+ Make subclasses responsible for joining content.
+ Use the result of converting to a unix path.
+ Handle reading empty properties defined by the link interface.
+ Advance more when preprocessing exported strings.
+ Make it an error for INSTALL_PREFIX to be evaluated.
+ Export targets to a targets file, not a Config file.
+ Add a way to exclude INTERFACE properties from exported targets.
+ Add API to check if we're reading a includes or defines property.
+ Add the $<LINKED:...> generator expression.
+ Add includes and compile definitions with target_link_libraries.
+ Test workaround of bad interface include directories from depends.
+ Optimize genex evaluation for includes and defines.
+ Cache context-independent includes on evaluation.
+ Style: Use this-> when invoking member functions.
+ Process generator expressions for 'system' include directories.
+ Deduplicate the isGeneratorExpression method.
+ De-duplicate validation of genex target names.
+ Test printing origin of include dirs from tll().
+ The COMPATIBLE_INTERFACE does not affect the target it is set on.
+ Ensure type specific compatible interface properties do not intersect.
+ Fix generation of COMPILE_DEFINITIONS in DependInfo.cmake.
+ Fix determination of evaluating link libraries.
+ Only use early evaluation termination for transitive properties.
+ Move a special case for PIC from the genex to the cmTarget code.
+ Don't keep track of content determined by target property values.
+ Only append build interface include dirs to particular targets.
+ Ensure that the build interface includes have been added.
+ Whitelist target types in target_{include_directories,compile_definitions}
+ Make sure INTERFACE properties work with OBJECT libraries.
+ Don't allow utility or global targets in the LINKED expression.
+ Generate config-specific interface link libraries propeties.
+ Fix determination of when we're evaluating compile definitions.
+ Rename the IncludeDirectoriesEntry to be more generic.
+ Don't use LINKED where not needed.
+ Use the link information as a source of compile definitions and includes.
+ Revert "Don't allow utility or global targets in the LINKED expression."
+ Don't populate INTERFACE includes and defines properties in tll.
+ Revert "Add the $<LINKED:...> generator expression."
+ Revert "find_package: Reword <package>_NO_INTERFACES documentation"
+ Revert "Add a way to exclude INTERFACE properties from exported targets."
+ Don't add target-specific interface includes and defines to Qt 4 targets.
+ Fix GenerateExportHeader documentation #13936
+ automoc: Add source file to target early to set the linker language
+ Keep track of all targets seen while evaluating a genex.
+ Add a new Export generator for IMPORTED targets.
+ Handle targets in the LINK_LIBRARIES of try_compile.
+ Strip stray semicolons when evaluating generator expressions.
+ Workaround broken code where a target has itself in its link iface.
+ Fix DAG checker finding cycling dependencies.
+ Expand includes and defines transitively in 'external' genexes.
+ Fix constness of accessors.
+ Fix the tests for evaluating includes and defines.
+ Memoize includes and defines from interface libraries.
+ Remove use of TARGET_DEFINED from target_include_directories test.
+ Remove use of TARGET_DEFINED from the ExportImport test.
+ Remove use of TARGET_DEFINED from the target_link_libraries test.
+ Revert "Add the TARGET_DEFINED generator expression"
+ Only add existing targets to the Qt4 target depends properties.
+ Fix the cmGeneratorExpression::Split when leading chars are present.
+ Fix RPATH information when only a genex is used as a link library.
+ Mention that IMPORTED targets may be created by a find_package call.
+ Remove unused parameters from target_link_libraries tests.
+ Only process transitive interface properties for valid target names.
+ Restore support for target names with '+' (#13986)
+ Automoc: Don't create automoc targets if Qt is not used (#13999)
+ cmake-gui: Use -fPIE if required by Qt.
+ cmake-gui: Workaround bug in Qt 5.0.0 to 5.0.3 QStandardItemModel
+
+Thomas Klausner (1):
+ KWIML: Teach ABI.h that VAX is big endian
+
+Yury G. Kudryashov (3):
+ Automoc: Fix automoc for OBJECT libraries.
+ Automoc: add OBJECT library to QtAutomoc test
+ spell: fix a few typos in comments
+
Changes in CMake 2.8.10.2 (since 2.8.10.1)
----------------------------------------------
Alex Neundorf (1):
diff --git a/Modules/ExternalData.cmake b/Modules/ExternalData.cmake
index 187f408..8332725 100644
--- a/Modules/ExternalData.cmake
+++ b/Modules/ExternalData.cmake
@@ -551,7 +551,10 @@
set(relname "${entry}")
set(alg "")
endif()
- if("x${relname}" MATCHES "^x${regex}$" AND NOT IS_DIRECTORY "${top_src}/${entry}")
+ if("x${relname}" MATCHES "^x${regex}$" # matches
+ AND NOT IS_DIRECTORY "${top_src}/${entry}" # not a directory
+ AND NOT "x${relname}" MATCHES "(^x|/)\\.ExternalData_" # not staged obj
+ )
set(name "${top_src}/${relname}")
set(file "${top_bin}/${relname}")
if(alg)
diff --git a/Modules/FindBoost.cmake b/Modules/FindBoost.cmake
index 8d8b10c..0a9ffc1 100644
--- a/Modules/FindBoost.cmake
+++ b/Modules/FindBoost.cmake
@@ -928,9 +928,13 @@
message(STATUS "[ ${CMAKE_CURRENT_LIST_FILE}:${CMAKE_CURRENT_LIST_LINE} ] "
"Searching for ${UPPERCOMPONENT}_LIBRARY_RELEASE: ${_boost_RELEASE_NAMES}")
endif()
+
+ # Avoid passing backslashes to _Boost_FIND_LIBRARY due to macro re-parsing.
+ string(REPLACE "\\" "/" _boost_LIBRARY_SEARCH_DIRS_tmp "${_boost_LIBRARY_SEARCH_DIRS}")
+
_Boost_FIND_LIBRARY(Boost_${UPPERCOMPONENT}_LIBRARY_RELEASE
NAMES ${_boost_RELEASE_NAMES}
- HINTS ${_boost_LIBRARY_SEARCH_DIRS}
+ HINTS ${_boost_LIBRARY_SEARCH_DIRS_tmp}
NAMES_PER_DIR
DOC "${_boost_docstring_release}"
)
@@ -960,9 +964,13 @@
message(STATUS "[ ${CMAKE_CURRENT_LIST_FILE}:${CMAKE_CURRENT_LIST_LINE} ] "
"Searching for ${UPPERCOMPONENT}_LIBRARY_DEBUG: ${_boost_DEBUG_NAMES}")
endif()
+
+ # Avoid passing backslashes to _Boost_FIND_LIBRARY due to macro re-parsing.
+ string(REPLACE "\\" "/" _boost_LIBRARY_SEARCH_DIRS_tmp "${_boost_LIBRARY_SEARCH_DIRS}")
+
_Boost_FIND_LIBRARY(Boost_${UPPERCOMPONENT}_LIBRARY_DEBUG
NAMES ${_boost_DEBUG_NAMES}
- HINTS ${_boost_LIBRARY_SEARCH_DIRS}
+ HINTS ${_boost_LIBRARY_SEARCH_DIRS_tmp}
NAMES_PER_DIR
DOC "${_boost_docstring_debug}"
)
diff --git a/Modules/FindQt4.cmake b/Modules/FindQt4.cmake
index 21e8e91..4c05cc0 100644
--- a/Modules/FindQt4.cmake
+++ b/Modules/FindQt4.cmake
@@ -881,16 +881,20 @@
endforeach()
if(Q_WS_WIN)
- set(QT_MODULES ${QT_MODULES} QAxContainer QAxServer)
- # 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
- )
+ 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()
endif()
# Set QT_QTDESIGNERCOMPONENTS_INCLUDE_DIR
@@ -1051,14 +1055,18 @@
if(Q_WS_WIN)
_QT4_ADJUST_LIB_VARS(qtmain)
- _QT4_ADJUST_LIB_VARS(QAxServer)
- set_property(TARGET Qt4::QAxServer PROPERTY
- INTERFACE_QT4_NO_LINK_QTMAIN ON
- )
- set_property(TARGET Qt4::QAxServer APPEND PROPERTY
- COMPATIBLE_INTERFACE_BOOL QT4_NO_LINK_QTMAIN)
+ if(QT_QAXSERVER_FOUND)
+ _QT4_ADJUST_LIB_VARS(QAxServer)
+ set_property(TARGET Qt4::QAxServer PROPERTY
+ INTERFACE_QT4_NO_LINK_QTMAIN ON
+ )
+ set_property(TARGET Qt4::QAxServer APPEND PROPERTY
+ COMPATIBLE_INTERFACE_BOOL QT4_NO_LINK_QTMAIN)
+ endif()
- _QT4_ADJUST_LIB_VARS(QAxContainer)
+ if(QT_QAXCONTAINER_FOUND)
+ _QT4_ADJUST_LIB_VARS(QAxContainer)
+ endif()
endif()
# Only public dependencies are listed here.
@@ -1080,7 +1088,9 @@
_qt4_add_target_depends(QtWebKit Gui Network)
_qt4_add_target_private_depends(Qt3Support Xml)
- _qt4_add_target_private_depends(QtSvg Xml)
+ if(QT_VERSION VERSION_GREATER 4.6)
+ _qt4_add_target_private_depends(QtSvg Xml)
+ endif()
_qt4_add_target_private_depends(QtDBus Xml)
_qt4_add_target_private_depends(QtUiTools Xml Gui)
_qt4_add_target_private_depends(QtHelp Sql Xml Network)
@@ -1090,8 +1100,12 @@
_qt4_add_target_private_depends(QtDeclarative XmlPatterns Svg Sql Gui)
_qt4_add_target_private_depends(QtMultimedia Gui)
_qt4_add_target_private_depends(QtOpenGL Gui)
- _qt4_add_target_private_depends(QAxServer Gui)
- _qt4_add_target_private_depends(QAxContainer Gui)
+ if(QT_QAXSERVER_FOUND)
+ _qt4_add_target_private_depends(QAxServer Gui)
+ endif()
+ if(QT_QAXCONTAINER_FOUND)
+ _qt4_add_target_private_depends(QAxContainer Gui)
+ endif()
_qt4_add_target_private_depends(phonon Gui)
if(QT_QTDBUS_FOUND)
_qt4_add_target_private_depends(phonon DBus)
diff --git a/Modules/Qt4Macros.cmake b/Modules/Qt4Macros.cmake
index 251d57c..f6c8476 100644
--- a/Modules/Qt4Macros.cmake
+++ b/Modules/Qt4Macros.cmake
@@ -451,14 +451,22 @@
endif()
foreach(_module ${modules})
string(TOUPPER ${_module} _ucmodule)
- if (NOT QT_QT${_ucmodule}_FOUND)
- message(FATAL_ERROR "Can not use \"${_module}\" module which has not yet been found.")
+ set(_targetPrefix QT_QT${_ucmodule})
+ if (_ucmodule STREQUAL QAXCONTAINER OR _ucmodule STREQUAL QAXSERVER)
+ if (NOT QT_Q${_ucmodule}_FOUND)
+ message(FATAL_ERROR "Can not use \"${_module}\" module which has not yet been found.")
+ endif()
+ set(_targetPrefix QT_Q${_ucmodule})
+ else()
+ if (NOT QT_QT${_ucmodule}_FOUND)
+ message(FATAL_ERROR "Can not use \"${_module}\" module which has not yet been found.")
+ endif()
+ if ("${_ucmodule}" STREQUAL "MAIN")
+ message(FATAL_ERROR "Can not use \"${_module}\" module with qt4_use_modules.")
+ endif()
endif()
- if ("${_ucmodule}" STREQUAL "MAIN")
- message(FATAL_ERROR "Can not use \"${_module}\" module with qt4_use_modules.")
- endif()
- target_link_libraries(${_target} ${link_type} ${QT_QT${_ucmodule}_LIBRARY})
- set_property(TARGET ${_target} APPEND PROPERTY INCLUDE_DIRECTORIES ${QT_QT${_ucmodule}_INCLUDE_DIR} ${QT_HEADERS_DIR} ${QT_MKSPECS_DIR}/default)
- set_property(TARGET ${_target} APPEND PROPERTY COMPILE_DEFINITIONS ${QT_QT${_ucmodule}_COMPILE_DEFINITIONS})
+ target_link_libraries(${_target} ${link_type} ${${_targetPrefix}_LIBRARIES})
+ set_property(TARGET ${_target} APPEND PROPERTY INCLUDE_DIRECTORIES ${${_targetPrefix}_INCLUDE_DIR} ${QT_HEADERS_DIR} ${QT_MKSPECS_DIR}/default)
+ set_property(TARGET ${_target} APPEND PROPERTY COMPILE_DEFINITIONS ${${_targetPrefix}_COMPILE_DEFINITIONS})
endforeach()
endfunction()
diff --git a/Source/CMakeVersion.cmake b/Source/CMakeVersion.cmake
index 6d793b4..f2792d6 100644
--- a/Source/CMakeVersion.cmake
+++ b/Source/CMakeVersion.cmake
@@ -1,6 +1,6 @@
# CMake version number components.
set(CMake_VERSION_MAJOR 2)
set(CMake_VERSION_MINOR 8)
-set(CMake_VERSION_PATCH 10)
-set(CMake_VERSION_TWEAK 20130515)
-#set(CMake_VERSION_RC 1)
+set(CMake_VERSION_PATCH 11)
+set(CMake_VERSION_TWEAK 0)
+#set(CMake_VERSION_RC 0)
diff --git a/Source/cmCoreTryCompile.cxx b/Source/cmCoreTryCompile.cxx
index 9f38b25..85e49a9 100644
--- a/Source/cmCoreTryCompile.cxx
+++ b/Source/cmCoreTryCompile.cxx
@@ -111,7 +111,7 @@
++i)
{
extraArgs++;
- libsToLink += argv[i] + " ";
+ libsToLink += "\"" + cmSystemTools::TrimWhitespace(argv[i]) + "\" ";
cmTarget *tgt = this->Makefile->FindTargetToUse(argv[i].c_str());
if (!tgt)
{
diff --git a/Source/cmGlobalXCodeGenerator.cxx b/Source/cmGlobalXCodeGenerator.cxx
index ceac564..3092abf 100644
--- a/Source/cmGlobalXCodeGenerator.cxx
+++ b/Source/cmGlobalXCodeGenerator.cxx
@@ -2028,20 +2028,16 @@
dirs.Add(incpath.c_str());
}
}
- if(target.GetType() != cmTarget::OBJECT_LIBRARY &&
- target.GetType() != cmTarget::STATIC_LIBRARY)
+ // Add framework search paths needed for linking.
+ if(cmComputeLinkInformation* cli = target.GetLinkInformation(configName))
{
- // Add framework search paths needed for linking.
- if(cmComputeLinkInformation* cli = target.GetLinkInformation(configName))
+ std::vector<std::string> const& fwDirs = cli->GetFrameworkPaths();
+ for(std::vector<std::string>::const_iterator fdi = fwDirs.begin();
+ fdi != fwDirs.end(); ++fdi)
{
- std::vector<std::string> const& fwDirs = cli->GetFrameworkPaths();
- for(std::vector<std::string>::const_iterator fdi = fwDirs.begin();
- fdi != fwDirs.end(); ++fdi)
+ if(emitted.insert(*fdi).second)
{
- if(emitted.insert(*fdi).second)
- {
- fdirs.Add(this->XCodeEscapePath(fdi->c_str()).c_str());
- }
+ fdirs.Add(this->XCodeEscapePath(fdi->c_str()).c_str());
}
}
}
diff --git a/Source/cmIncludeDirectoryCommand.cxx b/Source/cmIncludeDirectoryCommand.cxx
index ffb0e80..30c1743 100644
--- a/Source/cmIncludeDirectoryCommand.cxx
+++ b/Source/cmIncludeDirectoryCommand.cxx
@@ -116,13 +116,19 @@
{
std::string inc = arg.substr(lastPos,pos);
this->NormalizeInclude(inc);
- incs.push_back(inc);
+ if (!inc.empty())
+ {
+ incs.push_back(inc);
+ }
}
lastPos = pos + 1;
}
std::string inc = arg.substr(lastPos);
this->NormalizeInclude(inc);
- incs.push_back(inc);
+ if (!inc.empty())
+ {
+ incs.push_back(inc);
+ }
}
void cmIncludeDirectoryCommand::NormalizeInclude(std::string &inc)
@@ -133,6 +139,11 @@
{
inc.assign(inc, b, 1+e-b); // copy the remaining substring
}
+ else
+ {
+ inc = "";
+ return;
+ }
if (!cmSystemTools::IsOff(inc.c_str()))
{
diff --git a/Source/kwsys/SystemTools.cxx b/Source/kwsys/SystemTools.cxx
index 22bf193..8b25d60 100644
--- a/Source/kwsys/SystemTools.cxx
+++ b/Source/kwsys/SystemTools.cxx
@@ -2742,14 +2742,23 @@
}
// Remove any trailing slash from the name.
- char buffer[KWSYS_SYSTEMTOOLS_MAXPATH];
+ char local_buffer[KWSYS_SYSTEMTOOLS_MAXPATH];
+ std::string string_buffer;
size_t last = length-1;
if(last > 0 && (name[last] == '/' || name[last] == '\\')
&& strcmp(name, "/") !=0)
{
- memcpy(buffer, name, last);
- buffer[last] = 0;
- name = buffer;
+ if(last < sizeof(local_buffer))
+ {
+ memcpy(local_buffer, name, last);
+ local_buffer[last] = 0;
+ name = local_buffer;
+ }
+ else
+ {
+ string_buffer.append(name, last);
+ name = string_buffer.c_str();
+ }
}
// Now check the file node type.
diff --git a/Tests/CMakeLists.txt b/Tests/CMakeLists.txt
index e07bb69..44e9450 100644
--- a/Tests/CMakeLists.txt
+++ b/Tests/CMakeLists.txt
@@ -15,10 +15,7 @@
list(APPEND TEST_BUILD_DIRS "${CMake_BINARY_DIR}/Tests/${dir}")
endmacro()
-macro(REGEX_ESCAPE_STRING _OUT _IN)
- # Escape special regex metacharacters with a backslash
- string(REGEX REPLACE "([$^.[|*+?()]|])" "\\\\\\1" ${_OUT} "${_IN}")
-endmacro()
+include(${CMAKE_CURRENT_SOURCE_DIR}/RegexEscapeString.cmake)
include(${CMAKE_CURRENT_SOURCE_DIR}/CheckFortran.cmake)
diff --git a/Tests/CMakeTests/GetPropertyTest.cmake.in b/Tests/CMakeTests/GetPropertyTest.cmake.in
index 306ab72..a858418 100644
--- a/Tests/CMakeTests/GetPropertyTest.cmake.in
+++ b/Tests/CMakeTests/GetPropertyTest.cmake.in
@@ -28,92 +28,95 @@
message(SEND_ERROR "bad value of VARIABLE PROPERTY test_var: got '${result}' instead of 'alpha'")
endif()
+include("@CMAKE_CURRENT_SOURCE_DIR@/../RegexEscapeString.cmake")
+REGEX_ESCAPE_STRING(CTEST_ESCAPED_CMAKE_CURRENT_SOURCE_DIR "@CMAKE_CURRENT_SOURCE_DIR@")
+
set(Missing-Argument-RESULT 1)
-set(Missing-Argument-STDERR ".*CMake Error at (@CMAKE_CURRENT_SOURCE_DIR@/)?GetProperty-Missing-Argument.cmake:1 \\(get_property\\):.*get_property called with incorrect number of arguments.*")
+set(Missing-Argument-STDERR ".*CMake Error at (${CTEST_ESCAPED_CMAKE_CURRENT_SOURCE_DIR}/)?GetProperty-Missing-Argument.cmake:1 \\(get_property\\):.*get_property called with incorrect number of arguments.*")
check_cmake_test(GetProperty
Missing-Argument
)
set(Bad-Scope-RESULT 1)
-set(Bad-Scope-STDERR ".*CMake Error at (@CMAKE_CURRENT_SOURCE_DIR@/)?GetProperty-Bad-Scope.cmake:1 \\(get_property\\):.*get_property given invalid scope FOO\\..*")
+set(Bad-Scope-STDERR ".*CMake Error at (${CTEST_ESCAPED_CMAKE_CURRENT_SOURCE_DIR}/)?GetProperty-Bad-Scope.cmake:1 \\(get_property\\):.*get_property given invalid scope FOO\\..*")
check_cmake_test(GetProperty
Bad-Scope
)
set(Bad-Argument-RESULT 1)
-set(Bad-Argument-STDERR ".*CMake Error at (@CMAKE_CURRENT_SOURCE_DIR@/)?GetProperty-Bad-Argument.cmake:1 \\(get_property\\):.*get_property given invalid argument \"FOO\"\\..*")
+set(Bad-Argument-STDERR ".*CMake Error at (${CTEST_ESCAPED_CMAKE_CURRENT_SOURCE_DIR}/)?GetProperty-Bad-Argument.cmake:1 \\(get_property\\):.*get_property given invalid argument \"FOO\"\\..*")
check_cmake_test(GetProperty
Bad-Argument
)
set(No-Property-RESULT 1)
-set(No-Property-STDERR ".*CMake Error at (@CMAKE_CURRENT_SOURCE_DIR@/)?GetProperty-No-Property.cmake:1 \\(get_property\\):.*get_property not given a PROPERTY <name> argument\\..*")
+set(No-Property-STDERR ".*CMake Error at (${CTEST_ESCAPED_CMAKE_CURRENT_SOURCE_DIR}/)?GetProperty-No-Property.cmake:1 \\(get_property\\):.*get_property not given a PROPERTY <name> argument\\..*")
check_cmake_test(GetProperty
No-Property
)
set(Global-Name-RESULT 1)
-set(Global-Name-STDERR ".*CMake Error at (@CMAKE_CURRENT_SOURCE_DIR@/)?GetProperty-Global-Name.cmake:1 \\(get_property\\):.*get_property given name for GLOBAL scope\\..*")
+set(Global-Name-STDERR ".*CMake Error at (${CTEST_ESCAPED_CMAKE_CURRENT_SOURCE_DIR}/)?GetProperty-Global-Name.cmake:1 \\(get_property\\):.*get_property given name for GLOBAL scope\\..*")
check_cmake_test(GetProperty
Global-Name
)
set(Bad-Directory-RESULT 1)
-set(Bad-Directory-STDERR ".*CMake Error at (@CMAKE_CURRENT_SOURCE_DIR@/)?GetProperty-Bad-Directory.cmake:1 \\(get_property\\):.*get_property DIRECTORY scope provided but requested directory was not.*found\\..*")
+set(Bad-Directory-STDERR ".*CMake Error at (${CTEST_ESCAPED_CMAKE_CURRENT_SOURCE_DIR}/)?GetProperty-Bad-Directory.cmake:1 \\(get_property\\):.*get_property DIRECTORY scope provided but requested directory was not.*found\\..*")
check_cmake_test(GetProperty
Bad-Directory
)
set(No-Target-RESULT 1)
-set(No-Target-STDERR ".*CMake Error at (@CMAKE_CURRENT_SOURCE_DIR@/)?GetProperty-No-Target.cmake:1 \\(get_property\\):.*get_property not given name for TARGET scope\\..*")
+set(No-Target-STDERR ".*CMake Error at (${CTEST_ESCAPED_CMAKE_CURRENT_SOURCE_DIR}/)?GetProperty-No-Target.cmake:1 \\(get_property\\):.*get_property not given name for TARGET scope\\..*")
check_cmake_test(GetProperty
No-Target
)
set(Bad-Target-RESULT 1)
-set(Bad-Target-STDERR ".*CMake Error at (@CMAKE_CURRENT_SOURCE_DIR@/)?GetProperty-Bad-Target.cmake:1 \\(get_property\\):.*get_property could not find TARGET FOO\\..*")
+set(Bad-Target-STDERR ".*CMake Error at (${CTEST_ESCAPED_CMAKE_CURRENT_SOURCE_DIR}/)?GetProperty-Bad-Target.cmake:1 \\(get_property\\):.*get_property could not find TARGET FOO\\..*")
check_cmake_test(GetProperty
Bad-Target
)
set(No-Source-RESULT 1)
-set(No-Source-STDERR ".*CMake Error at (@CMAKE_CURRENT_SOURCE_DIR@/)?GetProperty-No-Source.cmake:1 \\(get_property\\):.*get_property not given name for SOURCE scope\\..*")
+set(No-Source-STDERR ".*CMake Error at (${CTEST_ESCAPED_CMAKE_CURRENT_SOURCE_DIR}/)?GetProperty-No-Source.cmake:1 \\(get_property\\):.*get_property not given name for SOURCE scope\\..*")
check_cmake_test(GetProperty
No-Source
)
set(No-Test-RESULT 1)
-set(No-Test-STDERR ".*CMake Error at (@CMAKE_CURRENT_SOURCE_DIR@/)?GetProperty-No-Test.cmake:1 \\(get_property\\):.*get_property not given name for TEST scope\\..*")
+set(No-Test-STDERR ".*CMake Error at (${CTEST_ESCAPED_CMAKE_CURRENT_SOURCE_DIR}/)?GetProperty-No-Test.cmake:1 \\(get_property\\):.*get_property not given name for TEST scope\\..*")
check_cmake_test(GetProperty
No-Test
)
set(Bad-Test-RESULT 1)
-set(Bad-Test-STDERR ".*CMake Error at (@CMAKE_CURRENT_SOURCE_DIR@/)?GetProperty-Bad-Test.cmake:1 \\(get_property\\):.*get_property given TEST name that does not exist: FOO.*")
+set(Bad-Test-STDERR ".*CMake Error at (${CTEST_ESCAPED_CMAKE_CURRENT_SOURCE_DIR}/)?GetProperty-Bad-Test.cmake:1 \\(get_property\\):.*get_property given TEST name that does not exist: FOO.*")
check_cmake_test(GetProperty
Bad-Test
)
set(Variable-Name-RESULT 1)
-set(Variable-Name-STDERR ".*CMake Error at (@CMAKE_CURRENT_SOURCE_DIR@/)?GetProperty-Variable-Name.cmake:1 \\(get_property\\):.*get_property given name for VARIABLE scope\\..*")
+set(Variable-Name-STDERR ".*CMake Error at (${CTEST_ESCAPED_CMAKE_CURRENT_SOURCE_DIR}/)?GetProperty-Variable-Name.cmake:1 \\(get_property\\):.*get_property given name for VARIABLE scope\\..*")
check_cmake_test(GetProperty
Variable-Name
)
set(No-Cache-RESULT 1)
-set(No-Cache-STDERR ".*CMake Error at (@CMAKE_CURRENT_SOURCE_DIR@/)?GetProperty-No-Cache.cmake:1 \\(get_property\\):.*get_property not given name for CACHE scope\\..*")
+set(No-Cache-STDERR ".*CMake Error at (${CTEST_ESCAPED_CMAKE_CURRENT_SOURCE_DIR}/)?GetProperty-No-Cache.cmake:1 \\(get_property\\):.*get_property not given name for CACHE scope\\..*")
check_cmake_test(GetProperty
No-Cache
diff --git a/Tests/CMakeTests/IfTest.cmake.in b/Tests/CMakeTests/IfTest.cmake.in
index 639e226..74b8e32 100644
--- a/Tests/CMakeTests/IfTest.cmake.in
+++ b/Tests/CMakeTests/IfTest.cmake.in
@@ -7,6 +7,9 @@
set(VAR_${_arg} "${_arg}")
endforeach()
+include("@CMAKE_CURRENT_SOURCE_DIR@/../RegexEscapeString.cmake")
+REGEX_ESCAPE_STRING(CTEST_ESCAPED_CMAKE_CURRENT_SOURCE_DIR "@CMAKE_CURRENT_SOURCE_DIR@")
+
macro(test_vars _old)
# Variables set to false or not set.
foreach(_var "" 0 ${FALSE_NAMES} UNDEFINED)
@@ -158,7 +161,7 @@
test_vars("")
set(Invalid-Argument-RESULT 1)
-set(Invalid-Argument-STDERR ".*CMake Error at (@CMAKE_CURRENT_SOURCE_DIR@/)?If-Invalid-Argument.cmake:1 \\(if\\):.*Unknown arguments specified.*")
+set(Invalid-Argument-STDERR ".*CMake Error at (${CTEST_ESCAPED_CMAKE_CURRENT_SOURCE_DIR}/)?If-Invalid-Argument.cmake:1 \\(if\\):.*Unknown arguments specified.*")
include("@CMAKE_CURRENT_SOURCE_DIR@/CheckCMakeTest.cmake")
check_cmake_test(If
diff --git a/Tests/CMakeTests/ListTest.cmake.in b/Tests/CMakeTests/ListTest.cmake.in
index f0ed70f..77c34a9 100644
--- a/Tests/CMakeTests/ListTest.cmake.in
+++ b/Tests/CMakeTests/ListTest.cmake.in
@@ -1,5 +1,8 @@
include("@CMAKE_CURRENT_SOURCE_DIR@/CheckCMakeTest.cmake")
+include("@CMAKE_CURRENT_SOURCE_DIR@/../RegexEscapeString.cmake")
+REGEX_ESCAPE_STRING(CTEST_ESCAPED_CMAKE_CURRENT_SOURCE_DIR "@CMAKE_CURRENT_SOURCE_DIR@")
+
macro(TEST command expected)
if("x${result}" STREQUAL "x${expected}")
#message("TEST \"${command}\" success: \"${result}\" expected: \"${expected}\"")
@@ -101,7 +104,7 @@
TEST("SORT empty result" "")
set(No-Arguments-RESULT 1)
-set(No-Arguments-STDERR ".*CMake Error at (@CMAKE_CURRENT_SOURCE_DIR@/)?List-No-Arguments.cmake:1 \\(list\\):.*list must be called with at least two arguments.*")
+set(No-Arguments-STDERR ".*CMake Error at (${CTEST_ESCAPED_CMAKE_CURRENT_SOURCE_DIR}/)?List-No-Arguments.cmake:1 \\(list\\):.*list must be called with at least two arguments.*")
# these trigger top-level condition
foreach(cmd IN ITEMS Append Find Get Insert Length Reverse Remove_At Remove_Duplicates Remove_Item Sort)
@@ -130,33 +133,33 @@
endforeach()
set(Length-Too-Many-Arguments-RESULT 1)
-set(Length-Too-Many-Arguments-STDERR ".*CMake Error at (@CMAKE_CURRENT_SOURCE_DIR@/)?List-Length-Too-Many-Arguments.cmake:1 \\(list\\):.*list sub-command LENGTH requires two arguments.*")
+set(Length-Too-Many-Arguments-STDERR ".*CMake Error at (${CTEST_ESCAPED_CMAKE_CURRENT_SOURCE_DIR}/)?List-Length-Too-Many-Arguments.cmake:1 \\(list\\):.*list sub-command LENGTH requires two arguments.*")
set(Reverse-Too-Many-Arguments-RESULT 1)
-set(Reverse-Too-Many-Arguments-STDERR ".*CMake Error at (@CMAKE_CURRENT_SOURCE_DIR@/)?List-Reverse-Too-Many-Arguments.cmake:1 \\(list\\):.*list sub-command REVERSE only takes one argument.*")
+set(Reverse-Too-Many-Arguments-STDERR ".*CMake Error at (${CTEST_ESCAPED_CMAKE_CURRENT_SOURCE_DIR}/)?List-Reverse-Too-Many-Arguments.cmake:1 \\(list\\):.*list sub-command REVERSE only takes one argument.*")
set(Remove_Duplicates-Too-Many-Arguments-RESULT 1)
-set(Remove_Duplicates-Too-Many-Arguments-STDERR ".*CMake Error at (@CMAKE_CURRENT_SOURCE_DIR@/)?List-Remove_Duplicates-Too-Many-Arguments.cmake:1 \\(list\\):.*list sub-command REMOVE_DUPLICATES only takes one argument.*")
+set(Remove_Duplicates-Too-Many-Arguments-STDERR ".*CMake Error at (${CTEST_ESCAPED_CMAKE_CURRENT_SOURCE_DIR}/)?List-Remove_Duplicates-Too-Many-Arguments.cmake:1 \\(list\\):.*list sub-command REMOVE_DUPLICATES only takes one argument.*")
set(Sort-Too-Many-Arguments-RESULT 1)
-set(Sort-Too-Many-Arguments-STDERR ".*CMake Error at (@CMAKE_CURRENT_SOURCE_DIR@/)?List-Sort-Too-Many-Arguments.cmake:1 \\(list\\):.*list sub-command SORT only takes one argument.*")
+set(Sort-Too-Many-Arguments-STDERR ".*CMake Error at (${CTEST_ESCAPED_CMAKE_CURRENT_SOURCE_DIR}/)?List-Sort-Too-Many-Arguments.cmake:1 \\(list\\):.*list sub-command SORT only takes one argument.*")
set(Invalid-Subcommand-RESULT 1)
-set(Invalid-Subcommand-STDERR ".*CMake Error at (@CMAKE_CURRENT_SOURCE_DIR@/)?List-Invalid-Subcommand.cmake:1 \\(list\\):.*list does not recognize sub-command NO_SUCH_SUBCOMMAND.*")
+set(Invalid-Subcommand-STDERR ".*CMake Error at (${CTEST_ESCAPED_CMAKE_CURRENT_SOURCE_DIR}/)?List-Invalid-Subcommand.cmake:1 \\(list\\):.*list does not recognize sub-command NO_SUCH_SUBCOMMAND.*")
foreach(cmd Get Insert Remove_At)
set(${cmd}-Invalid-Index-RESULT 1)
- set(${cmd}-Invalid-Index-STDERR ".*CMake Error at (@CMAKE_CURRENT_SOURCE_DIR@/)?List-${cmd}-Invalid-Index.cmake:2 \\(list\\):.*list index: 3 out of range \\(-3, 2\\).*")
+ set(${cmd}-Invalid-Index-STDERR ".*CMake Error at (${CTEST_ESCAPED_CMAKE_CURRENT_SOURCE_DIR}/)?List-${cmd}-Invalid-Index.cmake:2 \\(list\\):.*list index: 3 out of range \\(-3, 2\\).*")
endforeach()
foreach(cmd Remove_Item Reverse Remove_Duplicates Sort Remove_At)
string(TOUPPER ${cmd} Cmd)
set(${cmd}-Nonexistent-List-RESULT 1)
- set(${cmd}-Nonexistent-List-STDERR ".*CMake Error at (@CMAKE_CURRENT_SOURCE_DIR@/)?List-${cmd}-Nonexistent-List.cmake:2 \\(list\\):.*sub-command ${Cmd} requires list to be present.*")
+ set(${cmd}-Nonexistent-List-STDERR ".*CMake Error at (${CTEST_ESCAPED_CMAKE_CURRENT_SOURCE_DIR}/)?List-${cmd}-Nonexistent-List.cmake:2 \\(list\\):.*sub-command ${Cmd} requires list to be present.*")
endforeach()
set(Get-CMP0007-Warn-RESULT 0)
-set(Get-CMP0007-Warn-STDERR ".*CMake Warning \\(dev\\) at (@CMAKE_CURRENT_SOURCE_DIR@/)?List-Get-CMP0007-Warn.cmake:3 \\(list\\):.*Policy CMP0007 is not set:.*")
+set(Get-CMP0007-Warn-STDERR ".*CMake Warning \\(dev\\) at (${CTEST_ESCAPED_CMAKE_CURRENT_SOURCE_DIR}/)?List-Get-CMP0007-Warn.cmake:3 \\(list\\):.*Policy CMP0007 is not set:.*")
check_cmake_test(List
No-Arguments
diff --git a/Tests/CMakeTests/WhileTest.cmake.in b/Tests/CMakeTests/WhileTest.cmake.in
index 4cec291..d4cf7d7 100644
--- a/Tests/CMakeTests/WhileTest.cmake.in
+++ b/Tests/CMakeTests/WhileTest.cmake.in
@@ -1,6 +1,9 @@
set(NUMBERS "")
set(COUNT 0)
+include("@CMAKE_CURRENT_SOURCE_DIR@/../RegexEscapeString.cmake")
+REGEX_ESCAPE_STRING(CTEST_ESCAPED_CMAKE_CURRENT_SOURCE_DIR "@CMAKE_CURRENT_SOURCE_DIR@")
+
while(COUNT LESS 200)
set(NUMBERS "${NUMBERS} ${COUNT}")
set(COUNT "2${COUNT}")
@@ -16,8 +19,9 @@
message(SEND_ERROR "while loop nesting error, result: '${NUMBERS}'")
endif()
+
set(Missing-Argument-RESULT 1)
-set(Missing-Argument-STDERR ".*CMake Error at (@CMAKE_CURRENT_SOURCE_DIR@/)?While-Missing-Argument.cmake:1 \\(while\\):.*while called with incorrect number of arguments.*")
+set(Missing-Argument-STDERR ".*CMake Error at (${CTEST_ESCAPED_CMAKE_CURRENT_SOURCE_DIR}/)?While-Missing-Argument.cmake:1 \\(while\\):.*while called with incorrect number of arguments.*")
include("@CMAKE_CURRENT_SOURCE_DIR@/CheckCMakeTest.cmake")
check_cmake_test(While
@@ -25,28 +29,28 @@
)
set(Missing-Endwhile-RESULT 1)
-set(Missing-Endwhile-STDERR ".*CMake Error in (@CMAKE_CURRENT_SOURCE_DIR@/)?While-Missing-Endwhile.cmake:.*A logical block opening on the line.*(@CMAKE_CURRENT_SOURCE_DIR@/)?While-Missing-Endwhile.cmake:1 \\(while\\).*is not closed\\..*")
+set(Missing-Endwhile-STDERR ".*CMake Error in (${CTEST_ESCAPED_CMAKE_CURRENT_SOURCE_DIR}/)?While-Missing-Endwhile.cmake:.*A logical block opening on the line.*(${CTEST_ESCAPED_CMAKE_CURRENT_SOURCE_DIR}/)?While-Missing-Endwhile.cmake:1 \\(while\\).*is not closed\\..*")
check_cmake_test(While
Missing-Endwhile
)
set(Endwhile-Mismatch-RESULT 0)
-set(Endwhile-Mismatch-STDERR ".*CMake Warning \\(dev\\) in (@CMAKE_CURRENT_SOURCE_DIR@/)?While-Endwhile-Mismatch.cmake:.*A logical block opening on the line.*(@CMAKE_CURRENT_SOURCE_DIR@/)?While-Endwhile-Mismatch.cmake:1 \\(while\\).*with mis-matching arguments\\..*")
+set(Endwhile-Mismatch-STDERR ".*CMake Warning \\(dev\\) in (${CTEST_ESCAPED_CMAKE_CURRENT_SOURCE_DIR}/)?While-Endwhile-Mismatch.cmake:.*A logical block opening on the line.*(${CTEST_ESCAPED_CMAKE_CURRENT_SOURCE_DIR}/)?While-Endwhile-Mismatch.cmake:1 \\(while\\).*with mis-matching arguments\\..*")
check_cmake_test(While
Endwhile-Mismatch
)
set(Endwhile-Alone-RESULT 1)
-set(Endwhile-Alone-STDERR ".*CMake Error at (@CMAKE_CURRENT_SOURCE_DIR@/)?While-Endwhile-Alone.cmake:1 \\(endwhile\\):.*An ENDWHILE command was found outside of a proper WHILE ENDWHILE.*structure\\.\n.*$")
+set(Endwhile-Alone-STDERR ".*CMake Error at (${CTEST_ESCAPED_CMAKE_CURRENT_SOURCE_DIR}/)?While-Endwhile-Alone.cmake:1 \\(endwhile\\):.*An ENDWHILE command was found outside of a proper WHILE ENDWHILE.*structure\\.\n.*$")
check_cmake_test(While
Endwhile-Alone
)
set(Endwhile-Alone-Args-RESULT 1)
-set(Endwhile-Alone-Args-STDERR ".*CMake Error at (@CMAKE_CURRENT_SOURCE_DIR@/)?While-Endwhile-Alone-Args.cmake:1 \\(endwhile\\):.*An ENDWHILE command was found outside of a proper WHILE ENDWHILE.*structure\\. Or its arguments did not.*$")
+set(Endwhile-Alone-Args-STDERR ".*CMake Error at (${CTEST_ESCAPED_CMAKE_CURRENT_SOURCE_DIR}/)?While-Endwhile-Alone-Args.cmake:1 \\(endwhile\\):.*An ENDWHILE command was found outside of a proper WHILE ENDWHILE.*structure\\. Or its arguments did not.*$")
check_cmake_test(While
Endwhile-Alone-Args
diff --git a/Tests/CTestTestMemcheck/CMakeLists.txt b/Tests/CTestTestMemcheck/CMakeLists.txt
index 2730a61..b5f758b 100644
--- a/Tests/CTestTestMemcheck/CMakeLists.txt
+++ b/Tests/CTestTestMemcheck/CMakeLists.txt
@@ -1,3 +1,5 @@
+REGEX_ESCAPE_STRING(CTEST_ESCAPED_CMAKE_CURRENT_BINARY_DIR "${CMAKE_CURRENT_BINARY_DIR}")
+
foreach (_retval 0 1)
file(WRITE "${CMAKE_CURRENT_BINARY_DIR}/ret${_retval}.c" "int main(){return ${_retval};}\n")
endforeach ()
@@ -49,7 +51,7 @@
foreach (_unkn Unknown UnknownQuoted)
set_tests_properties(CTestTestMemcheck${_unkn} PROPERTIES
- PASS_REGULAR_EXPRESSION "Do not understand memory checker: ${CMAKE_COMMAND_ESCAPED}\n(.*\n)?Error in read script: ${CMAKE_CURRENT_BINARY_DIR}/${_unkn}/test.cmake\n")
+ PASS_REGULAR_EXPRESSION "Do not understand memory checker: ${CMAKE_COMMAND_ESCAPED}\n(.*\n)?Error in read script: ${CTEST_ESCAPED_CMAKE_CURRENT_BINARY_DIR}/${_unkn}/test.cmake\n")
endforeach ()
set_tests_properties(CTestTestMemcheckNotExist PROPERTIES
@@ -67,7 +69,7 @@
string(TOLOWER ${_pp} _pp_lower)
set_tests_properties(CTestTestMemcheckDummyValgrindFail${_pp}
PROPERTIES
- PASS_REGULAR_EXPRESSION "\nProblem running command: ${CMAKE_CURRENT_BINARY_DIR}[^\n]*fail[^\n]*\n(.*\n)?Problem executing ${_pp_lower}-memcheck command\\(s\\\).\n(.*\n)?Error in read script: ${CMAKE_CURRENT_BINARY_DIR}/DummyValgrindFail${_pp}/test.cmake\n")
+ PASS_REGULAR_EXPRESSION "\nProblem running command: ${CTEST_ESCAPED_CMAKE_CURRENT_BINARY_DIR}[^\n]*fail[^\n]*\n(.*\n)?Problem executing ${_pp_lower}-memcheck command\\(s\\\).\n(.*\n)?Error in read script: ${CTEST_ESCAPED_CMAKE_CURRENT_BINARY_DIR}/DummyValgrindFail${_pp}/test.cmake\n")
endforeach ()
set_tests_properties(CTestTestMemcheckDummyValgrindIgnoreMemcheck
@@ -75,7 +77,7 @@
PASS_REGULAR_EXPRESSION "\n2/2 Test #2: RunCMakeAgain .*\n1/1 MemCheck #1: RunCMake .*${NORMAL_CTEST_OUTPUT}")
set_tests_properties(CTestTestMemcheckDummyPurify PROPERTIES
- PASS_REGULAR_EXPRESSION "\nCannot find memory tester output file: ${CMAKE_CURRENT_BINARY_DIR}/DummyPurify/Testing/Temporary/MemoryChecker.log\n(.*\n)?Error in read script: ${CMAKE_CURRENT_BINARY_DIR}/DummyPurify/test.cmake\n")
+ PASS_REGULAR_EXPRESSION "\nCannot find memory tester output file: ${CTEST_ESCAPED_CMAKE_CURRENT_BINARY_DIR}/DummyPurify/Testing/Temporary/MemoryChecker.log\n(.*\n)?Error in read script: ${CTEST_ESCAPED_CMAKE_CURRENT_BINARY_DIR}/DummyPurify/test.cmake\n")
set_tests_properties(CTestTestMemcheckDummyBC PROPERTIES
- PASS_REGULAR_EXPRESSION "\nCannot find memory tester output file: ${CMAKE_CURRENT_BINARY_DIR}/DummyBC/Testing/Temporary/MemoryChecker.log\n(.*\n)?Error parsing XML in stream at line 1: no element found\n(.*\n)?Error in read script: ${CMAKE_CURRENT_BINARY_DIR}/DummyBC/test.cmake\n")
+ PASS_REGULAR_EXPRESSION "\nCannot find memory tester output file: ${CTEST_ESCAPED_CMAKE_CURRENT_BINARY_DIR}/DummyBC/Testing/Temporary/MemoryChecker.log\n(.*\n)?Error parsing XML in stream at line 1: no element found\n(.*\n)?Error in read script: ${CTEST_ESCAPED_CMAKE_CURRENT_BINARY_DIR}/DummyBC/test.cmake\n")
diff --git a/Tests/IncludeDirectories/CMakeLists.txt b/Tests/IncludeDirectories/CMakeLists.txt
index 8a60f17..3e3ecc9 100644
--- a/Tests/IncludeDirectories/CMakeLists.txt
+++ b/Tests/IncludeDirectories/CMakeLists.txt
@@ -58,3 +58,14 @@
if (NOT propContentAfter STREQUAL "")
message(SEND_ERROR "Clearing DIRECTORY property failed.")
endif()
+
+add_library(empty_entry_test SHARED empty.cpp)
+set_target_properties(empty_entry_test PROPERTIES INCLUDE_DIRECTORIES "")
+include_directories(/one/two
+ " "
+ " "
+)
+get_target_property(incs empty_entry_test INCLUDE_DIRECTORIES)
+if (NOT incs STREQUAL ";/one/two")
+ message(SEND_ERROR "Empty include_directories entry was not ignored.")
+endif()
diff --git a/Tests/IncludeDirectories/TargetIncludeDirectories/CMakeLists.txt b/Tests/IncludeDirectories/TargetIncludeDirectories/CMakeLists.txt
index bcfbe3c..4a5aa30 100644
--- a/Tests/IncludeDirectories/TargetIncludeDirectories/CMakeLists.txt
+++ b/Tests/IncludeDirectories/TargetIncludeDirectories/CMakeLists.txt
@@ -115,6 +115,25 @@
target_include_directories(lib7 PUBLIC $<$<STREQUAL:$<TARGET_PROPERTY:TYPE>,EXECUTABLE>:/lib7/include>)
add_custom_target(head_target_test "some_bogus_custom_tool \"$<TARGET_PROPERTY:lib7,INCLUDE_DIRECTORIES>$<TARGET_PROPERTY:lib7,INTERFACE_INCLUDE_DIRECTORIES>\"")
+add_library(includes_source_good empty.cpp)
+target_include_directories(includes_source_good
+ INTERFACE
+ "${CMAKE_CURRENT_BINARY_DIR}/good"
+ "${CMAKE_CURRENT_BINARY_DIR}/othergood/"
+)
+add_library(includes_source_bad empty.cpp)
+target_include_directories(includes_source_bad
+ INTERFACE
+ "${CMAKE_CURRENT_BINARY_DIR}/bad"
+)
+
+add_library(includes_proxy SHARED empty.cpp)
+target_link_libraries(includes_proxy includes_source_good)
+target_link_libraries(includes_proxy LINK_INTERFACE_LIBRARIES includes_source_bad)
+add_executable(copy_includes copy_includes.cpp)
+target_include_directories(copy_includes PRIVATE $<TARGET_PROPERTY:includes_proxy,INCLUDE_DIRECTORIES>)
+
+
file(WRITE "${CMAKE_CURRENT_BINARY_DIR}/lib5.cpp" "#include \"common.h\"\n")
add_library(lib5 "${CMAKE_CURRENT_BINARY_DIR}/lib5.cpp")
diff --git a/Tests/IncludeDirectories/TargetIncludeDirectories/copy_includes.cpp b/Tests/IncludeDirectories/TargetIncludeDirectories/copy_includes.cpp
new file mode 100644
index 0000000..fed4c03
--- /dev/null
+++ b/Tests/IncludeDirectories/TargetIncludeDirectories/copy_includes.cpp
@@ -0,0 +1,7 @@
+
+#include "common.h"
+
+int main()
+{
+ return 0;
+}
diff --git a/Tests/IncludeDirectories/TargetIncludeDirectories/empty.cpp b/Tests/IncludeDirectories/TargetIncludeDirectories/empty.cpp
new file mode 100644
index 0000000..7279c5e
--- /dev/null
+++ b/Tests/IncludeDirectories/TargetIncludeDirectories/empty.cpp
@@ -0,0 +1,7 @@
+#ifdef _WIN32
+__declspec(dllexport)
+#endif
+int empty(void)
+{
+ return 0;
+}
diff --git a/Tests/IncludeDirectories/empty.cpp b/Tests/IncludeDirectories/empty.cpp
new file mode 100644
index 0000000..1787013
--- /dev/null
+++ b/Tests/IncludeDirectories/empty.cpp
@@ -0,0 +1,4 @@
+#ifdef _WIN32
+__declspec(dllexport)
+#endif
+int empty() { return 0; }
diff --git a/Tests/RegexEscapeString.cmake b/Tests/RegexEscapeString.cmake
new file mode 100644
index 0000000..92aed17
--- /dev/null
+++ b/Tests/RegexEscapeString.cmake
@@ -0,0 +1,4 @@
+macro(REGEX_ESCAPE_STRING _OUT _IN)
+ # Escape special regex metacharacters with a backslash
+ string(REGEX REPLACE "([$^.[|*+?()]|])" "\\\\\\1" ${_OUT} "${_IN}")
+endmacro()
diff --git a/Tests/RunCMake/ExternalData/LinkDirectory1-stdout.txt b/Tests/RunCMake/ExternalData/LinkDirectory1-stdout.txt
new file mode 100644
index 0000000..953ea68
--- /dev/null
+++ b/Tests/RunCMake/ExternalData/LinkDirectory1-stdout.txt
@@ -0,0 +1,5 @@
+-- Linked Dir/ToLink.txt.md5 to ExternalData MD5/c18ff9804c8deec9eaeb17063cda8b7b
+-- Raw data correctly transformed to content link!
+-- Staged content exists!
+-- Staged content is correct!
+-- Staged content was correctly not re-staged!
diff --git a/Tests/RunCMake/ExternalData/LinkDirectory1.cmake b/Tests/RunCMake/ExternalData/LinkDirectory1.cmake
new file mode 100644
index 0000000..541fc79
--- /dev/null
+++ b/Tests/RunCMake/ExternalData/LinkDirectory1.cmake
@@ -0,0 +1,37 @@
+include(ExternalData)
+set(ExternalData_LINK_CONTENT MD5)
+set(ExternalData_SOURCE_ROOT ${CMAKE_CURRENT_BINARY_DIR})
+set(ExternalData_BINARY_ROOT ${CMAKE_CURRENT_BINARY_DIR}/ExternalData)
+set(input ${CMAKE_CURRENT_BINARY_DIR}/Dir)
+set(output ${CMAKE_CURRENT_BINARY_DIR}/ExternalData/Dir)
+set(staged "${input}/.ExternalData_MD5_c18ff9804c8deec9eaeb17063cda8b7b")
+set(content "To be transformed into a content link.")
+file(REMOVE ${staged})
+file(REMOVE_RECURSE ${input})
+file(WRITE ${input}/ToLink.txt "${content}")
+ExternalData_Expand_Arguments(Data args "DATA{${input}/,REGEX:.*}")
+if("x${args}" STREQUAL "x${output}")
+ message(STATUS "Raw data correctly transformed to content link!")
+else()
+ message(FATAL_ERROR "Data reference transformed to:\n ${args}\n"
+ "but we expected:\n ${output}")
+endif()
+if(EXISTS "${staged}")
+ message(STATUS "Staged content exists!")
+else()
+ message(FATAL_ERROR "Staged content missing!")
+endif()
+
+# Expand again to check whether staged content is ignored.
+ExternalData_Expand_Arguments(Data args "DATA{${input}/,REGEX:.*}")
+file(STRINGS "${staged}" staged_content LIMIT_INPUT 1024)
+if("${content}" STREQUAL "${staged_content}")
+ message(STATUS "Staged content is correct!")
+else()
+ message(STATUS "Staged content is incorrect!")
+endif()
+if(EXISTS "${staged}.md5")
+ message(FATAL_ERROR "Staged content was incorrectly re-staged!")
+else()
+ message(STATUS "Staged content was correctly not re-staged!")
+endif()
diff --git a/Tests/RunCMake/ExternalData/RunCMakeTest.cmake b/Tests/RunCMake/ExternalData/RunCMakeTest.cmake
index ceb2ecf..8fba82c 100644
--- a/Tests/RunCMake/ExternalData/RunCMakeTest.cmake
+++ b/Tests/RunCMake/ExternalData/RunCMakeTest.cmake
@@ -13,6 +13,7 @@
run_cmake(Directory5)
run_cmake(LinkContentMD5)
run_cmake(LinkContentSHA1)
+run_cmake(LinkDirectory1)
run_cmake(MissingData)
run_cmake(NoLinkInSource)
run_cmake(NoURLTemplates)