Brad King c1edede31f Merge topic 'compile-features-C-language' 11 лет назад
..
CMP0004 d05a9bd1e6 Cygwin: Avoid legacy warnings in RunCMake.* tests 12 лет назад
CMP0019 d05a9bd1e6 Cygwin: Avoid legacy warnings in RunCMake.* tests 12 лет назад
CMP0022 d25ad482e9 OS X: Add CMP0042 to enable MACOSX_RPATH by default 12 лет назад
CMP0026 911cc9a39e cmTarget: Evaluate CMP0026 and CMP0051 in calling context 11 лет назад
CMP0027 b1bbee3e9a Record more policies on targets when created 12 лет назад
CMP0028 50fd0a33c9 Tests: Simplify and document policy scopes in RunCMake.CMP* tests 12 лет назад
CMP0037 77b581c2f0 Policies: omit warnings about unset policies when they are actually set to NEW 12 лет назад
CMP0038 b1bbee3e9a Record more policies on targets when created 12 лет назад
CMP0039 77b581c2f0 Policies: omit warnings about unset policies when they are actually set to NEW 12 лет назад
CMP0040 77b581c2f0 Policies: omit warnings about unset policies when they are actually set to NEW 12 лет назад
CMP0041 50fd0a33c9 Tests: Simplify and document policy scopes in RunCMake.CMP* tests 12 лет назад
CMP0042 50fd0a33c9 Tests: Simplify and document policy scopes in RunCMake.CMP* tests 12 лет назад
CMP0043 50fd0a33c9 Tests: Simplify and document policy scopes in RunCMake.CMP* tests 12 лет назад
CMP0045 50fd0a33c9 Tests: Simplify and document policy scopes in RunCMake.CMP* tests 12 лет назад
CMP0046 77b581c2f0 Policies: omit warnings about unset policies when they are actually set to NEW 12 лет назад
CMP0049 50fd0a33c9 Tests: Simplify and document policy scopes in RunCMake.CMP* tests 12 лет назад
CMP0050 50fd0a33c9 Tests: Simplify and document policy scopes in RunCMake.CMP* tests 12 лет назад
CMP0051 911cc9a39e cmTarget: Evaluate CMP0026 and CMP0051 in calling context 11 лет назад
CTest bca67c710f build_command: Return a "cmake --build" command-line 12 лет назад
CheckModules 7f857775e2 CheckTypeSize: Add unit test to cover the no-C case 12 лет назад
CommandLine 94389f6388 cmake: Add '-E sleep' command 12 лет назад
CompatibleInterface 5771f81d91 cmTarget: Add GetTransitiveTargetClosure method. 12 лет назад
CompileFeatures e0890d03a4 Features: Extend concept to C language. 11 лет назад
CompilerChange 15610bb5b1 Drop use of configure_file IMMEDIATE option 12 лет назад
CompilerNotFound 3e04946f7b Require CMAKE_<LANG>_COMPILER to be found as a full path 12 лет назад
Configure e0890d03a4 Features: Extend concept to C language. 11 лет назад
DisallowedCommands 4ea27bcc4c Cygwin: Avoid legacy warnings in RunCMake.DisallowedCommands test 12 лет назад
ExportWithoutLanguage 66b290e7e2 export(): Process the export() command at generate time. 12 лет назад
ExternalData ccd29b9af8 ExternalData: Warn on missing file instead of failing 11 лет назад
FPHSA d05a9bd1e6 Cygwin: Avoid legacy warnings in RunCMake.* tests 12 лет назад
FeatureSummary 8372b4553b FeatureSummary: Add unit tests 12 лет назад
File_Generate 42e1cd137c file(GENERATE): Only write the file if content is different. 11 лет назад
FindPkgConfig cc5a0d8f42 FindPkgConfig: More unit tests 12 лет назад
GeneratorExpression 6aabb6a62b Genex: Use case-sensitive comparison for COMPILER_ID. 12 лет назад
GeneratorToolset d05a9bd1e6 Cygwin: Avoid legacy warnings in RunCMake.* tests 12 лет назад
IncompatibleQt d05a9bd1e6 Cygwin: Avoid legacy warnings in RunCMake.* tests 12 лет назад
Languages d05a9bd1e6 Cygwin: Avoid legacy warnings in RunCMake.* tests 12 лет назад
ObjectLibrary fdcefe3c42 cmGeneratorTarget: Compute consumed object libraries on demand. 12 лет назад
ObsoleteQtMacros f69606d335 Qt4Macros: Port to use message(DEPRECATION) 12 лет назад
PositionIndependentCode 2e60b5fcf7 cmTarget: Report origin of COMPATIBLE_INTERFACE properties. 12 лет назад
SolutionGlobalSections d05a9bd1e6 Cygwin: Avoid legacy warnings in RunCMake.* tests 12 лет назад
Syntax 411f77d14f EVIS: Add tests for syntax corner cases and CMP0053 11 лет назад
TargetObjects 5de63265e3 Genex: Only evaluate TARGET_OBJECTS to determine target sources. 12 лет назад
TargetPolicies 783bce295b Export: Disallow exported interface includes in src/build tree (#14592). 12 лет назад
TargetPropertyGeneratorExpressions d05a9bd1e6 Cygwin: Avoid legacy warnings in RunCMake.* tests 12 лет назад
TargetSources b8af201168 cmTarget: Fix listing of source files at configure-time. 11 лет назад
VisibilityPreset d05a9bd1e6 Cygwin: Avoid legacy warnings in RunCMake.* tests 12 лет назад
WriteCompilerDetectionHeader 62a4a67dc5 Add the WriteCompilerDetectionHeader module. 11 лет назад
XcodeProject a339ea6529 Xcode: Add source file property to control file type (#14854) 11 лет назад
add_dependencies d05a9bd1e6 Cygwin: Avoid legacy warnings in RunCMake.* tests 12 лет назад
alias_targets d05a9bd1e6 Cygwin: Avoid legacy warnings in RunCMake.* tests 12 лет назад
build_command 4ac75fdfe6 Prefer CMAKE_MAKE_PROGRAM over CMAKE_BUILD_TOOL (#14548) 12 лет назад
cmake_minimum_required 7d47c69365 Drop compatibility with CMake < 2.4 12 лет назад
configure_file 98383f802a Unicode: check encoding of files given to configure_file. 12 лет назад
export cbe7e8fae4 export: Implement EXPORT subcommand (#9822) 12 лет назад
find_dependency a25b809f20 Tests: Check find_dependency empty extra arguments 12 лет назад
find_package d05a9bd1e6 Cygwin: Avoid legacy warnings in RunCMake.* tests 12 лет назад
get_filename_component d05a9bd1e6 Cygwin: Avoid legacy warnings in RunCMake.* tests 12 лет назад
if d05a9bd1e6 Cygwin: Avoid legacy warnings in RunCMake.* tests 12 лет назад
include 77b581c2f0 Policies: omit warnings about unset policies when they are actually set to NEW 12 лет назад
include_directories 3b673586f5 CMP0052: Make the warning message more informative. 11 лет назад
include_external_msproject d05a9bd1e6 Cygwin: Avoid legacy warnings in RunCMake.* tests 12 лет назад
install be0458c562 InstallRules: added new variable to disable generation of install rules 12 лет назад
interface_library 2600e923a6 Disallow INTERFACE libraries with add_custom_command(TARGET). 12 лет назад
list d05a9bd1e6 Cygwin: Avoid legacy warnings in RunCMake.* tests 12 лет назад
message 509c142a3f message: Add a DEPRECATION mode 12 лет назад
no_install_prefix fe057ab3cd Allow disabling adding the install prefix to the prefix search path. 12 лет назад
project 7e142c5ac2 project: Manage VERSION variables 12 лет назад
set c869984ea0 RunCMake: Allow specifying the source dir and file to test. 12 лет назад
string 4e184a21be string: Add CONCAT sub-command 12 лет назад
target_compile_features e0890d03a4 Features: Extend concept to C language. 11 лет назад
target_link_libraries 77b581c2f0 Policies: omit warnings about unset policies when they are actually set to NEW 12 лет назад
try_compile d05a9bd1e6 Cygwin: Avoid legacy warnings in RunCMake.* tests 12 лет назад
variable_watch d05a9bd1e6 Cygwin: Avoid legacy warnings in RunCMake.* tests 12 лет назад
CMakeLists.txt a339ea6529 Xcode: Add source file property to control file type (#14854) 11 лет назад
README.rst d4ca30ae15 Tests/RunCMake: Add function to run a specified command-line 12 лет назад
RunCMake.cmake c869984ea0 RunCMake: Allow specifying the source dir and file to test. 12 лет назад

README.rst

This directory contains tests that run CMake to configure a project
but do not actually build anything. To add a test:

1. Add a subdirectory named for the test, say ``/``.

2. In ``./CMakeLists.txt`` call ``add_RunCMake_test`` and pass the
test directory name ````.

3. Create script ``/RunCMakeTest.cmake`` in the directory containing::

include(RunCMake)
run_cmake(SubTest1)
...
run_cmake(SubTestN)

where ``SubTest1`` through ``SubTestN`` are sub-test names each
corresponding to an independent CMake run and project configuration.

One may also add calls of the form::

run_cmake_command(SubTestI ${CMAKE_COMMAND} ...)

to fully customize the test case command-line.

4. Create file ``/CMakeLists.txt`` in the directory containing::

cmake_minimum_required(...)
project(${RunCMake_TEST} NONE) # or languages needed
include(${RunCMake_TEST}.cmake)

where ``${RunCMake_TEST}`` is literal. A value for ``RunCMake_TEST``
will be passed to CMake by the ``run_cmake`` macro when running each
sub-test.

5. Create a ``/.cmake`` file for each sub-test named
above containing the actual test code. Optionally create files
containing expected test results:

``-result.txt``
Process result expected if not "0"
``-stdout.txt``
Regex matching expected stdout content
``-stderr.txt``
Regex matching expected stderr content
``-check.cmake``
Custom result check.

Note that trailing newlines will be stripped from actual and expected
test output before matching against the stdout and stderr expressions.
The code in ``-check.cmake`` may use variables

``RunCMake_TEST_SOURCE_DIR``
Top of test source tree
``RunCMake_TEST_BINARY_DIR``
Top of test binary tree

and an failure must store a message in ``RunCMake_TEST_FAILED``.