Commit Graph

15735 Commits

Author SHA1 Message Date
Brad King cbc9a9514d CMake 3.0.0-rc6 2014-05-22 10:41:12 -04:00
Brad King 0aa41c7b94 Merge branch 'backport-kwsys-cygwin-fixes' into release 2014-05-20 09:49:57 -04:00
Brad King 0c7f84ca41 KWSys Process: Workaround child kill trouble on Cygwin
When we kill a child we send SIGSTOP first so that we can traverse its
child processes recursively.  On unwinding the recursion we then send
SIGKILL.  Current Cygwin has trouble when both signals are sent in quick
succession by the parent process.  Add a usleep(1) after sending the
first signal to give up our time slice and give Cygwin a chance to
process the first signal before sending the second.
2014-05-20 09:48:35 -04:00
Brad King e604209cb9 KWSys SystemTools: Port cygwin path conversion to modern API
The cygwin_conv_to_win32_path function is deprecated in favor of
cygwin_conv_path.  Use the latter.
2014-05-20 09:48:26 -04:00
Brad King 40b9cd0f61 CMP0022: Fix link language propagation in NEW behavior
The languages used in compiling STATIC libraries need to be propagated
to dependents regardless of the settings of INTERFACE_LINK_LIBRARIES or
CMP0022.  They are independent of the libraries in the link interface.

Prior to commit v2.8.12~192^2~2 (Introduce the INTERFACE_LINK_LIBRARIES
property, 2013-06-04) the cmTarget::ComputeLinkInterface code path for
"explicitLibraries" could never be taken for STATIC libraries, so the
logic to propagate languages existed only in the non-explicitLibraries
code path.  After that commit, INTERFACE_LINK_LIBRARIES could be set for
STATIC libraries to cause the "explicitLibraries" code path to be taken.
The commit also left the old non-explicitLibraries code path conditional
on CMP0022 not being set to NEW.  Thus link language propagation was
left missing from two cases by that commit.

The explicitLibraries code path was fixed to propagate languages by
commit v2.8.12~149^2~1 (cmTarget: Fix iface libraries and languages for
static libraries, 2013-07-26).  However, the non-explicitLibraries case
was never taught to propagate languages when CMP0022 is set to NEW.  Fix
that now.  Factor the logic to propagate link languages out of the link
interface libraries conditions so that it always occurs.  Update
Tests/Fortran to set CMP0022 to NEW to test this case (because the test
passes only if link language propagation works).
2014-05-19 09:11:39 -04:00
Brad King 5527cfa002 Merge branch 'fix-atomic-rename-Windows-sharing-violation' into release 2014-05-13 15:25:47 -04:00
Eric Berge 24bd7ae11a cmSystemTools::RenameFile: Retry on Windows ERROR_SHARING_VIOLATION
Add ERROR_SHARING_VIOLATION to the set of errors (previously including
only ERROR_ACCESS_DENIED) that cause a rename (MoveFile) on Windows to
retry.  The condition was observed when two renames to the same target
file name were happening simultaneously.
2014-05-13 15:23:36 -04:00
Brad King b3ebb8f434 CMake 3.0.0-rc5 2014-05-13 09:34:03 -04:00
Brad King 9996b9846d Merge branch 'ninja-intel-linux' into release 2014-05-09 15:20:26 -04:00
Brad King 54535f4730 Ninja: Fix deptype for Intel compiler on Linux
Since commit v3.0.0-rc1~305^2 (Ninja: deptype msvc for Intel's compiler
on Windows, 2013-11-25) we used "deps = msvc" for the Intel compiler.
This is correct only on Windows.  On Linux we still want "deps = gcc".

Fix the logic to use "deps = msvc" when the compiler id or the "simulate
id" is "MSVC".  This will preserve the behavior on Intel for Windows and
fix the behavior on Intel for Linux.  In the future this should be
converted to a platform information module variable.
2014-05-09 15:11:54 -04:00
Brad King 23409f50f1 cmTarget: Evaluate CMP0026 in calling context
This policy should be checked at the call site that tries to access the
LOCATION property, not the directory scope containing the target.
Thread the caller context through cmTarget::GetProperty to use for
checking the policy setting and emitting a diagnostic with proper
backtrace.

