Commit Graph

29894 Commits

Author SHA1 Message Date
Matt McCormick 361c199ff6 FindDCMTK: Add reStructuredText formatting. 2016-01-12 15:44:10 -05:00
Matt McCormick d790f4feea FindDCMTK: Keep original copyright notice.
This is a follow-up to 31b4700ed6.
Remove the extra character that was added to ensure the CMake.ModuleNotices
test passes.
2016-01-12 14:45:11 -05:00
Matt McCormick 8c8e53d060 FindDCMTK: Minor documentation grammatical issues.
Also remove CTK integration reference to avoid confusion.
2016-01-12 12:25:15 -05:00
Matt McCormick d50cbbb03d FindDCMTK: Obey QUIET option for find_package. 2016-01-11 16:51:36 -05:00
Jean-Christophe Fillion-Robin 31b4700ed6 FindDCMTK: Improve compatibility with DCMTKConfig.cmake.
This improvement to the FindDCMTK module improves compatibility with recent
DCMTK, which provides a DCMTKConfig.cmake file. See the module comments for a
compatibility matrix.

It also provides DCMTK_INCLUDE_DIRS.

Ported from CommonTK (commontk.org).
2016-01-11 16:51:24 -05:00
Brad King a9e8b123de Merge branch 'fix-CMP0065-NEW-AIX-HP' into release 2015-12-11 09:36:30 -05:00
Marc Chevrier f254276fc1 AIX,HP-UX: Fix RPATH handling when CMP0065 is set to NEW
The CMAKE_SHARED_LIBRARY_LINK_<LANG>_FLAGS setting has always been meant
for flags needed to export symbols from executables for use by shared
library plugins.  Since commit v3.4.0-rc1~58^2~1 (CMP0065: Restrict the
use of CMAKE_SHARED_LIBRARY_LINK_<LANG>_FLAGS, 2015-08-24) this is made
explicit by using the flags only for executables with ENABLE_EXPORTS,
guarded by CMP0065 for compatibility.

On some platforms we were accidentally using this setting to pass other
flags to the linker:

* AIX: -bnoipath, -brtl
* HP-UX: +s, +nodefaultrpath

