Commit Graph

670 Commits

Author SHA1 Message Date
Brad King deec97d8ec Revert "Qbs: Add new 'extra' generator for qbs project files"
This reverts commit f85db2f323.

Discussion by the QtCreator community at

  https://bugreports.qt.io/browse/QTCREATORBUG-13695

raises concerns about this particular approach to working with CMake
projects using QtCreator.  Also, the functionality and design of the QBS
extra generator was never discussed on the CMake mailing list or with
QtCreator developers.  There may be better ways to make the two tools
work together.

In order to avoid committing to long-term support of this generator
prior to such discussion taking place, revert it from CMake for now.
We may restore this or use an alternative design based on results of
such discussion.
2015-05-21 09:05:58 -04:00
Brad King 70d48e1287 Merge topic 'cpack-deb-component-dependencies'
1237d5fa Help: Add notes for topic 'cpack-deb-component-dependencies'
e3f522f6 CPack/DEB per component dependencies
2015-05-12 09:12:54 -04:00
Domen Vrankar 7c103be8de CPack: Enable DEB and RPM tests more reliably
CPack DEB and RPM generators were not used for some tests because
CPACK_BINARY_DEB and CPACK_BINARY_RPM variable were not set.  Fix this,
simplify generator selection in CTEST_RUN_CPackComponentsForAll, and fix
bugs that were detected after tests were run.
2015-05-12 08:56:34 -04:00
Raffi Enficiaud e3f522f6e4 CPack/DEB per component dependencies
Dependencies may now be set per component
2015-05-08 23:36:26 +02:00
Brad King 18527c4991 Merge topic 'vs-install-in-default-build'
a6e4e73d VS: Add option to put INSTALL target in .sln default build
562e69dd Tests: Enable devenv tests on VS >= 10
2015-05-07 14:25:37 -04:00
Raffi Enficiaud 4588a1697f CPack/DEB component dependency auto-discovery
Dependency auto-discovery can now be set per component
2015-05-07 14:21:57 -04:00
Robert Goulet a6e4e73da3 VS: Add option to put INSTALL target in .sln default build
Add a CMAKE_VS_INCLUDE_INSTALL_TO_DEFAULT_BUILD variable to control
this behavior.
2015-05-06 10:31:39 -04:00
Brad King 562e69dd50 Tests: Enable devenv tests on VS >= 10
The VSExcludeFromDefaultBuild have not been enabled on VS >= 10 since
commit v3.0.0-rc1~260^2~9 (Tests: Simplify VSExcludeFromDefaultBuild
configuration, 2013-11-14).  Since commit v3.0.0-rc1~260^2~2 (VS: Add
CMAKE_VS_(DEVENV|MSBUILD|MSDEV)_COMMAND variables, 2013-12-04) we can
simply check the CMAKE_VS_DEVENV_COMMAND variable for a devenv tool
to use for the test.
2015-05-04 16:07:23 -04:00
Raffi Enficiaud 2f0afffabd CPackDEB component description
Support for setting different description
for each component.
2015-04-29 18:05:36 +02:00
Stephen Kelly bf24b6c501 Tests: Guard more CTest tests against parallel execution. 2015-04-27 22:03:40 +02:00
Brad King ebb54e02c4 Merge topic 'cpack-deb-linitian-md5hash'
75b0e167 CPackDeb: Add basic package tests
fdfe4586 CPackDeb: Fix lintian md5sum file warning
2015-04-23 09:04:43 -04:00
Raffi Enficiaud 75b0e1679c CPackDeb: Add basic package tests
Tests of generated component based deb packages with lintian and dpkg.
Also includes basic file name check.
2015-04-23 09:03:10 -04:00
Brad King 1468f31988 Merge topic 'ExternalProject-genex'
b470d618 Help: Add notes for topic 'ExternalProject-genex'
0273ef14 ExternalProject: Allow generator expressions with LOG_* options (#15287)
7bd8cfb8 ExternalProject: Allow generator expressions in initial cache options
1cf43dcf Tests: Add case to cover ExternalProject with subdirectories
2015-04-22 11:16:43 -04:00
Brad King 2f4b13b32d Tests: Protect CTestTestSerialOrder from environment (#15524)
Reported-by: Stephen Kelly <steveire@gmail.com>
2015-04-21 11:47:42 -04:00
Brad King 1cf43dcf7c Tests: Add case to cover ExternalProject with subdirectories
Add an ExternalProjectSubdir test directory with a minimal test showing
use of ExternalProject_Add for a source tree in a subdirectory.  This
will allow us to easily add test external projects that cover specific
behavior where the client project must check results.
2015-04-21 10:40:52 -04:00
Brad King 5e0e65c189 Merge topic 'add-GreenHills-MULTI-generator'
66b641f4 Help: Add notes for topic 'add-GreenHills-MULTI-generator'
48004d9d Add a 'Green Hills MULTI' generator on Windows
051d8be1 cmLocalGenerator: Constify some cmTarget and cmGeneratorTarget arguments
2015-04-20 14:02:52 -04:00
Geoff Viola 48004d9dbe Add a 'Green Hills MULTI' generator on Windows
Green Hills MULTI is an IDE for embedded real-time systems.  The IDE's
product page can be found here:

 http://www.ghs.com/products/MULTI_IDE.html

It supports cross compiling on ARM, Intel x86, and other architectures
with various operating systems.  The IDE exists on Linux and Windows
host systems, but CMake will currently only generate the project files
on Windows host systems.
2015-04-20 13:55:40 -04:00
Brad King 9efee16a7a Merge topic 'ninja-autogen'
e8fdd5f1 QtAutogen: Workaround rcc CRCRLF newlines on Windows (#15459)
15f1a6b4 Tests/QtAutogen: Avoid touching files in the source tree
3f7c7c65 Tests/QtAutogen: Help Qt5Autogen test find Qt5 on Windows
26b5cc5e Tests/QtAutogen: Enable per-config source tests when possible
45566408 Tests/QtAutogen: Require CMake 3.1 to set policies everywhere
2015-04-17 10:50:13 -04:00
Brad King 26b5cc5e79 Tests/QtAutogen: Enable per-config source tests when possible
Pass CMAKE_BUILD_TYPE into the test on generators that use it so that
the per-config part of the test can activate as needed.  Do not make the
per-config part conditional on the Debug configuration because the
generator expressions evaluate to empty in other configurations.

Skip the per-config source case with the Ninja generator because it does
not currently work.  cmQtAutoGenerators::InitializeAutogenTarget needs
to know the list of source files on a target, but generator expressions
in the list cannot be evaluated until after CreateGeneratorTargets has
been called.  That cannot happen until after Autogen targets have been
generated.  It is a chicken-and-egg problem.
2015-04-16 15:00:26 -04:00
Brad King 4e039a9a98 Tests: Move more command line tests into RunCMake.CommandLine
Port most CMakeTestBadCommandLines test cases to RunCMake.CommandLine
and drop the former test.  Add validation of expected results, which was
not done by the old test.
2015-04-10 14:56:41 -04:00
Nils Gladitz 6c4781baa9 Tests: Consolidate, refactor and extend -E tar tests 2015-04-10 08:32:32 -04:00
Brad King dfbde6fa99 Merge topic 'gcov-module-coverage-exclude'
9a544f2d CTestCoverageCollectGCOV: Support CTEST_CUSTOM_COVERAGE_EXCLUDE
2015-04-06 08:58:21 -04:00
Nils Gladitz 9a544f2d98 CTestCoverageCollectGCOV: Support CTEST_CUSTOM_COVERAGE_EXCLUDE 2015-04-04 12:25:15 +02:00
Gilles Khouzam 01a9ab0def VS: Add support for XAML source files
XAML files are by default of type Page in the vcxproj and can be
overriden by setting the VS_XAML_TYPE property.  The .cpp and .h file
of the same name are automatically added as depending on the XAML file.

New VSXaml test builds a basic XAML WindowsStore 8.1 app with VS2013.
2015-04-03 13:40:35 -04:00
Domen Vrankar 681f3a2f01 CPackRPM: Add basic symlink support (#15209)
RPM packages can contain symbolic links to relative paths - including
support for multiple relocation paths through generation of post install
relocation scripts.  Add basic support with limitations described in
documentation.
2015-03-31 14:04:13 -04:00
Clinton Stimpson e3f84fc504 cpack: Fix CPACK_PACKAGING_INSTALL_PREFIX handling for archives (#14677)
Fix the case when the archive generator is used to package components
with an install prefix.
2015-03-30 09:22:14 -04:00
Gregor Jasny 6ab1413499 Tests: Enable XCTest tests for Xcode 5
Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
2015-03-24 11:24:56 -04:00
Brad King e85eb2e336 Merge topic 'add-extra-qbs-generator'
f85db2f3 Qbs: Add new 'extra' generator for qbs project files
2015-03-23 09:18:43 -04:00
Gregor Jasny 87a4b8580c Tests: Add XCTest example to test Frameworks and Cocoa App Bundles
Signed-off-by: Gregor Jasny <gjasny@googlemail.com>
2015-03-23 09:12:20 -04:00
Stanislav Ionascu f85db2f323 Qbs: Add new 'extra' generator for qbs project files 2015-03-20 10:25:11 -04:00
Brad King 54a5cdbb4c Tests: Compute Xcode version for any generator on OS X
Store the version in CMake_TEST_XCODE_VERSION for use by tests that work
with any generator on OS X but may depend on the Xcode version providing
the tools.
2015-03-18 15:23:53 +01:00
Brad King 8915cddcde Merge topic 'FindMatlab-rewrite'
49c8dcf7 FindMatlab: Rewrite module and provide a usage API
2015-03-17 10:14:52 -04:00
Zach Mullen 874fdd914a CTest: Output test-specific env vars in verbose mode (#15446)
Any environment vars that were configured for a test via the
ENVIRONMENT property will now be output when the test is run
with verbose logging enabled.
2015-03-17 10:11:33 -04:00
Raffi Enficiaud 49c8dcf7bb FindMatlab: Rewrite module and provide a usage API
Implement a brand new FindMatlab module:

- Add support for versions and components.
- Find Matlab and its version in a more precise and multiplatform way.
- Add API to create a new mex extension with documentation.
- Add API to add matlab unit tests (with or without the unit test framework).
- Find as much as possible based on a single Matlab_ROOT_DIR cache entry
  and allow the user to change it to re-find everything.
2015-03-17 09:47:04 -04:00
Joseph Snyder c771f9d945 CTest: Fix Jacoco Coverage
Rename the example jacoco.xml file to be jacoco.xml.in to stop CMake
from apptempting to calculate Jacoco Coverage when running over itself.

Enclose a push of -1 to the coverage vector to only happen if there is a
fin to calculate for. This prevents a crash if the target file doesn't
exist.
2015-03-06 11:18:19 -05:00
Brad King b10310e6e6 Tests: Drop CTestTestFailedSubmit-* tests
Everything they cover is now covered by RunCMake.ctest_submit test cases
(except ctest_coverage LABELS which were not actually checked anyway).
Drop these redundant tests.
2015-02-24 10:03:27 -05:00
Domen Vrankar 8c0474cd2c CPackRPM: run tests on more platforms than just Linux
Lift the restriction that limits use of CPackRPM tests to Linux OS only
because RPM can also be used on e.g. AIX which is Unix OS.
2015-02-23 10:19:29 -05:00
Brad King d891d47434 Tests: Consolidate detection of 'rpmbuild'
Several tests use slight variations of the same logic to enable CPack
RPM tests.  Consolidate this logic into one check before any tests are
added.  Look for 'rpmbuild' only on Linux and only when the test build
tree does not have spaces in the path.  In particular, this will make
the result available in time for the RunCMake.CPackRPM test to be
activated even if CMake is configured exactly once.
2015-02-13 11:50:38 -05:00
Brad King 8f82004368 Merge topic 'CTestCoverageCollectGCOV-refinements'
809a5a5e Help: Add notes for topic 'CTestCoverageCollectGCOV-refinements'
03c0812c CTestCoverageCollectGCOV: Fix handling of international characters
8caa4e72 CTestCoverageCollectGCOV: Add test case
5c828cc8 CTestCoverageCollectGCOV: Allow custom flags to gcov
30cb628e CTestCoverageCollectGCOV: Fix handling of large file counts
2015-02-04 12:30:10 -05:00
Bill Hoffman 8caa4e72ab CTestCoverageCollectGCOV: Add test case 2015-02-03 10:40:58 -05:00
Brad King ab9fa54d48 Xcode: Switch to internal CMAKE_MAKE_PROGRAM lookup by generator (#15324)
The "cmakexbuild" wrapper is not needed for Xcode 4 and above, and the
path to it may change when CMake moves.  Avoid storing a specific path
to a build program in CMakeCache.txt and instead compute the value for
CMAKE_MAKE_PROGRAM on demand.  However, if a user does set the value
explicitly then honor it.

This does for Xcode what commit v3.0.0-rc1~260^2~4 (VS: Switch to
internal CMAKE_MAKE_PROGRAM lookup by generators, 2013-11-15) did for
Visual Studio generators.
2015-01-29 09:11:11 -05:00
Brad King 0aebeb9c84 FindJsonCpp: Add module to find JsonCpp package 2015-01-19 09:34:03 -05:00
Brad King 661622f011 Merge topic 'ninja-fix-subdir-objlib-languages'
07fc7b75 Tests: Test using objects from a language enabled in a subdirectory (#15325)
fdbfcfdf Ninja: Generate rules only for languages compiled in a target (#15325)
2014-12-24 06:38:24 -05:00
Brad King 400af305ef Merge topic 'add-FindGSL'
1b28e3b2 FindGSL: Add module to find the GNU Scientific Library
2014-12-23 08:53:45 -05:00
Brad King 07fc7b75ef Tests: Test using objects from a language enabled in a subdirectory (#15325)
Add a test case that enables CXX in the top level and C in a subdirectory.
Create an executable in the top level that uses C objects compiled in the
subdirectory.  Strictly speaking this is not defined behavior for all
language combinations, but happens to work in this case.  Test this
behavior since projects might try to use it.
2014-12-22 20:13:40 -05:00
Brad King ccd5822a83 Merge topic 'osx-cfbundle-tweaks'
b189c599 Tests: Run CFBundleTest only with valid configuration
3a605693 Xcode: Call IsCFBundleOnApple to decide if bundle is being built
207b7af0 cmTarget: Use GetCFBundleDirectory within GetFullNameInternal
2014-12-19 08:26:57 -05:00
Brad King b189c5994d Tests: Run CFBundleTest only with valid configuration
The verification script needs to know the configuration tested.
2014-12-19 08:24:04 -05:00
Brad King 7ca6bdf035 Tests: Move CTestTestMemcheck tools into Tests/CMakeLib
The dummy memcheck tools we build for the RunCMake.CTestMemcheck tests
require CMakeLib, so put them in a Tests/CMakeLib/PseudoMemcheck
directory.
2014-12-18 10:12:16 -05:00
Kelly Thompson 1b28e3b28b FindGSL: Add module to find the GNU Scientific Library 2014-12-17 10:59:48 -05:00
Brad King f53a3340bb Tests: Fix OS X version check to use component-wise test
Otherwise 10.10 may be considered to be less than 10.4 and the
tests for CPack will not run.

Reported-by: Sean McBride <sean@rogue-research.com>
2014-12-12 15:11:37 -05:00
Ben Boeckel b7d760aea2 test: test source file properties with case-insensitivity
Some filesystems are case insensitive, so when setting properties on the
files, this should be respected (modulo a policy decision).
2014-12-02 10:56:36 -05:00
Brad King cbec5c0445 Merge topic 'default-lang-dialect-for-master'
f327a9fd Merge branch 'default-lang-dialect' into step2
36bb100e Fix the test for running the CxxDialog unit test.
a3d0ae17 Features: Fix the default C dialect for Clang and GNU.
49e2b689 Features: Fix references to CXX compiler version in Clang-C.cmake.
7565ab2c Features: Test the CXX compiler only if it has features.
2014-11-25 10:18:37 -05:00
Stephen Kelly f327a9fd26 Merge branch 'default-lang-dialect' into step2
Conflicts:
	Modules/Compiler/Clang-C.cmake
2014-11-20 22:11:56 +01:00
Stephen Kelly 36bb100e2b Fix the test for running the CxxDialog unit test.
The existing versions have been used since commit
v3.1.0-rc1~635^2~8 (cmTarget: Add CXX_STANDARD and CXX_EXTENSION
target properties., 2013-10-13), but further discussions since then
increased the initial minimum compiler versions this feature is
available for.
2014-11-20 22:10:25 +01:00
Brad King e15a7075b5 Add an option for explicit BYPRODUCTS of custom commands (#14963)
A common idiom in CMake-based build systems is to have custom commands
that generate files not listed explicitly as outputs so that these
files do not have to be newer than the inputs.  The file modification
times of such "byproducts" are updated only when their content changes.
Then other build rules can depend on the byproducts explicitly so that
their dependents rebuild when the content of the original byproducts
really does change.

This "undeclared byproduct" approach is necessary for Makefile, VS, and
Xcode build tools because if a byproduct were listed as an output of a
rule then the rule would always rerun when the input is newer than the
byproduct but the byproduct may never be updated.

Ninja solves this problem by offering a 'restat' feature to check
whether an output was really modified after running a rule and tracking
the fact that it is up to date separately from its timestamp.  However,
Ninja also stats all dependencies up front and will only restat files
that are listed as outputs of rules with the 'restat' option enabled.
Therefore an undeclared byproduct that does not exist at the start of
the build will be considered missing and the build will fail even if
other dependencies would cause the byproduct to be available before its
dependents build.

CMake works around this limitation by adding 'phony' build rules for
custom command dependencies in the build tree that do not have any
explicit specification of what produces them.  This is not optimal
because it prevents Ninja from reporting an error when an input to a
rule really is missing.  A better approach is to allow projects to
explicitly specify the byproducts of their custom commands so that no
phony rules are needed for them.  In order to work with the non-Ninja
generators, the byproducts must be known separately from the outputs.

Add a new "BYPRODUCTS" option to the add_custom_command and
add_custom_target commands to specify byproducts explicitly.  Teach the
Ninja generator to specify byproducts as outputs of the custom commands.
In the case of POST_BUILD, PRE_LINK, and PRE_BUILD events on targets
that link, the byproducts must be specified as outputs of the link rule
that runs the commands.  Activate 'restat' for such rules so that Ninja
knows it needs to check the byproducts, but not for link rules that have
no byproducts.
2014-11-14 16:16:00 -05:00
Brad King 0854d45bbb Tests: Build config-dependent tests in the same config they run
The CPackComponentsForAll-*, GeneratorExpression, and
TestsWorkingDirectory tests all build binaries that they later
need to run or package for the tested configuration.  Tell the
'ctest --build-and-test' call to use the same configuration
for driving the build process.
2014-11-13 09:37:11 -05:00
Brad King 75f3a282b7 Merge topic 'update-curl'
c02c747b Tests: Update expected CTestTestFailedSubmit output
a427ed0c curl: Skip sanity check that triggers Clang warning
17b24d55 curl: Disable warnings to avoid changing 3rd party code
4c3bd340 curl: Skip check for inet_pton on Windows
54cb23c6 curl: Restore installation of OpenSSL DLLs
c50f0327 curl: Restore CURL_CA_BUNDLE option
681693c9 curl: Restore CMake-specific zlib selection code
10d80b68 curl: Restore CMake-specific test and install code
19593042 curl: Configure build to work within CMake
cf54aebb curl: Fix curl.h inclusion of curlbuild.h from CMake sources
c17e3207 curl: Use arch-aware CHECK_TYPE_SIZE results
1f7cb7e2 curl: Fix detection of headers with dependencies
b18c9044 curl: Drop inclusion of .rc file for static lib
860f0a2d curl: Select file APIs on Windows
5a3b55ed curl: Do not use 'dl' on HP-UX
59242702 curl: Simplify if() conditions on check result variables
...
2014-11-10 10:43:10 -05:00
Brad King c02c747b85 Tests: Update expected CTestTestFailedSubmit output
Add another error message that curl now produces.
2014-11-10 10:13:39 -05:00
Brad King 6e1e7dd014 Merge topic 'wince-tests'
5bd29b88 Tests: Run Tutorial steps 1-4 as tests for Windows CE
2014-10-30 14:11:51 -04:00
Joseph Snyder 220e81345b CTest: Add Javascript coverage parser
Add a coverage parser for the Blanket.js library using the JSON output of
the mocha.js test runner.

Add a test for the new parser.
2014-10-29 11:27:11 -04:00
Pascal Bach 5bd29b8889 Tests: Run Tutorial steps 1-4 as tests for Windows CE 2014-10-29 09:39:20 -04:00
Brad King 95d84f76d9 Merge topic 'cmake-cmp0054-warnings'
29c3edb8 Avoid if() quoted auto-dereference
2014-10-21 15:08:07 -04:00
Brad King 4f9fcd356b Merge topic 'ctest-delphi-coverage'
5c31c3e4 CTest: Add code coverage parser for Pascal/Delphi
2014-10-21 15:07:58 -04:00
Joseph Snyder 5c31c3e4eb CTest: Add code coverage parser for Pascal/Delphi
Add a class to parse the HTML output of the Delphi-code-coverage tool

 http://code.google.com/p/delphi-code-coverage/

Add a test for the new parser.
2014-10-21 15:02:20 -04:00
Ben Boeckel 29c3edb87a Avoid if() quoted auto-dereference
When testing CMAKE_<LANG>_COMPILER_ID values, do not explicitly
dereference or quote the variable. We want if() to auto-dereference the
variable and not its value. Also replace MATCHES with STREQUAL where
equivalent.
2014-10-20 11:49:16 -04:00
Brad King 34d035e70e Merge topic 'vs-nsight-tegra-generator'
df84281d Help: Add notes for topic 'vs-nsight-tegra-generator'
69e198dc VS: Generate Nsight Tegra project revision number
5365c9ac VS: Map Nsight Tegra file types in .vcxproj files
178f56a5 VS: Fix Tegra-Android platform linking of libraries by name
7115702f Tests: Add test for VS Nsight Tegra generator support
a6289499 VS: Generate ANDROID_GUI executables as app packages
c12e4699 Add 'ANDROID_API' target property to set Android Target API
9a4df52a Add 'ANDROID_GUI' target property to mark Android applications
16569abf cmTarget: Track internally whether platform is Android
ef0fd4f0 VS: Teach vcxproj generation about the Tegra-Android platform
d09b60f5 VS: Detect compiler id of Nsight Tegra-Android toolchains
2f071466 VS: Teach VS >= 10 to recognize CMAKE_SYSTEM_NAME 'Android'
2014-09-30 08:46:27 -04:00
Brad King 7115702f1b Tests: Add test for VS Nsight Tegra generator support
Create a VSNsightTegra test based on the "two-libs" example from the
Android NDK.  Add it whenever testing on a machine with VS 11 or 12
and the NVIDIA Nsight Tegra Visual Studio Edition installed.  Exclude
it when there is a space in the path to the source or build tree because
the tools do not seem to support it.
2014-09-30 08:45:34 -04:00
Brad King cb9e86706c Merge topic 'vs-minor-cleanups'
c655f0c4 VS: Drop GenerateManifest from .vcxproj files for non-MS tools
227a3367 VS: Use case-insensitive check for hlsl,jpg,png,xml file extensions
4a24015a Tests: Always detect VS and SDK availability on Windows
2014-09-29 16:26:07 -04:00
Brad King 4a24015afc Tests: Always detect VS and SDK availability on Windows
Move the detection block out of the Windows >= 8 conditional so it
can be used on other versions.
2014-09-29 16:05:52 -04:00
Tony Kelman e0acdd1a47 Tests: Adjust expected error message in FailedSubmit-ftp
Error message from cygwin's curl (using `--system-libs`) in
CTestTestFailedSubmit-ftp was:

  Failed to connect to  port 21: Connection timed out
        ^^^

Update our regex to match this.
2014-09-26 08:34:14 -04:00
Brad King b234836637 Merge topic 'vs-generator-platform'
be6a555d Tests: Test setting a generator platform in a toolchain file
d506fee8 Tests: Use -A option to pass generator platform selection
11c9ddd6 ExternalProject: Use -A option to pass generator platform
29bd843e CTest: Use -A option to pass generator platform selection
eb7d8156 cmake: Add -A option to specify a generator platform
2014-09-15 10:27:38 -04:00
Brad King 9edf6903e6 Merge topic 'if-sanity'
858d5a0b Fix if() checks of CMAKE_SYSTEM_NAME on Cygwin
e177e7af FPHSA: Avoid if() dereferencing of quoted variable
425acc52 cmcurl: Use if(DEFINED) to simplify conditions
cede5cbd libarchive: Avoid depending on if() to dereference a quoted variable
2d97178b FindGTK2: Avoid depending on if() to dereference a quoted variable
0b12815d Modules/Test*.cmake: Use if(DEFINED) to simplify conditions
188a1f23 If: Introduce policy CMP0054 - don't dereference quoted variables in if()
b900c1cc If: Extract cmConditionEvaluator from if() implementation
2014-09-15 10:27:36 -04:00
Brad King d506fee81c Tests: Use -A option to pass generator platform selection
This is less verbose than defining CMAKE_GENERATOR_PLATFORM.
2014-09-15 10:26:59 -04:00
Brad King 858d5a0b3e Fix if() checks of CMAKE_SYSTEM_NAME on Cygwin
The CMAKE_SYSTEM_NAME is "CYGWIN", but we also define a variable
named "CYGWIN" to "1".  Avoid allowing if() to expand the "CYGWIN"
string as a variable.
2014-09-11 21:23:24 +02:00
Brad King 09ab207c66 Tests: Add generator platform support
Propagate CMAKE_GENERATOR_PLATFORM through the test hierarchy so that all
tests can build with the selected generator platform, if any.
2014-09-10 11:21:50 -04:00
Brad King 1e88ab62e8 Merge topic 'wix-log-on-failure'
4952030c CPackWiX: Attach wix.log on test failure.
2014-09-04 09:48:13 -04:00
Brad King bfc81c5934 Merge topic 'vs-windows-apps'
39fefde2 VS: Add test case for Windows Phone and Windows Store
89da8465 MSVC: Define 'WIN32' for Windows Store and Windows Phone
ed7f085f Help: Add notes for topic 'vs-windows-apps'
dd11ae8f VS: Do not compile C sources as WinRT (#15100)
b8e40538 VS: Mark Windows Phone and Store targets as App Containers
0432f062 VS: Always ignore ole32 on Windows Phone 8.0
e6ff2f8b VS: Generate Windows Metadata for WinRT components
ee48f4c7 VS: Generate Windows Phone and Windows Store projects as Unicode
cb1aceed VS: Add VS_WINRT_COMPONENT property to enable CompileAsWinRT
401269e4 VS: Handle .pfx files explicitly in generator
23782171 VS: Handle AppxManifest sources explicitly in generator
bc373c6d VS: Set Window Phone/Store app type in CMake-generated targets
d89b2889 VS: Mark CMake-generated targets as Utility in .vcxproj files
03ad8f28 CMakeDetermineCompilerABI: Link with standard libraries on MSVC
2014-09-02 10:16:37 -04:00
Gilles Khouzam 39fefde25d VS: Add test case for Windows Phone and Windows Store
Add tests to build for each version of each system when the
corresponding tools are available.
2014-09-02 10:17:03 -04:00
Nils Gladitz 4952030c2e CPackWiX: Attach wix.log on test failure. 2014-09-02 08:53:34 +02:00
Brad King 8c30014982 Merge topic 'vs-masm'
cbd1d42b Help: Add notes for topic 'vs-masm'
0f8522a6 VS: Add MASM support to VS 8 and 9 (#8170, #14984)
a43f4400 VS: Move internal MasmEnabled member up to VS 7 generator
df3b007d VS: Add test for MASM support
e8727449 VS: Populate MASM tool build settings in .vcxproj files
0271a5f9 VS: Manually fix MASM flag table entries
1d662e48 VS: Generate MASM flag tables from MSBuild tool files
4f6940df VS: Fix ASM_MASM support in VS >= 10
d7866c52 ASM_MASM: Fix selection of ml64
0374abdb ASM_MASM: Add preprocessor definitions to compile lines
5b0a46e1 ASM_MASM: Do not require compiler to be a full path
802dbe52 cmLocalVisualStudio7Generator: Rename local 'lang' var
2014-08-22 10:37:55 -04:00
Brad King 0f8522a6c9 VS: Add MASM support to VS 8 and 9 (#8170, #14984) 2014-08-20 10:22:07 -04:00
Brad King df3b007d7f VS: Add test for MASM support
It is now expected to work with VS >= 10 and MSVC >= 13.1.
2014-08-20 10:19:49 -04:00
Joseph Snyder 6d66e396a1 CTEST: Fix MUMPS file parser and update test
The current file parser for a MUMPS routine uses a period "." as the
one of the signals that a line of MUMPS code is executable.  This is not
a correct assumption.  Add the period to the list of characters that CTest
will not consider the start of a line of code.

Update the test routine to have an entry point with code to match the scenario
mentioned above.
2014-08-15 10:50:36 -04:00
Brad King 3526478cc0 Tests: Activate tests accidentally excluded from Xcode
The generator name is "Xcode", not "XCode".  Fix this typo.  Explicitly
exclude the SubDirSpaces test on Xcode because it does not work.  Also
tell the RunCMake.File_Generate test when Xcode is not multi-config so
it can exlcude the OutputConflict case.

Inspired-by: Daniele E. Domenichelli <daniele.domenichelli@iit.it>
2014-07-17 09:31:53 -04:00
Rolf Eike Beer 92af3664c9 Tests: split the ExternalProject test
Move the subtests that test with local projects into their own test. The reason
is that on slower or crowded machines the test may reach the limit of 25
minutes and therefore fail while it would pass if it was given enough time.
The split is roughly 3:1 with regard to the execution time, with the new
ExternalProjectLocal test being the faster one.
2014-07-03 18:12:08 +02:00
Ben Boeckel 902c90636e Tests: Use add_test(NAME) signature in add_test_macro
This will allow generator expressions to be used in test arguments.
2014-07-01 10:24:48 -04:00
Brad King 57ddde524b Update CDash server URL
It is now at open.cdash.org and does not start in "/CDash".
2014-06-24 13:54:52 -04:00
Brad King 1bd4e006aa Tests: Fix CMAKE_TESTS_CDASH_SERVER parsing
Allow the value to end without a slash and have an empty server path
component.  This is needed to match "http://open.cdash.org" correctly.
2014-06-24 13:54:51 -04:00
Brad King 8be1a711b2 Merge topic 'add_jacoco_coverage_parsing'
558c2190 CTest: Add Jacoco Coverage functionality
2014-06-13 15:45:03 -04:00
Joseph Snyder 558c2190e8 CTest: Add Jacoco Coverage functionality
Add the ability to parse the XML output of the Jacoco tool.

Jacoco (www.eclemma.org/jacoco) is a Java coverage tool.
Add and integrate a class for the parser and
include a test which utilizes the new parser.
2014-06-12 10:38:19 -04:00
Brad King a0861931ea Merge topic 'dev/backtrace-performance'
86be733f cmGeneratorExpression: Add workaround for Borland compiler
3495ab0a tests: update unused variable test expected output
2a1b2d84 backtrace: Convert to local paths in IssueMessage
a0829205 genex: remove the need for backtraces
efc20569 cmake: remove dummy backtraces for IssueMessage
d46c650d cmMakefile: return a backtrace
2014-06-09 10:28:44 -04:00
Nils Gladitz 887532f0f0 CTest: Fix combined inclusive/exclusive label regular expressions 2014-06-06 10:28:18 +02:00
Ben Boeckel 3495ab0a81 tests: update unused variable test expected output
The expected output is now a relative path, not a full path. Update the
pass/fail detection accordingly.
2014-06-05 12:44:19 -04:00
Joseph Snyder 50daf239b0 CTest: Generalize Cobertura coverage format handling
Add support for Cobertura coverage files written by Java.

Add a test which uses the report from a Java run of Cobertura to calculate coverage.

In the documentation of CTEST_COVERAGE_COMMAND, give a sample .sh file to merge
the Cobertura .ser files and generate the XML report from the merged file.
2014-06-04 14:26:19 +00:00
Brad King 9afcecaf32 Tests: Try to make CTestTestTimeout more robust
Write to the timeout test log file before sleeping and flush to be sure
it is created.  Move the check that the after-sleep line is not written
out to the ctest script.  Rename the CheckChild test to TestSleep since
it no longer checks.  Do not try to read the log file if it does not
exist.
2014-05-23 10:30:39 -04:00
Brad King f9871f541d Merge topic 'fix_mumps_coverage'
9ad07fbe CTest: Fix MUMPS coverage parsing and test
2014-05-16 10:21:03 -04:00
Joseph Snyder 9ad07fbeb8 CTest: Fix MUMPS coverage parsing and test
Fix the MUMPS coverage parser:

* Account for tabs after entry points

* Stop double incrementing lines that have explicit calls to the 0 line

* If a line has been previously marked as non executable, but then
  contains a count, increment it an extra one to push it back into
  the executable code set.

Add a custom routine and corresponding coverage files in the test case.
This file is smaller and has cmcov/mcov files that have data for only
that routine.
2014-05-16 10:16:40 -04:00
Stephen Kelly 62a4a67dc5 Add the WriteCompilerDetectionHeader module.
Provide a function to write a portable header to detect compiler
features.  Generate a preprocessor #error for unknown compilers
and compiler versions whose features are not yet recorded.  This
error condition might be relaxed in the future, but for now it
is useful for verification of expectations.
2014-05-14 13:57:30 -04:00
Brad King 65a71a5db2 Merge topic 'ctest-bad-generator'
54111286 ctest_build: Do not crash on bad generator name
2014-05-08 11:27:59 -04:00
Brad King 5411128645 ctest_build: Do not crash on bad generator name
If creation of the global generator fails, return early with an error
message instead of trying to use the generator and crashing.

Add a CTestTestBadGenerator test to cover this case.

Reported-by: Mathieu Malaterre <malat@debian.org>
Bug-Debian: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=747306
2014-05-07 11:02:16 -04:00