Extend the RunCMake.CMP0026 test with a cross-directory case.
2014-05-09 11:12:48 -04:00
Brad King 2e75bf672b cmTarget: Drop unused GetProperty signature
No callers use the second "scope" argument.  Drop this signature and
hard-code the default parameter value internally.
2014-05-09 11:06:13 -04:00
Brad King 890efcb607 Merge branch 'vs-fix-MANIFESTUAC' into release 2014-05-07 15:35:32 -04:00
Eric Berge 9c7f234ceb VS: Fix /MANIFESTUAC:NO linker option mapping
There are no versions of /MANIFESTUAC:NO where addition values are
appended.  Remove both of the MANIFESTUAC:NO entries from our flag
tables and replace them with one which would set EnableUAC to false and
immediately stop processing the /MANIFESTUAC:NO option.
2014-05-07 15:24:08 -04:00
Brad King 74dc1a0be6 Merge branch 'desktop-icon' into release 2014-05-07 15:04:15 -04:00
Johannes Huber 0c4c29edf2 cmake-gui: Fix desktop file icon configuration
Drop the icon file extension.  This fixes the desktop file validation
message:

 "CMakeSetup32.png" for key "Icon" in group "Desktop Entry" is an icon
 name with an extension, but there should be no extension as described in
 the Icon Theme Specification if the value is not an absolute path