These flags are incorrectly dropped when CMP0065 is set to NEW.  Fix
this by moving the flags to more appropriate places for linking
executables.
2015-12-11 09:21:47 -05:00
Brad King 5914d5eabc Merge branch 'fix-java-idlj-jarsigner-typos' into release 2015-12-03 09:17:34 -05:00
Marc Chevrier d8b251e2ea FindJava: Fix typos in IdlJ and JarSigner component implementation
Fix typos introduced by commit v3.4.0-rc1~257^2~2 (FindJava: Add support
for idlj and jarsigner tools, 2015-07-31) to correctly report when these
components are found.
2015-12-03 09:17:00 -05:00
Brad King fd7180f0c0 CMake 3.4.1 2015-12-02 08:46:12 -05:00
Brad King 7cb630809d Merge branch 'backport-NIOS2-CPU' into release 2015-12-02 08:41:25 -05:00
Marek Vasut f2ca704cbb Add NIOS2 CPU support
Add necessary bits to support the NIOS2 little-endian CPU.

Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Ley Foon Tan <lftan@altera.com>
Cc: Thomas Chou <thomas@wytron.com.tw>
Cc: Walter Goossens <waltergoossens@home.nl>
2015-12-02 08:40:36 -05:00
Brad King 535760ccb9 Merge branch 'include-for-mode_t' into release 2015-12-02 08:31:49 -05:00
Kylie McClain 001043ac30 Include `sys/types.h` header to get `mode_t`
Do not depend on it being included by other system headers.
It is not included by others on musl-libc, for example.
2015-12-02 08:31:08 -05:00
Brad King 7b13759d5f Merge branch 'reduce-realpath-calls' into release 2015-12-01 11:00:49 -05:00
Brad King 4e3cf8b012 cmOrderDirectories: Reduce repeat realpath() calls
Since commit v3.1.0-rc1~110^2 (Tolerate symlinks during RPATH ordering,
2014-09-09) we call realpath() for every directory ordering constraint
check.  On some platforms/filesystems this is slow, so memoize the
result of the call for each directory.
2015-12-01 11:00:32 -05:00
Brad King 6b18528743 cmOrderDirectories: Factor out directory comparison
Create an `IsSameDirectory` helper method.
2015-12-01 11:00:32 -05:00
Brad King f8deadc16d Merge branch 'reduce-cmState-accumulation' into release 2015-11-30 11:19:01 -05:00
Brad King 5f860ebb67 cmState: Avoid accumulating snapshot storage for short-lived scopes
We need to keep only certain snapshot types and their ancestors.
Also keep those needed for backtraces.
2015-11-25 12:30:13 -05:00
Brad King f21dc4a81c cmState: Avoid accumulating policy stack storage for short-lived scopes
We enforce policy push/pop balance around any scope that pushes/pops a
snapshot.  Therefore a snapshot may never reference entries of
PolicyStack that were created in nested scopes.  Free storage of
short-lived policy stack entries when they are popped.
2015-11-25 10:37:59 -05:00
Brad King bc1d3a8a87 cmListFileCache: Implement cmListFileBacktrace ctor/dtor out-of-line 2015-11-25 10:36:52 -05:00
Brad King 85fe26b5f7 cmLinkedTree: Add Pop method
Add a method to increment an iterator (follow the "up" pointer) to the
previous level in the stack of scopes and free storage of the top of the
stack if possible.  This will allow short-lived scopes to be created and
destroyed by matching Push/Pop pairs without accumulating storage.
2015-11-25 10:33:26 -05:00
Brad King 518d6b22f6 cmLinkedTree: Rename 'Extend' method to 'Push'
Logically the method pushes a nested scope on top of a given scope
because the "up" pointer sequence forms a stack independent of any
other branches of the tree.
2015-11-25 10:23:05 -05:00
Brad King 9ecf8a14fb Merge branch 'fix-find_package-version-file-error-stack' into release 2015-11-25 09:23:13 -05:00
Brad King 32edac6fdd cmState: Enforce policy scope balancing around variable scopes
Everywhere we use cmMakefile::ScopePushPop to manage variable scopes
also expects policy scopes to be balanced.  There is no place that we
use cmMakefile::PolicyPushPop without also using ScopePushPop.  Relieve
PolicyPushPop of responsibility for policy scope balance checks by
moving it to ScopePushPop.
2015-11-24 19:38:36 -05:00
Brad King 0fa7f143a0 cmLocalGenerator: Use ScopePushPop RAII class to manage local variable scopes 2015-11-24 19:38:34 -05:00
Brad King d85c9176ae cmMakefile: Remove unused PolicyPushPop interfaces
The PolicyPushPop constructor arguments and Quiet method were used to
pass non-default arguments to PushPolicy and PopSnapshot, but no clients
use them anymore.
2015-11-24 19:38:33 -05:00
Brad King 8e1be7bf68 cmMakefile: Clarify purpose of method that pops a scope snapshot
The `PopPolicyBarrier` method is actually responsible for closing any
scope opened by creating a snapshot.  Rename it to `PopSnapshot` and add
a comment explaining the purpose of the poilcy-scope-specific part of
the method.
2015-11-24 19:38:31 -05:00
Brad King 62126b67e0 Merge branch 'test-cmake_policy-unmatched' into fix-find_package-version-file-error-stack 2015-11-24 14:09:54 -05:00
Brad King 2e28c619f8 cmState: Skip variable scope snapshots to avoid call stack duplicates
Since commit v3.4.0-rc1~179^2~1 (cmState: Add a VariableScope snapshot
type, 2015-08-23) the snapshot stack may have a VariableScopeType entry.
Skip over these when constructing the call stack, just as we do for
policy scopes.  Otherwise we report the command causing the variable
scope to be entered twice (e.g. find_package while loading a package
version file).
2015-11-24 14:09:27 -05:00
Brad King b219ff94ac Tests: Add case for package version file unmatched policy scope 2015-11-24 14:01:21 -05:00
Brad King 378185fb7f Tests: Add case for unmatched cmake_policy({PUSH,POP}) 2015-11-24 09:30:16 -05:00
Brad King c25d642de3 Merge branch 'test-add_subdirectory-in-function' into release 2015-11-24 09:29:31 -05:00
Brad King 010c595986 Tests: Add case for add_subdirectory inside a function 2015-11-23 10:52:51 -05:00
Brad King 5e3045a749 Merge branch 'revert-compiler-links-statically' into release 2015-11-23 10:19:34 -05:00
Brad King 9682de566e Revert "Disable shared library support when compiler links statically" (#15855)
In commit v3.4.0-rc1~18^2 (Disable shared library support when compiler
links statically, 2015-09-30) we tried to detect when the compiler is
not capable of linking shared libraries (possibly due to flags in use).
However, the approach is not robust against flags like `-nostdlib`.
Revert it for now pending another solution to the original problem.
2015-11-23 10:16:32 -05:00
Brad King e3dfa3506c Merge branch 'backport-fix-autodef-bigobj-64' into release 2015-11-20 08:57:13 -05:00
Bill Hoffman c7ddc5f438 Fix auto export symbols for Dlls containing /bigobj for 64bit builds.
This fixes a bug where 64 bit builds with /bigobj incorrectly determined
that the object files were not 64 bit. This manifested itself with
printf type functions showing up as undefined because the leading
underscore was being removed and should not be removed.
2015-11-20 08:43:58 -05:00
Brad King 16ba21f79a Merge branch 'avoid-divide-by-zero' into release 2015-11-19 13:20:47 -05:00
Ty Smith f5cd92a826 cmELF: Avoid divide by zero if there are no dynamic section entries 2015-11-19 13:20:21 -05:00
Brad King aa0460b34a Merge branch 'fix-forced-toolchain-dialect' into release 2015-11-19 10:28:22 -05:00
Brad King 441dba8032 Project: Guess default standard dialect if compiler was forced (#15852)
Prior to commit v3.4.0-rc1~71^2 (Project: Determine default language
dialect for the compiler, 2015-09-15) we always guessed the default
language standard dialect based on the compiler version.  This was not
reliable so that commit switched to computing the default language
standard dialect while detecting the compiler id.

When a toolchain file uses CMakeForceCompiler to set the compiler id
then the detection does not occur.  Therefore commit v3.4.0-rc1~54^2
(Project: Don't require computed default dialect if compiler was forced,
2015-09-22) made the lack of detection an error only if the compiler was
not forced.  However, this means that projects using CMakeForceCompiler
no longer even get the guess that we had before so <LANG>_COMPILER does
not work.

Due to the sophistication of CMake's compiler detection logic projects
should be ported away from using CMakeForceCompiler.  In the meantime,
restore a guess of the default language standard dialect when the
compiler is forced.
2015-11-19 10:22:35 -05:00
Brad King 59b6d8a81b Merge branch 'backport-android-no-versioned-soname' into release 2015-11-19 08:57:27 -05:00
Brad King 3aec561aa2 Android: Restore generation of non-versioned soname (#15851)
Our check of CMAKE_PLATFORM_NO_VERSIONED_SONAME, originally added by
commit v3.1.0-rc1~416^2 (Add basic Android platform module, 2014-06-06),
was dropped accidentally by commit v3.4.0-rc1~250^2~21
(cmGeneratorTarget: Move GetLibraryNames from cmTarget, 2015-08-04).
Restore the check in the new location of the GetLibraryNames method.
2015-11-19 08:52:40 -05:00
Brad King ce7da2dec4 Merge branch 'FindGTest-avoid-CMP0064' into release 2015-11-18 10:43:56 -05:00
Brad King b5e7b22def FindGTest: Refactor test type checks to avoid cases triggering CMP0064
Update our if() conditions to avoid CMP0064 warnings when `${test_type}`
is equal to `TEST`.

Reported-by: David T. Chen <dchen@mail.nih.gov>
2015-11-18 10:42:55 -05:00
Brad King e32c903057 Merge branch 'fix-ms-manifest-no-linker' into release 2015-11-18 10:14:14 -05:00
Brad King daa72b253a Merge branch 'fix-compute-default-dialect-lto' into release 2015-11-18 10:14:09 -05:00
Brad King c3dc8935ee Make C and C++ default dialect detection robust to advanced optimizations
In commit v3.4.0-rc1~71^2 (Project: Determine default language dialect
for the compiler, 2015-09-15) we added an "INFO:..." string to the
compiler id detection binary.  The value can be optimized out of the
compiler id binary unless we force it to be included by making the
program behavior depend on it at runtime.  Add references to the value
as we do for the other info strings already.

Gentoo-Issue: https://bugs.gentoo.org/show_bug.cgi?id=565744
2015-11-18 10:12:25 -05:00
Brad King ca263d1d71 MSVC: Fix linking with /MANIFEST:NO option
Refactoring in commit v3.4.0-rc1~74^2~1 (MSVC: Rewrite manifest file
handling with Makefile and Ninja, 2015-09-15) broke handling of this
option.  Fix it and add a test case.
2015-11-18 09:31:56 -05:00