Applied-by: Rolf Eike Beer <eike@sf-mail.de>
2014-05-07 15:03:05 -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
Brad King 8c5b9cf915 KWSys SystemInformation: Include backtrace APIs whenever we use them
Include execinfo.h, cxxabi.h, and dlfcn.h under the same conditions
under which we use the APIs from them.  Move their inclusion out of
OS-specific blocks.
2014-05-06 10:05:01 -04:00
Brad King 478356e6d9 Restore --help-full option to output all help manuals
This option was removed during conversion to the reStructuredText
documentation.  Restore it.  Process documentation starting at
Help/index.rst so that all manuals are included in the output.
2014-04-25 08:41:31 -04:00
Brad King 72ab764582 Merge branch 'osx-CFBundle-info-plist' into release 2014-04-22 12:53:51 -04:00
Tim Blechmann 149ce5db5e OS X: Fix Info.plist placement in a CFBundle
Fix cmOSXBundleGenerator::CreateCFBundle to place Info.plist under the
same root directory as the rest of the bundle.  Without this, Info.plist
was placed into CMAKE_BINARY_DIR, not CMAKE_CURRENT_BINARY_DIR because
the target path was not generated correctly.
2014-04-22 12:48:44 -04:00
Brad King 567e4e681c CMake 3.0.0-rc4 2014-04-16 13:24:46 -04:00
Brad King e40fbbb074 Merge branch 'archive-null-error' into release 2014-04-16 13:19:10 -04:00
Brad King b508de59e8 cmArchiveWrite: Handle NULL error string (#14882)
If archive_error_string returns NULL, use a placeholder string instead
of crashing.
2014-04-16 13:13:28 -04:00
Brad King 97243c22b2 Merge branch 'revise-compiler-id-policies' into release 2014-04-02 14:54:17 -04:00
Brad King a41c0a9dcb Do not warn by default when policy CMP0025 or CMP0047 is not set
These policies are triggered by the use of a particular compiler rather
than outdated CMake code in a project.  Avoid warning in every project
that enables a language by not displaying the policy warning by default.
Add variable CMAKE_POLICY_WARNING_CMP<NNNN> to control the warning
explicitly; otherwise enable the warning with --debug-output or --trace.

This breaks with strict policy convention because it does not provide
developers with any warning about the behavior change by default.
Existing projects will continue to build without a warning or change in
behavior.  When a developer changes the minimum required version of
CMake in a project to a sufficiently high value (3.0), the project will
suddenly get the new compiler id and may break, but at least the
breakage comes with a change to the project rather than the version of
CMake used to build it.

Breaking strict policy convention is worthwhile in this case because
very few projects will be affected by the behavior change but every
project would have to see the warning if it were enabled by default.
2014-04-02 14:43:54 -04:00
Nils Gladitz 77b581c2f0 Policies: omit warnings about unset policies when they are actually set to NEW 2014-03-31 09:45:10 -04:00
Brad King a48de7d850 CMake 3.0.0-rc3 2014-03-20 09:26:39 -04:00
Brad King 6a85d624a8 Merge branch 'add_custom_command-no-INTERFACE-lib' into release 2014-03-19 10:57:04 -04:00
Stephen Kelly 2600e923a6 Disallow INTERFACE libraries with add_custom_command(TARGET).
Don't attempt to trace their dependencies.
2014-03-19 15:51:21 +01:00
Stephen Kelly 5f210672da QtDialog: Fix Qt 5 build on non-Windows.
The Qt5Core_QTMAIN_LIBRARIES variable is defined to the Qt5::WinMain
target on Windows, and undefined elsewhere.
2014-03-19 15:38:02 +01:00
Brad King 0f4e8fd0e9 CMake 3.0.0-rc2 2014-03-17 13:14:27 -04:00
Brad King 4a7eb0cdec Merge branch 'CONFIG-LOCATION-CMP0026' into release 2014-03-17 09:35:30 -04:00
Stephen Kelly c903b5319b cmTarget: Restore <CONFIG>_LOCATION to CMP0026 OLD behavior (#14808)
Restore support for the undocumented <CONFIG>_LOCATION target property
removed by commit v3.0.0-rc1~175^2 (cmTarget: Remove support for
<CONFIG>_LOCATION property, 2013-12-30) as part of the CMP0026 OLD
behavior.
2014-03-17 09:30:39 -04:00
Brad King 43b39b1c36 Merge branch 'fix-Qt5-windows-build' into release 2014-03-17 09:24:12 -04:00
Stephen Kelly 61c60b239c QtDialog: Avoid linking to Qt4 WinMain when using Qt 5.
Override the QT_QTMAIN_LIBRARY cache variable with a regular
variable in the Qt 5 configuration. This avoids linking with the
Qt 4 version of the WinMain library.
2014-03-17 14:15:14 +01:00
Stephen Kelly d83245a34f cmTarget: Don't create duplicate backtraces in CMP0046 warning 2014-03-12 18:01:26 +01:00
Brad King ebaa5a6410 Merge branch 'fix-AUTOGEN-custom-command-depends' into release 2014-03-10 09:38:52 -04:00
Brad King 98e3831a67 Merge branch 'fix-policy-scopes' into release 2014-03-10 09:36:28 -04:00
Stephen Kelly 112cba927a QtAutogen: Fix AUTOGEN depends on custom command output with VS.
Visual Studio is handled as a special case for autogen depends. However,
the special handling works only for target dependencies, not file
dependencies output by a custom command.

Use a PRE_BUILD step only if all depends are targets.
2014-03-10 13:01:29 +01:00
Brad King b1bbee3e9a Record more policies on targets when created
Policies CMP0027, CMP0038, and CMP0046 have per-target meaning so
record the policy settings on targets as they are created.
2014-03-06 11:05:47 -05:00
Brad King 51988a4fce Merge branch 'fix-check-build-system-crash' into release 2014-03-04 10:17:05 -05:00
Brad King 3504f9b9ff cmake: Fix --check-build-system argument count check (#14784)
This internal option requires two arguments, not just one.  Fix the
argument count required to recognize the option.
2014-03-04 10:12:08 -05:00
Brad King 42322469e4 Merge branch 'fix-showinclude-warnings' into release 2014-02-26 09:36:02 -05:00
Nils Gladitz 47702b8d49 CTest: exclude /showIncludes notes when scraping logs
My last related commit e5e3f3d4 (CTest: filter /showIncludes output from
ninja compile launcher, 2013-12-01) filtered /showIncludes messages from
the generated xml output but they also need to be filtered in
ScrapeLog().  Otherwise they are being detected as warnings when using
compilers withs english diagnostics.
2014-02-25 11:23:57 -05:00
Brad King b686154b61 Merge branch 'install-FILES-genex' into release 2014-02-24 09:16:36 -05:00
Brad King 6e89c8a5f1 install: Support generator expressions in FILES and PROGRAMS mode
Teach the install(FILES) and install(PROGRAMS) commands to evaluate
generator expressions in the list of files.

Extend the ExportImport test to cover installation cases involving
generator expressions.
2014-02-21 17:05:26 -05:00
Brad King f11f7b34a8 cmInstallFilesGenerator: Add reference to calling cmMakefile
Add a Makefile member to the cmInstallFilesGenerator class and
populate it on construction.  This will be useful in a following
change to evaluate generator expressions with proper context.
2014-02-21 17:05:26 -05:00
Brad King 7cbab17871 Change version scheme to use only two components for feature levels
Historically CMake used three version components for the feature level.
We released new features while incrementing only the third version
component.  Since commit v2.8.2~105^2~4 (New version scheme to support
branchy workflow, 2010-04-23) we used the fourth version component for
bug-fix releases and the development date:

 <major>.<minor>.<patch>[.<tweak>][-rc<n>] = Release
 <major>.<minor>.<patch>.<date>[-<id>]     = Development

This solidified use of three components for the feature level, and was
necessary to continue releasing 2.x versions because:

* Some existing projects performed floating-point comparisons of
  ${CMAKE_MAJOR_VERSION}.${CMAKE_MINOR_VERSION} to 2.x numbers
  so ``x`` could never be higher than 9.

* Version 2.9.<date> was used briefly in post-2.8.0 development in
  CVS prior to the transition to Git, so using it in releases may
  have caused confusion.

Now that we are moving to 3.x versions, these two restrictions go away.
Therefore we now change to use only two components for the feature
level and use the scheme:

 <major>.<minor>.<patch>[-rc<n>] = Release
 <major>.<minor>.<date>[-<id>]   = Development
2014-02-19 09:30:13 -05:00
Brad King 4bb80396e0 CMake 3.0.0-rc1 version update 2014-02-19 09:30:12 -05:00