Commit Graph

4790 Commits

Author SHA1 Message Date
Andreas Mohr bf019d765d Fix spelling and typos (non-binary) 2013-05-07 08:39:19 -04:00
Andreas Mohr ddac8d3d2d Fix spelling and typos (affecting binary data / module messages) 2013-05-07 08:39:19 -04:00
Matt McCormick ecd11a25cc ExternalProject: Allow blank SVN_USERNAME/SVN_PASSWORD (#14128)
With

  SVN_USERNAME ""
  SVN_PASSWORD ""

in an ExternalProject_Add() call, the blank username and password
will be passed to the svn checkout/update step commands.
2013-05-06 13:16:18 -04:00
Brad King a2bc47df1a Recognize ld with toolchain prefix (#13960)
Teach CMAKE_PARSE_IMPLICIT_LINK_INFO to recognize linker invocations
of the form "<toolchain-prefix>-ld" e.g. "x86_64-pc-linux-gnu-ld".
2013-05-06 08:45:34 -04:00
David Golub 40566ef2f8 CPack/NSIS: Obtain path from which to uninstall from registry (#14124)
Without this, when CPACK_NSIS_ENABLE_UNINSTALL_BEFORE_INSTALL is set,
the installer tries to uninstall the old version from the default
installation path for the new version, rather than using the path from
the registry where the old version is installed.
2013-05-02 10:22:20 -04:00
Brad King f9eee7f183 Windows: Search '/' prefix only when cross compiling (#10994)
Commit dac78148 (...makes the mingw cross compiler work out of the
box..., 2007-08-02) added to CMAKE_SYSTEM_PROGRAM_PATH and
CMAKE_SYSTEM_LIBRARY_PATH paths like "/bin" and "/lib" with no Windows
drive letter so that cross-compiling to Windows from Linux would search
these paths under CMAKE_FIND_ROOT_PATH.  Later commit 2a782880 (...use
CMAKE_SYSTEM_PREFIX_PATH when possible, 2008-01-16) generalized this
approach by instead adding "/" to CMAKE_SYSTEM_PREFIX_PATH.

Both commits assumed that the paths would never match anything on
Windows hosts without a drive letter.  However, Windows evaluates these
paths relative to the current working drive letter so find_* commands
may report paths like "/lib/..." when paths like "c:/lib/..." exist on
what happens to be current drive.  Such drive-less paths are not
reliable when the working drive changes, so we should not use them.

Fix WindowsPaths.cmake to add '/' to CMAKE_SYSTEM_PREFIX_PATH only when
cross-compiling to Windows from a non-Windows host.  This will avoid
searching and finding local paths without a drive letter on Windows.
2013-04-25 09:07:45 -04:00
Brad King 52723722c7 Check{C,CXX}CompilerFlag: Test using C locale (#14102)
Set the locale to C while running the compiler for these checks because
we match the resulting warning messages in English only.

Suggested-by: Marco Nolden <m.nolden@dkfz-heidelberg.de>
2013-04-22 08:50:08 -04:00
Marcel Loose 32b582d8a5 FindCUDA: Remove duplicate entries from INCLUDE_DIRECTORIES.
As of CMake 2.8.8, the INCLUDE_DIRECTORIES() command does
not de-duplicate entries. Failure to do so can lead to an extremely
long and repetitive list of -I entries on the command line.
2013-04-18 15:15:51 -04:00
Mathias Gaunard cd2d2480cc FindCUDA: CUDA_COMPUTE_BUILD_PATH uses relative paths to binary dir.
make CUDA_COMPUTE_BUILD_PATH use a relative path to the current
binary directory instead of the current source directory if the source
file considered is in the current binary directory. This is done to
shorten the paths given to the compiler.
2013-04-18 09:07:52 -04:00
Rolf Eike Beer 5be35935dc FindOpenGL: require headers to be found on non-Windows platforms (#13746) 2013-04-17 12:59:52 +02:00
Rolf Eike Beer b10a1713dc FindOpenGL: simplify OS selection code
This was using nested if's, now it uses elseif to flatten that. It also removes
one "if" from the general "else" branch that checks for Apple, as that has it's
own branch anyway and can't be true at this point.
2013-04-17 12:46:13 +02:00
Brad King 5683146185 Xcode: Use explicitFileType to mark source types (#14093)
Replace use of lastKnownFileType with explicitFileType to insist
that Xcode treat the file as we ask.
2013-04-16 15:44:48 -04:00
Alex Neundorf d118b8b389 Add IAR to the CMakeDetectC(XX)CompilerID.c(pp).in
With the AVR IAR compiler this can't be found, but it works e.g. for the
ARM AVR compiler.

Alex
2013-04-15 09:14:35 -04:00
Alex Neundorf d33f40638d Add regexps for the IAR toolchain to the vendor list.
The IAR compilers produce object files where the plain strings at least
sometimes can't be found, see:

  http://www.cmake.org/Bug/view.php?id=10176#c19598

Alex
2013-04-15 09:13:10 -04:00
Alex Neundorf 22fb73a0d6 Add support files for C, C++ and ASM for the IAR toolchain.
The original feature request is at http://www.cmake.org/Bug/view.php?id=10176
Documentation can be found at http://www.iar.com/website1/1.0.1.0/675/1/

Alex
2013-04-15 09:11:17 -04:00
Alex Neundorf efb19b6d45 CMakeSystem: include toolchain file after setting CMAKE_HOST_ (#13796)
Make the CMAKE_HOST_* variables always available in the toolchain file.
They are when the file is included in CMakeDetermineSystem.cmake, and
now also here.  For the non-cross-compiling case this does not change
anything at all.

Alex
2013-04-15 09:06:21 -04:00
Stephen Kelly 8e0da4cddc Fix some copyastos in the DetermineRCCompiler file. 2013-04-14 09:03:48 +02:00
Robin Lee 1b614e018c FindOpenSSL: Fix spelling of CMAKE_CROSSCOMPILING (#14075)
Use of the mis-spelled variable name 'CMAKE_CROSS_COMPILING' was
introduced by commit 4b793ad1 (FindOpenSSL: find cross-compiled OpenSSL
from MinGW, 2012-07-23).  Fix the spelling.
2013-04-12 08:50:06 -04:00
Brad King fb9f73de64 MSVC: Invoke 'link' directly for executables
Update the CMAKE_<LANG>_LINK_EXECUTABLE rule variable to invoke the
linker directly instead of through the compiler.  We already do this
for DLL linking with CMAKE_<LANG>_CREATE_SHARED_LIBRARY.

This also works around a VS 6 cl bug.  While invoking the link tool
internally it fails to correctly quote flags like /pdb:... with spaces
in the value.
2013-04-08 13:03:56 -04:00
Brad King 42ba1b08f3 VS: Separate compiler and linker PDB files (#11899, #14062)
The MS tools create two types of PDB files as explained here:

 http://msdn.microsoft.com/en-us/library/yd4f8bd1%28v=vs.71%29.aspx
 http://msdn.microsoft.com/en-us/library/yd4f8bd1%28v=vs.80%29.aspx
 http://msdn.microsoft.com/en-us/library/yd4f8bd1%28v=vs.90%29.aspx
 http://msdn.microsoft.com/en-us/library/yd4f8bd1%28v=vs.100%29.aspx

One is created by the compiler (/Fd) and the other by the linker (/pdb).
The two options should not specify the same file.  Split them up.

In the VS IDE generators, simply drop ProgramDataBaseFileName to
take the VS default "/Fd$(IntDir)vc$(PlatformToolsetVersion).pdb".

In the Makefile generators, set "/Fd" on the compile line to be
the directory containing object files (with a trailing slash the
compiler will add the "vc$(PlatformToolsetVersion).pdb" filename
automatically).  Drop the /Fd option from the exe link command
line and add "/pdb" instead (already done for dll linking).
Update these rules for both MSVC and Intel tools.

Drop support for PDB_OUTPUT_DIRECTORY and PDB_NAME in STATIC
libraries because the generated .pdb files are only from /Fd
and not real linker-generated .pdb files.  Update documentation to
clarify that the PDB_* properties are only for linker .pdb files.

This regresses the PDBDirectoryAndName test for STATIC libraries.
Since it is not clear at this time what should be done for STATIC
library .pdb files, comment out the relevant portion of the test
and leave a TODO comment.
2013-04-05 11:25:09 -04:00
Eric NOULARD f055c997a5 CPackRPM add /usr/lib64 to the list of builtin to-be-excluded path 2013-04-05 12:53:47 +02:00
Eric NOULARD bac5772b39 CPackRPM add mechanism to remove path from generated list of file in RPM spec.
This fixes bug #0013609, and is a possible solution to #0012864 as well.
The later will be completely fixed in another way. Both approaches
needs to be implemented because the current one is more automatic.

Inspired-By: Ari
2013-04-05 12:43:50 +02:00
Brad King 9cccd2c29c Merge topic 'usr-move-relocatable'
6c613b4 Handle usr-move without forcing absolute paths (#14041)
2013-04-04 14:20:21 -04:00
Brad King 6c613b433c Handle usr-move without forcing absolute paths (#14041)
In commit 0c727b90 (install(EXPORT): Force absolute paths for usr-move,
2013-03-08) and commit d4774140 (configure_package_config_file: force
absolute paths for usr-move, 2013-01-24) we supported Linux
distributions implementing the "/usr move" by assuming that installation
to (/usr)?/lib(64)? represents a non-relocatable system package.

When cross-compiling one may prepare a package for installation into a
system location on a target machine but install the package files on the
*host* machine inside another path for use with CMAKE_FIND_ROOT_PATH.
In this case the package development files must still be relocatable.

Handle "/usr move" with a new approach that works with relocatable
files.  Teach configure_package_config_file and install(EXPORT) to
generate special logic in a package configuration file or targets file
for installation under (/usr)?/lib(64)?.  Teach the file to recognize
when it is loaded through a symlink that refers to the same realpath as
its original install destination.  In such a case, use the original
install prefix.  Otherwise, compute the prefix relative to the current
file location to make it relocatable.
2013-04-03 11:19:47 -04:00
Clinton Stimpson bec8e64c73 Qt4: Fix typo setting a variable for FindThreads.
Fixes bug 14055.
2013-04-02 07:46:51 -06:00
Eric NOULARD 2ef908f911 Add support for componentized USER spec file
CPACK_RPM_USER_BINARY_SPECFILE can now be specified on a per-component
basis using CPACK_RPM_<componentName>_USER_BINARY_SPECFILE.

Inspired-By: Theodore Papadopoulo with its patch proposal.
2013-04-01 16:06:22 +02:00
Brad King 1c7833e7ae Merge topic 'ExactCaseReadmeTxt'
5479251 Modules/readme.txt: make lines a bit shorter for easier readability
140692d Modules/readme.txt: switch from "XXX" to "Xxx"
2013-03-28 10:42:24 -04:00
Brad King 9852d8f42b Merge topic 'use-java-INCLUDE_JARS'
8a2fca8 UseJava.cmake: require explicit request to include jars
2013-03-28 10:42:07 -04:00
Brad King 91461b48c8 Merge topic 'dev/add-isystem-for-clang'
4d668f3 Clang: Add -isystem flag support everywhere
2013-03-28 10:41:55 -04:00
Alex Neundorf 5479251b3b Modules/readme.txt: make lines a bit shorter for easier readability
This patch doesn't make them 79 characters long, but at least gets rid
of really long lines.  While at it, fix spelling of "relevant".

Alex
2013-03-28 10:39:14 -04:00
Alex Neundorf 140692d84c Modules/readme.txt: switch from "XXX" to "Xxx"
Using XXX as name of the package is ambiguous, since it can be
interpreted as "ALLUPPERCASE" and also as "ExactCase (if the name
is already ALLUPPERCASE)".
After extensive discussion there is the conclusion that ExactCase
is intended, so using a CamelCased name makes that more obvious.

Alex
2013-03-28 10:38:49 -04:00
Matthew Woehlke 81b5fb5b0d UseJava.cmake: fully use cmake_parse_arguments in add_jar
Modify add_jar to fully use named arguments, rather than cmake
variables, for specifying output names/directories, etc. For backward
compatibility, the old variables are still honored if set, although
named arguments will override them.
2013-03-28 10:36:33 -04:00
Matthew Woehlke 8a2fca8cd7 UseJava.cmake: require explicit request to include jars
Modify add_jar to (partly) use cmake_parse_arguments, and to require
using the named argument list INCLUDE_JARS to specify jar files (or jar
targets) to use as dependencies when creating a jar. This preserves the
ability to have such, while restoring the historic behavior that jar
files listed as sources are ignored. (The code now explicitly ignores
them, however, rather than adding them to an unused local variable, so
that it is more clear that nothing is being done with them.)
2013-03-28 10:35:42 -04:00
Ben Boeckel 4d668f3311 Clang: Add -isystem flag support everywhere
In GNU.cmake, -isystem is not used if APPLE is set. However, Clang has
pretty much always supported -isystem, so we should always use it.

In the future, GNU.cmake should do a version check to see if -isystem is
supported.
2013-03-28 10:32:24 -04:00
Bill Hoffman 118f741c49 ExternalProject: Retry on a failed git clone
Git sometimes fails to clone repositories due to network outage or
server load.  Try 3 times before giving up.
2013-03-26 10:31:39 -04:00
Brad King 36f158159b Merge topic 'FindImageMagick-v6.8.0-8'
dbd895b FindImageMagick: Search versioned suffixes (#14012)
2013-03-19 15:20:34 -04:00
Brad King b04b8ddfd8 Merge topic 'Ruby-version-selection'
d7e05e4 FindRuby: improve version selection
2013-03-19 15:20:30 -04:00
Brad King cc1c533163 Merge topic 'fix-java-jar-depends'
adeafad UseJava.cmake: accept jar targets in add_jar
53a05b8 UseJava.cmake: fix passing jars to add_jar
45c8e4b UseJava.cmake: simplify path logic
2013-03-19 15:20:22 -04:00
Rex Dieter dbd895b897 FindImageMagick: Search versioned suffixes (#14012)
The parent commit added suffixes for -Q8 and -Q16 but there may also be
versioned suffixes -6.Q8 and -6.Q16.
2013-03-18 16:37:50 -04:00
Rolf Eike Beer d7e05e4144 FindRuby: improve version selection
This will stop e.g. looking for a ruby1.9 executable first if "1.8 EXACT" was
given.
2013-03-18 20:17:08 +01:00
Brad King 526cbafa4e Merge topic 'findqt4-withqt5'
252bfd3 FindQt4: If Qt5 is in CMAKE_PREFIX_PATH, be sure to find Qt4 includes.
2013-03-18 09:42:06 -04:00
Brad King 68e86af6f7 Merge topic 'fix-FPHSA-match'
78e6217 FPHSA: Fix FOUND_VAR check to work with if() auto-dereference
2013-03-18 09:41:59 -04:00
Brad King 758651f124 Merge topic 'set-QT_MAJOR_VERSION'
4aa10cd FindQt4: Set the INTERFACE_QT_MAJOR_VERSION for Qt4::QtCore
2013-03-18 09:41:50 -04:00
Brad King bb260f0927 Merge topic 'set-Qt4_FOUND'
28d14f9 FindQt4: Set the Qt4_FOUND variable if Qt4 is found
2013-03-18 09:41:41 -04:00
Brad King a402bc4d5a Merge topic 'TI_DSP_to_TI'
27e6f6e TI compiler: add automatic detection of prefix and suffixes
b301586 rename TI_DSP toolchain to TI, since it works also for the ARM compiler
12b25df Determine C/CXX/Fortran compiler: fix indentation
7baa55a Determine C/CXX/Fortran compiler: minor restructuring
2013-03-18 09:41:37 -04:00
Brad King 253d7b6fe4 Merge topic 'FindCUDA.cmake/SeparableCompilation'
b6e9b8f FindCUDA: Use the PRE_LINK mode only for MSVC >= 10
2013-03-18 09:41:28 -04:00
Stephen Kelly 78e6217f31 FPHSA: Fix FOUND_VAR check to work with if() auto-dereference
Otherwise, it seems to match on the content of the variable.
2013-03-18 09:35:07 -04:00
Stephen Kelly 4aa10cd6d6 FindQt4: Set the INTERFACE_QT_MAJOR_VERSION for Qt4::QtCore
With a similar commit in Qt 5, this will error at CMake time if
an attempt is made to use

 target_link_libraries(foo Qt4::QtCore Qt5::Core)
2013-03-18 09:31:33 -04:00
Stephen Kelly 28d14f9f13 FindQt4: Set the Qt4_FOUND variable if Qt4 is found
Provide the old QT4_FOUND for compatibility.
2013-03-18 09:30:47 -04:00
Clinton Stimpson 252bfd3379 FindQt4: If Qt5 is in CMAKE_PREFIX_PATH, be sure to find Qt4 includes. 2013-03-18 09:06:53 -04:00
Alex Neundorf 27e6f6ef39 TI compiler: add automatic detection of prefix and suffixes
The TI cross compilers are named e.g. cl6x or armcl, the accompanying
strip and ar have the same prefixes/suffixes.

Alex
2013-03-14 21:48:09 +01:00
Alex Neundorf b3015862e5 rename TI_DSP toolchain to TI, since it works also for the ARM compiler
Additionally, look for a special ar and strip

Alex
2013-03-14 21:47:59 +01:00
Alex Neundorf 12b25df882 Determine C/CXX/Fortran compiler: fix indentation
Alex
2013-03-14 21:47:49 +01:00
Alex Neundorf 7baa55ac0b Determine C/CXX/Fortran compiler: minor restructuring
No functional changes, only change the way the if()-condition works,
to make it easier to add more cases.

Alex
2013-03-14 21:47:38 +01:00
Brad King 192ef7101e Merge topic 'aix-pic'
5c8c1d6 XL: Use -qpic for position independent code (#14010)
2013-03-14 10:00:35 -04:00
James Bigler b6e9b8f127 FindCUDA: Use the PRE_LINK mode only for MSVC >= 10
Use normal custom command dependencies by default.  Use the PRE_LINK
approach only to work around what seems to be a bug in msbuild handling
of custom build rules that chain together.
2013-03-14 09:57:15 -04:00
Matthew Woehlke adeafad488 UseJava.cmake: accept jar targets in add_jar
Modify add_jar to also accepts jars by target name.
2013-03-13 17:34:50 -04:00
Matthew Woehlke 53a05b8f51 UseJava.cmake: fix passing jars to add_jar
Fix setting classpath when encountering a jar argument to add_jar to
actually set the variable that is used to specify the classpath to
javac, instead of just uselessly appending the jar to
CMAKE_JAVA_INCLUDE_PATH (which is never used again at the point where it
is modified). Also, list jars so specified as dependencies of compiling
the java sources for the jar target.
2013-03-13 17:30:16 -04:00
Matthew Woehlke 45c8e4b181 UseJava.cmake: simplify path logic
Move logic to determine relative path to .java file to after the file
extension check, so that it only executes when it is actually used.
2013-03-13 17:29:14 -04:00
Brad King 5c8c1d624d XL: Use -qpic for position independent code (#14010)
According to XL C/C++ V9.0 documentation the default for -qpic/-qnopic
is platform-dependent.  It won't hurt to add the option on platforms
where it is the default, so always add it when we want position
independent code.
2013-03-13 13:49:48 -04:00
Brad King 18029b1e77 Merge topic 'findqt4-withqt5'
161a793 FindQt4: Fix QT_QMAKE{_QMAKE => }_EXECUTABLE typo
2013-03-13 13:37:26 -04:00
Brad King 8128940ac1 Merge topic 'cleanup-early-include-CTest-failure'
d90f49b CTest: Fail early without PROJECT_BINARY_DIR (#14005)
2e1c2bd build_command: Fail early without CMAKE_MAKE_PROGRAM (#14005)
4e5cb37 Refactor RunCMake.build_command test to allow more cases
2013-03-13 13:34:36 -04:00
Brad King edf200a50b Merge topic 'ExternalData-escape-semicolons'
1823ab4 ExternalData: Preserve escaped semicolons during argument expansion
2013-03-13 13:34:06 -04:00
Brad King 161a793781 FindQt4: Fix QT_QMAKE{_QMAKE => }_EXECUTABLE typo
The parent commit accidentally referenced QT_QMAKE_QMAKE_EXECUTABLE
which does not exist.  Use QT_QMAKE_EXECUTABLE instead.

Reported-by: m.hergarden@euphoria-it.nl
2013-03-13 07:54:36 -04:00
Brad King d90f49b894 CTest: Fail early without PROJECT_BINARY_DIR (#14005)
Do not use PROJECT_BINARY_DIR before it is defined.  If it is not
defined when needed, fail with an error message suggesting that the
project() command be invoked first.
2013-03-12 18:20:44 -04:00
Brad King 1823ab4d76 ExternalData: Preserve escaped semicolons during argument expansion
The CMake language implicitly flattens lists so a ";" in a list element
must be escaped with a backslash.  List expansion removes backslashes
escaping semicolons to leave raw semicolons in the values.  Teach
ExternalData_Add_Test and ExternalData_Expand_Arguments to re-escape
semicolons found in list elements so the resulting argument lists work
as if constructed directly by the set() command.

For example:

  ExternalData_Add_Test(Data NAME test1 COMMAND ... "a\\;b")
  ExternalData_Expand_Arguments(Data args2 "c\\;d")
  add_test(NAME test2 COMMAND ... ${args2})

should be equivalent to

  set(args1 "a\\;b")
  add_test(NAME test1 COMMAND ... ${args1})
  set(args2 "c\\;d")
  add_test(NAME test2 COMMAND ... ${args2})

which is equivalent to

  add_test(NAME test1 COMMAND ... "a;b")
  add_test(NAME test2 COMMAND ... "c;d")

Note that it is not possible to make ExternalData_Add_Test act exactly
like add_test when quoted arguments contain semicolons because the CMake
language flattens lists when constructing function ARGN values.  This
re-escape approach at least allows test arguments to have semicolons.

While at it, teach ExternalData APIs to not transform "DATA{...;...}"
arguments because the contained semicolons are non-sensical.

Suggested-by: Jean-Christophe Fillion-Robin <jchris.fillionr@kitware.com>
2013-03-12 16:33:19 -04:00
Brad King 153242601e Merge topic 'findqt4-withqt5'
2112341 FindQt4: Do not use qmake from Qt5
2013-03-12 13:47:08 -04:00
Brad King 28490ecccb Merge topic 'aix-shared-flags'
bce7a2a AIX: Do not use -brtl to create shared libraries (#13997)
2013-03-12 13:47:04 -04:00
Brad King e58117b2ba Merge topic 'Win-HOST_SYSTEM_PROCESSOR'
20681c9 fix Windows processor detection
2013-03-12 13:46:27 -04:00
Brad King 2a3011b536 Merge topic 'FindCUDA.cmake/AddCUDA_cupti_LIBRARY'
c939b49 FindCUDA: Added cupti library.
2013-03-12 13:46:21 -04:00
Brad King 142357ac76 Merge topic 'FindCUDA.cmake/SeparableCompilation'
6a19150 FindCUDA: Add support for separable compilation
2013-03-12 13:46:17 -04:00
Brad King f0e93ce0e5 Merge topic 'FindCUDA.cmake/DontLinkAgainstCUDADriver'
3497bc2 FindCUDA: Remove linkage against CUDA driver library (#13084)
2013-03-12 13:46:13 -04:00
Brad King ff6038057b Merge topic 'FindImageMagick-v6.8.0-8'
5fe9855 FindImageMagick: Search quantum depth suffixes (#13859)
2013-03-12 13:46:10 -04:00
Janne Rönkkö 21123416b4 FindQt4: Do not use qmake from Qt5
Wihtout this, if qmake binary is from Qt5 the FindQt4 fails even though
the Qt4 version of qmake would be installed as qmake-qt4.

On Archlinux this is the case.

Reviewed-by: Clinton Stimpson <clinton@elemtech.com>
2013-03-12 13:43:13 -04:00
James Bigler c939b4948c FindCUDA: Added cupti library.
In addition to adding the cupti library, find_local_library_first has
been renamed to cuda_find_local_library_first with a backward
compatibility macro to find_local_library_first.  Also added
cuda_find_local_library_first_with_path_ext to handle different paths.
2013-03-12 13:38:40 -04:00
James Bigler 6a19150b54 FindCUDA: Add support for separable compilation
This adds a new variable, CUDA_SEPARABLE_COMPILATION, and two new
functions, CUDA_COMPUTE_SEPARABLE_COMPILATION_OBJECT_FILE_NAME and
CUDA_LINK_SEPARABLE_COMPILATION_OBJECTS.

When CUDA_SEPARABLE_COMPILATION is specified then CUDA runtime objects
will be compiled with the separable compilation flag.  These object
files are collected in a target named variable that can be used in
CUDA_COMPUTE_SEPARABLE_COMPILATION_OBJECT_FILE_NAME and
CUDA_LINK_SEPARABLE_COMPILATION_OBJECTS.
2013-03-12 13:38:09 -04:00
James Bigler 3497bc2cee FindCUDA: Remove linkage against CUDA driver library (#13084)
The CUDA runtime library (libcudart) doesn't depend on the driver API
library (libcuda) and shouldn't be used to link CUDA run time codes.
2013-03-12 13:37:44 -04:00
Brad King bce7a2a3a5 AIX: Do not use -brtl to create shared libraries (#13997)
The flag was added incorrectly by commit 9c3a6eb4 (Need -brtl when creating
shared libraries, 2003-05-16).  According to "man ld" the -G option implies
"-brtl -bnortllib ...", -brtl implies "-brtllib", and -brtllib should only be
used for executables, not shared libraries.  Therefore it is incorrect and
unnecessary to specify -brtl explicitly after -G.

Reported-by: Kevin Burge <kcburge@gmail.com>
2013-03-11 09:01:27 -04:00
Rolf Eike Beer 20681c9e05 fix Windows processor detection
Thanks to Martin Koller for this.
2013-03-06 18:04:53 +01:00
Brad King e162d88fbb Merge topic 'GetPrerequisites-objdump'
12fb50d GetPrerequisites: Add documentation for objdump
8eb2fe9 GetPrerequisites: Enable test for BundleUtilities on MinGW
33c94c8 GetPrerequisites: Add support for objdump
5260a86 GetPrerequisites: Move tool search paths up
2013-03-04 15:40:24 -05:00
Brad King caf3f07b83 Merge topic 'non-fatal-Qt4-missing-targets'
4d5230d Only add existing targets to the Qt4 target depends properties.
2013-03-04 15:40:03 -05:00
Brad King 07ee97cace Merge topic 'Win-HOST_SYSTEM_PROCESSOR'
add8d22 properly detect processor architecture on Windows
2013-03-04 15:39:50 -05:00
Michael Tänzer 12fb50da9f GetPrerequisites: Add documentation for objdump
Signed-off-by: Michael Tänzer <neo@nhng.de>
2013-03-01 16:59:49 +01:00
Slava Sysoltsev 5fe9855624 FindImageMagick: Search quantum depth suffixes (#13859)
From ImageMagick's 6.8.0-8 changelog:

  http://www.imagemagick.org/script/changelog.php
  ABI is incompatible if quantum depth change.
  Add abi indication to library name.

Search for library names with -Q16 and -Q8 suffixes.

Reported-by: Evangelos Foutras <evangelos@foutrelis.com>
2013-03-01 08:09:28 -05:00
Michael Tänzer 33c94c82ba GetPrerequisites: Add support for objdump
Make it usable on MinGW without Visual Studio installed.

Signed-off-by: Michael Tänzer <neo@nhng.de>
2013-02-28 09:49:32 -05:00
Michael Tänzer 5260a864f5 GetPrerequisites: Move tool search paths up
Make them usable in the gp_tool selection heuristic.

Signed-off-by: Michael Tänzer <neo@nhng.de>
2013-02-28 09:48:11 -05:00
Stephen Kelly 4d5230d1d8 Only add existing targets to the Qt4 target depends properties.
Qt can be configured in ways which disable certain modules. Make
sure we don't fail on that.
2013-02-26 22:03:04 +01:00
Brad King 9d4394148a Merge topic 'FPHSA_FOUND_VAR_OPTION'
f17711c FPHSA: Convert FOUND_VAR failure test to RunCMake
c1f5780 FPHSA: improve documentation
7bb1abe FPHSA: Add FOUND_VAR option to specify _FOUND variable name
2013-02-25 13:12:05 -05:00
Brad King b887bca6ee Merge topic 'try_compile-targets'
236133e Handle targets in the LINK_LIBRARIES of try_compile.
1c0597c Add a new Export generator for IMPORTED targets.
f2ab17d Keep track of all targets seen while evaluating a genex.
2013-02-25 13:12:02 -05:00
Brad King 20d0b37f4a Merge topic 'generate-export-header-warnings'
1e0891e Removed GenerateExportHeader warnings about old compilers
2013-02-25 13:11:29 -05:00
Brad King 3044443b40 Merge topic 'fix-GEH-docs'
0ebf332 Fix GenerateExportHeader documentation #13936
2013-02-25 13:11:19 -05:00
Rolf Eike Beer add8d22acc properly detect processor architecture on Windows
CMake is usually run as a 32 bit process even on 64 bit Windows, so the
PROCESSOR_ARCHITECTURE environment variable would always return x86. This post
gives a description on how to do it properly:

http://blogs.msdn.com/b/david.wang/archive/2006/03/26/howto-detect-process-bitness.aspx
2013-02-25 16:14:36 +01:00
Stephen Kelly 236133e79e Handle targets in the LINK_LIBRARIES of try_compile.
Imported targets are re-exported so that they can be used by the
try_compile generated code with target_link_libraries.

This makes the use of the cmake_expand_imported_targets macro
obsolete. The macro is not able to expand the generator expressions
which may appear in the IMPORTED_LINK_INTERFACE_LIBRARIES content.
Instead it just sees them as 'not a target'.
2013-02-22 08:35:39 -05:00
Alex Neundorf c1f5780e2d FPHSA: improve documentation
Alex
2013-02-22 08:32:34 -05:00
Alex Neundorf 7bb1abe56a FPHSA: Add FOUND_VAR option to specify _FOUND variable name
In the new mode FPHSA now accepts a FOUND_VAR option, which can be set
either to ExactCase_FOUND or UPPERCASE_FOUND, no other values are
accepted.  Also add tests for that, including failure.

Alex
2013-02-22 08:31:00 -05:00
Marcus D. Hanwell 1e0891e28a Removed GenerateExportHeader warnings about old compilers
These warnings tend to flood the dashboard submissions, and it is doing
what it should (degrade gracefully with older compilers).
2013-02-20 11:48:12 -05:00
Stephen Kelly 0ebf332199 Fix GenerateExportHeader documentation #13936
There is no CMAKE_CURRENT_BUILD_DIR. CMAKE_CURRENT_BINARY_DIR is
the correct variable here.
2013-02-20 09:27:48 +01:00
Neil Carlson c26ac223df NAG: Use -PIC for Fortran position-independent code (#13932)
The Numerical Algorithms Group (NAG) Fortran compiler documents -PIC for
position-independent code.
2013-02-18 13:12:50 -05:00
Brad King e85f1c28d4 Merge topic 'rpath-use-implicit-link-dirs'
95a9c80 Merge topic 'LINK_LIBRARIES-property' into rpath-use-implicit-link-dirs
baa33ac AIX-GNU: Put implicit link directories in runtime libpath (#13909)
171b099 Avoid duplicate RPATH entries
2013-02-15 13:12:31 -05:00
Brad King ffdf57d9f5 Merge topic 'OpenMP-doc'
77fd5e5 FindOpenMP: improve documentation (#13895)
2013-02-15 13:12:21 -05:00
Brad King 3a393cb2da Merge topic 'Embarcadero-linker-flags'
188b0e9 Embarcadero: Fix default link stack/heap flags (#13912)
2013-02-15 13:11:54 -05:00
Brad King 0e2ed9b097 Merge topic 'linked-usage-cleanup'
fde949d Don't add target-specific interface includes and defines to Qt 4 targets.
79ae968 Revert "Add a way to exclude INTERFACE properties from exported targets."
71bf96e Revert "find_package: Reword <package>_NO_INTERFACES documentation"
3df36b5 Revert "Add the $<LINKED:...> generator expression."
e1f9080 Don't populate INTERFACE includes and defines properties in tll.
567c8d1 Revert "Don't allow utility or global targets in the LINKED expression."
a1c4905 Use the link information as a source of compile definitions and includes.
5c9f5e3 Don't use LINKED where not needed.
5b88504 Rename the IncludeDirectoriesEntry to be more generic.
b030323 Fix determination of when we're evaluating compile definitions.
2013-02-15 13:11:04 -05:00
Brad King 95a9c80cac Merge topic 'LINK_LIBRARIES-property' into rpath-use-implicit-link-dirs
Resolve a logical conflict in the signature of cmTarget::GetLinkClosure.
2013-02-14 10:18:31 -05:00
Brad King baa33acbda AIX-GNU: Put implicit link directories in runtime libpath (#13909)
The GNU compiler front-ends on AIX invoke the linker with flags of the
form "-L/path/to/gnu/runtime/lib" to tell ld where to find the language
runtime libraries.  They depend on the default libpath behavior
documented in "man ld" to add the -L paths also to the runtime libpath
so the dynamic loader can find the language runtime libraries.  This
differs from platforms whose linkers have distinct -rpath flags that
non-system compilers can use to tell the dynamic loader where to find
their language runtime libraries.

Since commit 96fd5909 (Implement linking with paths to library files,
2008-01-22) CMake always passes "-Wl,-blibpath:" followed by any
project-defined RPATH plus "/usr/lib:/lib" in order to explicitly set
the runtime libpath and avoid getting all the project -L paths in the
runtime libpath.  The explicit libpath prevents the GNU compiler runtime
library -L paths from being placed in the libpath and then the dynamic
loader fails to find the language runtime libraries.

CMake already detects the implicit link directories for each language
since commit 07ea19ad (Implicit link info for C, CXX, and Fortran,
2009-07-23).  Add the implicit link directories to the explicit runtime
libpath for GNU compilers on AIX to fix this use case.
2013-02-14 10:16:36 -05:00
Rolf Eike Beer 77fd5e51ab FindOpenMP: improve documentation (#13895) 2013-02-13 19:38:00 +01:00
Brad King 188b0e9e37 Embarcadero: Fix default link stack/heap flags (#13912)
Since commit c70beb4b (change the default borland stack size, 2003-05-05),
commit 1b572eb9 (remove -H flags, 2003-05-08), and commit 2d411398 (Stack size
in generated programs should be 10 meg, 2003-06-12) CMake adds link flags to
select a 10MB stack.  At the time this was for consistency with our behavior on
MS, but that was recently removed by commit 51af1da3 (Remove "/STACK:10000000"
from default linker flags, 2012-11-23).

Change our Embarcadero link flags to select the default stack and heap settings
according to the compiler documentation.  This is more reliable than leaving
the flags out completely as it has been reported that the linker does not
always use its documented defaults.

Suggested-by: Mathäus Mendel <contato@mathausmendel.com>
2013-02-13 13:35:25 -05:00
Stephen Kelly fde949d143 Don't add target-specific interface includes and defines to Qt 4 targets.
This is a partial revert of commit c8ee07d0 (FindQt4: Add INTERFACE
includes and defines to Qt4 targets, 2012-12-31).
2013-02-13 15:12:31 +01:00
Brad King f0c4d37ff3 Merge topic 'EclipseDetectClangIncludeDirs'
a396b6e Eclipse: also detect include dirs and macro for clang (#13823)
2013-02-12 14:42:18 -05:00
Brad King 17a6d3c36f Merge topic 'CPackRPM-fixSomeRPMSpecificVarHandling'
9be3da1 CPackRPM fix #13898 uses IF(DEFINED var) to avoid wrong var value logic
2013-02-12 14:42:06 -05:00
Brad King 813b519280 Merge topic 'minor-fixes'
ba48e63 Generate config-specific interface link libraries propeties.
deb51a7 Remove unused forward declarations.
9712362 Don't allow utility or global targets in the LINKED expression.
faa927e Make sure INTERFACE properties work with OBJECT libraries.
510fdcb Whitelist target types in target_{include_directories,compile_definitions}
4de7178 Ensure that the build interface includes have been added.
df74bc3 Only append build interface include dirs to particular targets.
d4e5c67 Don't keep track of content determined by target property values.
1fb545a Move a special case for PIC from the genex to the cmTarget code.
57175d5 Only use early evaluation termination for transitive properties.
4cf161a Fix determination of evaluating link libraries.
3a298c0 Fix generation of COMPILE_DEFINITIONS in DependInfo.cmake.
655e98b Ensure type specific compatible interface properties do not intersect.
46e2896 The COMPATIBLE_INTERFACE does not affect the target it is set on.
5f926a5 Test printing origin of include dirs from tll().
7c0ec75 De-duplicate validation of genex target names.
...
2013-02-11 13:59:48 -05:00
Alex Neundorf a396b6ece2 Eclipse: also detect include dirs and macro for clang (#13823)
Alex
2013-02-10 18:58:27 +01:00
Eric NOULARD 9be3da1c80 CPackRPM fix #13898 uses IF(DEFINED var) to avoid wrong var value logic 2013-02-09 13:42:05 +01:00
Stephen Kelly ba48e63f1e Generate config-specific interface link libraries propeties.
All other properties we generate are config-specific, so it makes
sense to do so here too.
2013-02-09 10:25:35 +01:00
Brad King 7dab997771 Merge topic 'generator-toolset'
56ca8d4 Tests: Add generator toolset support
f36c665 Tests: Consolidate ctest --build-and-test generator options
c0debb1 Merge branch 'master' into generator-toolset
daae0d2 ExternalProject: Propagate the generator toolset
e3841cf CTest: Add options to set generator toolset
f980a80 Xcode: Implement generator toolset selection (#9831, #13802)
650c647 VS: Implement generator toolset selection (#10722, #13774)
4fd5342 CMake: Add -T option to choose a generator toolset
118c32f Merge branch 'xcode-duplicate-flags-13354' into generator-toolset
cf8645e Tests: Run ctest custom commands with VERBATIM
5b2fba5 ExternalProject: Simplify CMake command line generation
2013-02-08 13:38:56 -05:00
Brad King 2cd362d191 Merge topic 'CMAKE_CL_64-CXX'
fe664b5 MSVC: Fix CMAKE_CL_64 in CXX-only projects (#13896)
2013-02-08 13:38:48 -05:00
Brad King 98cca40d9b Merge topic 'implicit-lib-canonical-path'
10e8b2d Normalize full paths in implicit link library list
2013-02-08 13:38:10 -05:00
Brad King fe664b5d1d MSVC: Fix CMAKE_CL_64 in CXX-only projects (#13896)
When CXX is enabled without C then MSVC_CXX_ARCHITECTURE_ID is set
instead but not MSVC_C_ARCHITECTURE_ID.  Test both.
2013-02-07 15:04:06 -05:00
Brad King c0debb1f89 Merge branch 'master' into generator-toolset
We need the latest Tests/CMakeLists.txt so we can refactor all tests.
2013-02-07 11:09:01 -05:00
Brad King daae0d2f5b ExternalProject: Propagate the generator toolset
When the CMAKE_GENERATOR option is given to ExternalProject_Add, look
also for option CMAKE_GENERATOR_TOOLSET to select the value of the cmake
"-T" command-line flag.  When no CMAKE_GENERATOR option is given
explicitly then use the current project's CMAKE_GENERATOR_TOOLSET (since
we already use its CMAKE_GENERATOR).
2013-02-07 11:08:33 -05:00
Brad King f980a80495 Xcode: Implement generator toolset selection (#9831, #13802)
Implement generator toolset selection (cmake -T) for Xcode > 2.0 by
adding the GCC_VERSION build setting to project files.
2013-02-07 11:07:48 -05:00
Brad King 10e8b2da37 Normalize full paths in implicit link library list
Teach CMakeParseImplicitLinkInfo to convert implicit link library full
paths to a canonical form.  This makes them more reproducible in case
different language compiler front-ends add the same library by different
paths e.g. ".../libA.a" and "...//libA.a".

Add a case to the CMake.ImplicitLinkInfo test to cover removal of extra
slashes from both library and directory paths.
2013-02-06 16:22:02 -05:00
Brad King 020525845a Merge topic 'add-ExternalData-module'
5484c60 Merge branch 'vs6-rule-files' into add-ExternalData-module
1fd8d01 ExternalData: Attach download rules to content links in IDEs
a6d3ffc Fix Module.ExternalData test on VS 6
aed590a Fix Module.ExternalData test on Cygwin
06e8ded Merge branch 'fix-atomic-rename-on-Windows' into add-ExternalData-module
e2e0d2e ExternalData: Collapse ../ components in DATA{} paths
ee2abfd ExternalData: Add support for SHA 1 and 2 hash algorithms
aa8b228 ExternalData: Generalize hash algo/ext handling
9e518a8 ExternalData: Allow DATA{} syntax to reference directories
175ed02 ExternalData: Allow ()-groups in series match regex
4befecc ExternalData: Add tests covering interfaces and errors
bcd2580 ExternalData: Improve series matching using an explicit syntax
c0cebcb ExternalData: Remove unused private interface
5275993 ExternalData: Cleanup stray TODO and typo in comments
7bb8344 ExternalData: Do not match directory names when resolving DATA{}
00d801f ExternalData: Remove compatibility with CMake < 2.8.5
...
2013-02-05 14:46:40 -05:00
Brad King 1fd8d017e6 ExternalData: Attach download rules to content links in IDEs
Each data file to be created in the build tree corresponds one-to-one with
a raw file or content link in the source tree.  Use the MAIN_DEPENDENCY of
add_custom_command to attach the build rule to the source tree file.  This
looks much nicer in the IDE project file browser and avoids ".rule" files.
2013-02-04 15:20:03 -05:00
Patrick Gansterer fd2a0d58c5 Set WINCE to 1 when building for WindowsCE
Introduce a new variable WINCE to make the WindowsCE
system more easy to use in if statements.
2013-02-01 23:26:03 +01:00
Brad King 118c32f8f2 Merge branch 'xcode-duplicate-flags-13354' into generator-toolset 2013-01-31 09:58:50 -05:00
Brad King 5b2fba5d40 ExternalProject: Simplify CMake command line generation
Append the source directory to the command line option in a separate
step instead of duplicating it with each possible generator.
2013-01-31 09:58:05 -05:00
Brad King e2e0d2e3c7 ExternalData: Collapse ../ components in DATA{} paths
Relative path components need to be normalized out even if they appear
in the middle of a caller-supplied string.
2013-01-30 14:55:12 -05:00
Brad King ee2abfdc89 ExternalData: Add support for SHA 1 and 2 hash algorithms
Update the Module.ExternalData and RunCMake.ExternalData tests to cover
some of them.
2013-01-30 10:05:07 -05:00
Brad King aa8b2288d3 ExternalData: Generalize hash algo/ext handling
Use private global variables _ExternalData_REGEX_(ALGO|EXT) to match the
possible hash algorithm names and extensions in regular expressions.
Use "file(<algo>)" instead of "cmake -E md5sum" to compute hashes
without a child process and to support more hash algorithms.
2013-01-30 10:05:07 -05:00
Brad King 9e518a8169 ExternalData: Allow DATA{} syntax to reference directories
Use a trailing slash to reference a directory.  Require that a list
of associated files be specified to select from within the directory.
One may simply use DATA{Dir/,REGEX:.*} to reference all files but
get a directory passed on the command line.
2013-01-30 10:05:07 -05:00
Brad King 175ed02207 ExternalData: Allow ()-groups in series match regex
Refactor use of the ExternalData_SERIES_MATCH value to avoid assuming
that it has no ()-groups that interfere with group indexing.

Extend the Module.ExternalData test to cover this case.
2013-01-30 10:05:07 -05:00
Brad King bcd25808ac ExternalData: Improve series matching using an explicit syntax
Automatic series recognition can generate false positives too easily
when the default series configuration is flexible enough to handle
common cases.  Avoid false positives by requiring an explicit syntax to
activate series recognition.  Choose the syntax DATA{<name>,:} to be
short, simple, and look like a vertical ellipsis.

This allows us to improve the default series match configuration.  Allow
series references to contain one of the numbered file names.  Allow '-'
as a separator in addition to '.' and '_'.  Document what the default
configuration matches.  Also provide more options to configure series
<name> parsing.
2013-01-29 15:23:00 -05:00
Brad King 7931d35193 Merge topic 'FindGTK2-lib-order'
399c3b8 FindGTK2: Fix GTK2_LIBRARIES order for static gtk libraries
2013-01-29 14:52:27 -05:00
Brad King c0cebcb19a ExternalData: Remove unused private interface
The 'store' action was part of an older design and is no longer needed.
Remove it.
2013-01-28 15:31:31 -05:00
Brad King 52759930bd ExternalData: Cleanup stray TODO and typo in comments
Remove an outdated TODO line left from earlier designs.
Also fix a typo.
2013-01-28 15:31:31 -05:00
Brad King 7bb8344d50 ExternalData: Do not match directory names when resolving DATA{}
Our content link and object download infrastructure supports only
blobs (files), not trees (directories).  Do not allow references
to end in a slash.
2013-01-28 15:31:02 -05:00
Rodolfo Schulz de Lima 399c3b8e54 FindGTK2: Fix GTK2_LIBRARIES order for static gtk libraries
Before this, when creating GTK2_LIBRARIES, FindGTK2 added the GTK
dependencies in wrong order into GTK2_LIBRARIES.  With dynamic libraries
this is not a major problem, but when linking to static gtk libraries,
the linker outputs a lot of undefined symbols.  Reorder the calls that
append libraries to GTK2_LIBRARIES to respect dependency order.
2013-01-28 08:48:36 -05:00
Alex Neundorf 4cad848369 configure_package_config_file(): extend documentation
Alex
2013-01-24 21:27:32 +01:00
Alex Neundorf 37c4bc1f86 configure_package_config_file(): fix indentation
This is a separate commit, so that the previous commit is smaller.

Alex
2013-01-24 21:18:47 +01:00
Alex Neundorf d4774140b7 configure_package_config_file: force absolute paths for usr-move
The configure_package_config()_file() macro will now use
absolute paths for the PATH_VARS if the Config.cmake file
will be installed into /lib(64) or /usr/lib(64), since due to
the usr-move filesystem changes Config.cmake files installed
there may be found via two paths (once per symlink via
/lib(64) and once via /usr/lib ), and in this case
relative paths break.

Alex
2013-01-24 21:15:58 +01:00
Brad King 00d801fbfe ExternalData: Remove compatibility with CMake < 2.8.5
Now that the module comes in a sufficiently new CMake it does not need
to support older versions.
2013-01-24 13:34:12 -05:00
Brad King ab26249db1 Add ExternalData module
Take files we previously distributed in ITK 4.3.1:

  CMake/ExternalData.cmake
  CMake/ExternalData_config.cmake.in

and add them for distribution in upstream CMake.  Update the copyright
notice block format to follow CMake conventions.
2013-01-24 13:32:17 -05:00
Brad King a37b0e3ebf Merge topic 'qt4-autolink-qtmain'
e3b5eb6 Automatically link to the qtmain library when linking to QtCore.
6c8d8af Add the $<TARGET_POLICY> expression
2013-01-23 15:11:24 -05:00
Stephen Kelly e3b5eb6b23 Automatically link to the qtmain library when linking to QtCore.
When using QAxServer, ensure that the qtmain library is excluded
by reporting an error at CMake time if it is not.
2013-01-23 14:15:41 -05:00
Brad King c0f1af926f ExternalProject: Allow DEPENDS on normal targets (#13849)
The ExternalProject_Add DEPENDS option adds two types of dependencies.
It adds a target-level build order dependency between the external
project target and the named targets.  It also adds a file-level
dependency on the "done" stamp file of the named external project
targets.  Targets not created by ExternalProject_Add have no such stamp
file and no _EP_STAMP_DIR property.  Prior to commit d14c0243 (Refactor
repeated code into function, 2012-04-26) we unconditionally accepted an
empty stamp dir and generated a dependency on a non-existent file.
After that commit we generate an error that no stamp dir is set.

Skip the file-level dependency when the named dependency is not an
external project target in order to allow this use case.  Teach the
ExternalProject test to cover the case.
2013-01-16 10:35:58 -05:00
Brad King feb9ffb681 Merge topic 'qt4-target-depends'
c8ee07d FindQt4: Add INTERFACE includes and defines to Qt4 targets
2013-01-10 10:22:40 -05:00
Brad King 42d9df9f4f Merge topic 'Haiku'
0380f36 FindOpenGL: add Haiku paths
8e9630c FindGLUT: BeOS does not have libXi and libXmu
50bfedf FindLua51: do not try to link libm on BeOS
3d2e6a0 check for Haiku only with __HAIKU__
7a1b961 Haiku no longer defines __BEOS__
ed96d9a bootstrap: use better defaults for Haiku
2013-01-10 10:22:14 -05:00
Stephen Kelly c8ee07d0ad FindQt4: Add INTERFACE includes and defines to Qt4 targets 2013-01-10 09:44:50 -05:00
Brad King bc414aebaf Merge topic 'qt4-version-openssl'
4b9ec00 FindQt4: set QT_VERSION_* variables sooner.
2013-01-08 14:32:22 -05:00
Rolf Eike Beer 0380f36cd8 FindOpenGL: add Haiku paths
Also check the HP-UX specific paths only when on HP-UX.
2013-01-08 00:39:53 +01:00
Rolf Eike Beer 8e9630c719 FindGLUT: BeOS does not have libXi and libXmu 2013-01-07 23:57:07 +01:00
Rolf Eike Beer 50bfedf391 FindLua51: do not try to link libm on BeOS
This includes Haiku, which currently is treated as BeOS. The ComplexOneConfig
test already knew about this.
2013-01-07 23:26:18 +01:00
Rolf Eike Beer 3d2e6a0687 check for Haiku only with __HAIKU__ 2013-01-07 21:52:45 +01:00
Rolf Eike Beer 7a1b961de8 Haiku no longer defines __BEOS__ 2013-01-07 21:20:11 +01:00
Brad King c2cde7f104 Merge topic 'osx-implicit-link-dirs'
cc676c3 OS X: Detect implicit linker framework search paths
2dd67c7 OS X: Detect implicit link directories on modern toolchains
ba58d0c OS X: Link with all framework search paths, not just the last
2013-01-07 14:23:04 -05:00
Brad King 0a097af097 Merge topic 'qt4-target-depends'
57a67bf Qt4: Add module dependencies to the IMPORTED targets
2013-01-07 14:19:36 -05:00
Stephen Kelly 57a67bf27e Qt4: Add module dependencies to the IMPORTED targets
This means for example, that consumers can use:

 target_link_libraries(foo ${QT_QTGUI_LIBRARIES})

instead of also needing to specify all 'public' dependencies:

 target_link_libraries(foo ${QT_QTGUI_LIBRARIES} ${QT_QTCORE_LIBRARIES} )

when using the IMPORTED targets.  Also populate the
IMPORTED_LINK_DEPENDENT_LIBRARIES property so CMake can help the linker
find shared library dependencies.
2013-01-07 14:00:47 -05:00
Clinton Stimpson 4b9ec00d0e FindQt4: set QT_VERSION_* variables sooner.
Set QT_VERSION_* variables sooner so they can be set before
Qt4ConfigDependentSettings.cmake uses them.
2013-01-07 11:06:35 -07:00
Brad King de34995d18 Merge topic 'FixSDLSearchPaths'
fb864d6 FindSDL_...: Restore dropped search paths (#13819)
2013-01-03 13:53:27 -05:00
Benjamin Eikel fb864d6e03 FindSDL_...: Restore dropped search paths (#13819)
Restore the search paths that were accidentally dropped by me in commit
9ed24c53. This was already fixed for FindSDL.cmake in commit 7cb51739.
2012-12-30 16:13:51 +01:00
Eric LaFranchi 3793dca08a CPack: WIX Product Icon, UI Banner, UI Dialog support (#13789) 2012-12-28 15:32:15 -05:00
Brad King cc676c3a08 OS X: Detect implicit linker framework search paths
Previously we hard-coded a list of implicit framework directories but
did not account for CMAKE_OSX_SYSROOT or for changes to the list across
OS X versions.  Instead we should automatically detect the framework
directories for the active toolchain.

The parent commit added the "-Wl,-v" option to ask "ld" to print its
implicit directories.  It displays a block such as:

 Framework search paths:
	/...

Parse this block to extract the list of framework directories.

Detection may fail on toolchains that do not list their framework
directories, such as older OS X linkers.  Always treat the paths

 <sdk>/Library/Frameworks
 <sdk>/System/Library/Frameworks
 <sdk>/Network/Library/Frameworks # Older OS X only
 /System/Library/Frameworks

as implicit.  Note that /System/Library/Frameworks should always be
considered implicit so that frameworks CMake finds there will not
override the SDK copies.
2012-12-11 15:15:52 -05:00
Brad King 2dd67c7ea0 OS X: Detect implicit link directories on modern toolchains
We detect the implicit link directories for the toolchain by adding a
flag to get verbose output from the compiler front-end while linking the
ABI detection binary.  Newer OS X toolchains based on Clang do not add
the implicit link directories with -L options to their internal
invocation of "ld".  Instead they use a linker that comes with the
toolchain and is already configured with the proper directories.

Add the "-Wl,-v" option to ask "ld" to print its implicit directories.
It displays them in a block such as:

 Library search paths:
	/...

Parse this block to extract the implicit link directories.

While at it, remove the checks introduced by commit efaf335b (Skip
implicit link information on Xcode, 2009-07-23) and commit 5195a664
(Skip implicit link info for multiple OS X archs, 2009-09-22).  Discard
the non-system link directories added by Xcode.  Discard all detected
implicit libraries in the multi-architecture case but keep the
directories.  The directories are still useful without the libraries
just to suppress addition of explicit -L options for them.
2012-12-11 15:15:51 -05:00
David Cole 3d0f1957d1 Merge topic 'ConfigHelperMinorCommentFix'
8039bd0 CONFIGURE_PACKAGE_CONFIG_FILE(): improve generated comments
2012-12-11 13:43:59 -05:00
David Cole d73c4057ed Merge topic 'OpenBSD-patches'
f80ccac OpenBSD: Add paths for Qt3/Qt4
2012-12-11 13:43:36 -05:00
Alex Neundorf 8039bd0864 CONFIGURE_PACKAGE_CONFIG_FILE(): improve generated comments
CONFIGURE_PACKAGE_CONFIG_FILE() now additionally generates
"Any changes to this file will be overwritten by the next CMake run
The input file was FooConfig.cmake.in"
into the configured file.

Alex
2012-12-06 22:24:43 +01:00
Amit Kulkarni f80ccac158 OpenBSD: Add paths for Qt3/Qt4
Handle OpenBSD specific paths in Qt3/Qt4, allowing concurrent building
and installation.  Some common programs are renamed with suffixes of
either 3 or 4.  Also, allow qt3/qt4 installed under /usr/local to be
searched and recognized appropriately.
2012-12-05 13:09:43 -05:00
David Cole 2bb2745fa8 Merge topic 'fix-11575-add-wix-support-to-cpack'
a74bd47 CPack: Fix dashboard errors and warnings (#11575)
ad0f735 CPack: Fix dashboard warnings (#11575)
0729ad4 CPack: Fix dashboard errors (#11575)
85baac1 CPack: Add a WiX Generator (#11575)
2012-12-05 10:31:05 -05:00
David Cole 799befa215 Merge topic 'OpenBSD-patches'
2f49b71 OpenBSD: Add path for Lua 5.1
4a015f7 OpenBSD: Add paths for Tcl/Tk 8.4/8.5
51c1119 OpenBSD: Add path for Freetype under X.org
6e7a345 OpenBSD: Add paths for Java 1.6.0/1.7.0 JRE/JDK
288f75e OpenBSD: Install shared libraries without executable permission
2012-12-05 10:30:56 -05:00
David Cole 7b910c0066 Merge topic 'qt4-include-as-system'
691ac05 Qt4: Add SYSTEM option to include_directories.
2012-12-05 10:30:40 -05:00
David Cole ba6e8264fe Merge topic 'ChangeSDLLinkLibraryOrder'
981629f Swap linking order of SDLmain and SDL (#0013769)
2012-12-05 10:30:31 -05:00
David Cole d208d1494f Merge topic 'windows-ce'
6b40e1b VS: Ignore LIBC.lib when linking the CompilerId executables
8e85822 VS: Add the entry point when compiling for WindowsCE
5bf9fd8 VS: Set the correct SubSystem when determinating the CompilerId
2012-12-05 10:30:16 -05:00
David Cole 00dc0ce592 Merge topic 'ninja_launchers'
9fc2e20 Ninja: fix usage of cldeps with ctest launchers
965358f enable CTEST_USE_LAUNCHERS with Ninja too
2012-12-05 10:29:36 -05:00
Amit Kulkarni 2f49b71b65 OpenBSD: Add path for Lua 5.1 2012-12-04 08:36:07 -05:00
Amit Kulkarni 4a015f77e7 OpenBSD: Add paths for Tcl/Tk 8.4/8.5 2012-12-04 08:36:07 -05:00
Amit Kulkarni 51c1119469 OpenBSD: Add path for Freetype under X.org 2012-12-04 08:35:47 -05:00
Amit Kulkarni 6e7a3453b4 OpenBSD: Add paths for Java 1.6.0/1.7.0 JRE/JDK 2012-12-04 08:35:23 -05:00
Amit Kulkarni 288f75edee OpenBSD: Install shared libraries without executable permission 2012-12-04 08:25:33 -05:00
Nils Gladitz 85baac1503 CPack: Add a WiX Generator (#11575)
This new CPack generator produces an *.msi installer file.
Requires having the WiX Toolset installed in order to work
properly.

Download the WiX Toolset installer "WiX36.exe" here:

  http://wix.codeplex.com/releases/view/93929
2012-12-03 11:00:31 -05:00
Clinton Stimpson 691ac05d40 Qt4: Add SYSTEM option to include_directories.
Thanks to Scott Bailey and Benjamin Kloster.
2012-12-03 08:00:07 -07:00
Benjamin Eikel 981629f701 Swap linking order of SDLmain and SDL (#0013769) 2012-12-02 14:32:47 +01:00
Patrick Gansterer 6b40e1ba3e VS: Ignore LIBC.lib when linking the CompilerId executables
Some Windows CE linkers want to link against LIBC.lib, but can not
find them. Since they are not required we can simply ignore it.
2012-11-30 15:17:50 +01:00
Patrick Gansterer 8e85822e2b VS: Add the entry point when compiling for WindowsCE
Set the entry point to mainACRTStartup to make sure that main()
can be found when linking the application to check the compiler.
2012-11-30 15:15:06 +01:00
Patrick Gansterer 5bf9fd8253 VS: Set the correct SubSystem when determinating the CompilerId
Some WinCE linker only work when the subsystem is set to WINDOWSCE.
2012-11-30 14:14:27 +01:00
Mathias Gaunard 965358fcf6 enable CTEST_USE_LAUNCHERS with Ninja too 2012-11-30 03:46:55 +01:00
Alex Neundorf 4809cadfe8 FPHSA: don't succeed if only checking for XX_FOUND (#13755)
This fixes issue #13755.
FPHSA(XX DEFAULT_MSG XX_FOUND)
always succeeded due to the way how the XX_FOUND variable was set.
It was preset to TRUE, and then reset to FALSE if something was missing
(...which had the effect that XX_FOUND itself was already preset when FPHSA
checked whether XX_FOUND is set)

Now XX_FOUND is unset first, and only later on set to TRUE.

Alex
2012-11-29 09:21:18 +01:00
Brad King 581b0c0d07 Merge topic 'windows-ce'
3a1006e VS: Added "Deploy" at project configuration for WindowsCE targets
40c36c9 VS: Make DetermineCompilerId working with WinCE too
038df9e VS: Allow setting the name of the target platform
6fe4fcb VS: Add parser for WCE.VCPlatform.config to read WinCE platforms
2118a20 VS: Support setting correct subsystem and entry point for WinCE
6920fed VS: Change variable type of Name from const char* to string
102521b VS: Change variable type of ArchitectureId from const char* to string
332dc09 VS: Add static method to get the base of the registry
d41d4d3 VS: Add CMAKE_VS_PLATFORM_NAME definition to cmMakefile
14861f8 VS: Remove TargetMachine for linker when checking compiler id
2012-11-28 08:49:56 -05:00
Brad King d5adbbcf9c Merge topic 'winflexbison'
df29336 FindFLEX: Add support for the Win flex-bison distribution
e593f8a FindBISON: Add support for the Win flex-bison distribution
2012-11-27 13:34:57 -05:00
Brad King dcb3701d76 Merge topic 'FindBullet-windows-configs'
f180b24 FindBullet: Search in per-config dirs on Windows (#13738)
2012-11-27 13:34:51 -05:00
Brad King 370a7c5f8c Merge topic 'fix-12437-remove-ridiculously-large-default-stack-size-arg'
51af1da CMake: Remove "/STACK:10000000" from default linker flags (#12437)
2012-11-27 13:34:46 -05:00
Brad King f30393e28a Merge topic 'cpack-nsis64-patches'
6ff730a CPack/NSIS: Add support for 64-bit NSIS (#13203)
51da766 CPack/NSIS: Fix compatibility issues with prerelease NSIS (#13202)
2012-11-27 13:34:13 -05:00
Brad King 7e5f1e2cbd Merge topic 'fix-FindGettext-result'
a7be253 FindGettext: fix overwriting result with empty variable (#13691)
2012-11-27 13:33:56 -05:00
Patrick Gansterer 40c36c9f7b VS: Make DetermineCompilerId working with WinCE too
Add a dummy mainCRTStartup() function, since the linker searches for
it instead of main() and set the CMAKE_SYSTEM_* variables depending
on the MSVC_C_ARCHITECTURE_ID and CMAKE_VS_WINCE_VERSION variables.
2012-11-27 08:31:19 -05:00
Patrick Gansterer df29336893 FindFLEX: Add support for the Win flex-bison distribution
Search for win_flex too and improve version parsing.
2012-11-26 16:30:05 -05:00
Patrick Gansterer e593f8a1cf FindBISON: Add support for the Win flex-bison distribution
Search for win_bison too.
2012-11-26 16:29:38 -05:00
Brad King 84740c7448 Merge branch 'fix-FindGettext-result' into release 2012-11-26 10:22:12 -05:00
Patrick Gansterer d41d4d3d61 VS: Add CMAKE_VS_PLATFORM_NAME definition to cmMakefile
When adding more platforms to the Visual Studio generators a simple
regular expressing can not handle all cases anymore. This new
define holds the name of the Visual Studio target platform.
2012-11-26 09:33:24 -05:00
Alan Witkowski f180b24ef4 FindBullet: Search in per-config dirs on Windows (#13738)
Bullet for windows installs in these per-config paths.
2012-11-26 09:08:14 -05:00
Rolf Eike Beer a7be253418 FindGettext: fix overwriting result with empty variable (#13691)
Remove stray line left by commit 656ab19b (FindGettext: remove code
duplicating FPHSA checks, 2012-09-08).
2012-11-26 08:57:13 -05:00
David Cole 51af1da3d2 CMake: Remove "/STACK:10000000" from default linker flags (#12437)
Modern apps that use multiple threads do NOT want 10 Megabytes of RAM
per thread being used for each thread's stack... Just leave off the
/STACK: argument, and let the compiler use a reasonable default value
for the stack size.

If existing single-threaded apps require the /STACK: argument because
they do need a very large stack size, they can add the flag in their
own CMakeLists files.
2012-11-23 11:41:58 -05:00
Patrick Gansterer 14861f88d2 VS: Remove TargetMachine for linker when checking compiler id
If the TargetMachine isn't defined the linker will choose
the correct target depending on the input file. This helps
us later with additional compiler platforms for WinCE.
2012-11-20 19:15:39 +01:00
David Golub 51da766a6d CPack/NSIS: Fix compatibility issues with prerelease NSIS (#13202) 2012-11-19 19:53:29 -05:00
Brad King cd739794d6 MSVC: Drop default use of /Zm1000 for VS >= 7.1
From the option documentation of VS >= 7.1:

 "In earlier versions of Visual C++, the compiler used several discrete
  heaps, and each had a finite limit. Currently, the compiler dynamically
  grows the heaps as necessary up to a total heap size limit, and requires
  a fixed-size buffer only to construct precompiled headers. Consequently,
  the /Zm compiler option is rarely necessary."
 http://msdn.microsoft.com/en-us/library/bdscwf1c.aspx

Suggested-by: Adam Moss <adam@broadcom.com>
2012-11-16 12:52:59 -05:00
Brad King bd52ff3ac9 Merge topic 'only-git-fetch-when-necessary'
a41d3a4 ExternalProjectUpdateTest: Only support Git 1.6.5 and greater.
de760c1 ExternalProject: Verify when a fetch occurs during update test.
0a34433 ExternalProject: Make sure the ExternalProjectUpdate setup is available.
9b66c8f ExternalProject: Always do a git fetch for a remote ref.
2619f4d ExternalProject: Add tests for UPDATE_COMMAND.
378aa12 ExternalProject: Do smoke tests for Git Tutorial builds.
d075829 ExternalProject: Only run 'git fetch' when required.
2012-11-13 14:31:58 -05:00
Brad King b35ba02d52 Merge topic 'osx-bad-sdk-xcode-3.2.6'
720d790 OS X: Warn about known SDK breakage by Xcode 3.2.6
2012-11-13 14:31:37 -05:00
Brad King 10fd4c9352 Merge topic 'MakeSquish4Work'
b58fd65 Squish: fix new squish_v4_add_test() macro
2012-11-13 14:31:26 -05:00
Matt McCormick 9b66c8faf5 ExternalProject: Always do a git fetch for a remote ref.
Remote git refs always require a git fetch, because the remote may move around
where the ref points.
2012-11-13 13:34:43 -05:00
Brad King 720d790f16 OS X: Warn about known SDK breakage by Xcode 3.2.6
Xcode 3.2.6 is known to break the SDK Library/Frameworks layout.
Detect and warn about this case to tell users to fix their system.

Reported-by: Matthew Brett <matthew.brett@gmail.com>
2012-11-08 09:18:59 -05:00
Alex Neundorf b58fd6569a Squish: fix new squish_v4_add_test() macro
The OUTPUT_NAME target property only returns something if it has been
explicitely set. So use LOCATION, and extract the filename from that.

Alex
2012-11-07 17:48:53 +01:00
Brad King 4b3cb25876 Merge topic 'MakeSquish4Work'
3a0ffa6 Squish: add support for squish 4 (#9734)
2ae9d03 Squish: use ${CMAKE_CURRENT_LIST_DIR}
53c42cb Squish: rename squish_add_test() to squish_v3_add_test() and fix docs a bit
daf1c4d Squish: find executables also under Windows
b878cd6 Squish: use FPHSA
3fe2bc6 Squish: detect version
2012-11-06 14:14:18 -05:00
Brad King 7fa265d79e Merge topic 'TI_DSP_Compiler'
65e9bbe Add support for Texas Instruments DSP compiler (#12405)
2012-11-06 14:14:08 -05:00
Brad King 31da7cce02 Merge topic 'fix-module-includes'
8ebf74b Find* (and some other): use ${CMAKE_CURRENT_LIST_DIR} in include()
2012-11-06 14:14:03 -05:00
Brad King a0074b64fc Merge topic 'deb-rpm-all_components_in_one'
e7e2694 CPack: Fix RPM/Deb package names to not include "ALL_COMPONENTS_IN_ONE"
2012-11-06 14:13:44 -05:00
Brad King b24ebfa157 Merge topic 'fix-13600-better-framework-regex'
89256e0 BundleUtilities: Use a more inclusive REGEX for frameworks (#13600)
2012-11-06 14:13:28 -05:00
Brad King a574752f84 Merge topic 'osx-sysroot-cleanup'
15f5764 OS X: Fix default CMAKE_OSX_SYSROOT with deployment target
2012-11-06 14:13:22 -05:00
Brad King 688631a43b Merge topic 'fix-FindSDL-paths'
7cb5173 FindSDL: Restore accidentally dropped search paths (#13651)
2012-11-06 14:13:18 -05:00
Brad King 6991013ddb Merge topic 'fix-PathScale-compiler-id'
fccf19f Fix PathScale compiler id for Clang-based upstream
2012-11-06 14:12:58 -05:00
Brad King 163802e8a1 Merge topic 'fix-openssl-win'
4a4c0ee FindOpenSSL: also find the non-MD debug libraries for MSVC
894b775 FindOpenSSL: fix library selection on Windows (#13645)
2012-11-06 14:12:54 -05:00
Clinton Stimpson e7e2694823 CPack: Fix RPM/Deb package names to not include "ALL_COMPONENTS_IN_ONE" 2012-11-06 11:50:07 -05:00
Brad King f058b27547 Merge branch 'osx-sysroot-cleanup' into release 2012-11-06 11:21:55 -05:00
Brad King 511f227e13 Merge branch 'fix-FindSDL-paths' into release 2012-11-06 11:21:49 -05:00
Brad King 7998ede985 Merge branch 'fix-PathScale-compiler-id' into release 2012-11-06 11:21:25 -05:00
Alex Neundorf 3a0ffa6225 Squish: add support for squish 4 (#9734)
This patch adds support for Squish 4.x.
The changes are basically what is attached to
http://public.kitware.com/Bug/view.php?id=9734.
When adding a test for squish 4.x, use squish_v4_add_test().

Alex
2012-11-05 19:20:13 +01:00
Alex Neundorf 2ae9d03fa6 Squish: use ${CMAKE_CURRENT_LIST_DIR}
Use ${CMAKE_CURRENT_LIST_DIR} instead of constructing the dir from pieces.

Alex
2012-11-05 19:17:24 +01:00
Alex Neundorf 53c42cb4ea Squish: rename squish_add_test() to squish_v3_add_test() and fix docs a bit
There is still a wrapper macro squish_add_test(), but this now
mentions that you should use squish_v3_add_test() instead.
Also, the docs for the macro were just wrong. They are at least
correct now, but still hard to understand (I don't have squish 3 around,
so I can't improve them).

Alex
2012-11-05 19:17:20 +01:00
Brad King 15f5764e2c OS X: Fix default CMAKE_OSX_SYSROOT with deployment target
Since commit 43b74793 (OS X: Further improve default CMAKE_OSX_SYSROOT
selection, 2012-09-21) we choose a default CMAKE_OSX_SYSROOT only when
one is needed.  However, the change forgot that we require a sysroot
when a deployment target is requested.  Teach Darwin.cmake to choose a
default CMAKE_OSX_SYSROOT when CMAKE_OSX_DEPLOYMENT_TARGET is set.

Reported-by: Matthew Brett <matthew.brett@gmail.com>
Reported-by: Bradley Giesbrecht <pixilla@macports.org>
2012-11-05 10:47:33 -05:00
Brad King 7cb5173969 FindSDL: Restore accidentally dropped search paths (#13651)
Cleanup in commit 9ed24c53 (FindSDL: Remove from find_... calls PATHS
that are set by default, 2012-09-04) accidentally dropped some search
paths.  Restore the dropped PATH_SUFFIXES and add more suffixes needed
to search paths that were previously hard-coded.

Reported-by: Gino van den Bergen <gino@dtecta.com>
2012-11-05 09:47:09 -05:00
Brad King fccf19f49b Fix PathScale compiler id for Clang-based upstream
Upstream PathScale now uses Clang as its front-end.  Test for __PATHCC__
before __clang__.

Reported-by: C. Bergström <cbergstrom@pathscale.com>
2012-11-05 08:33:54 -05:00
Rolf Eike Beer 4a4c0ee780 FindOpenSSL: also find the non-MD debug libraries for MSVC
We already search for them in release mode.
2012-11-05 08:17:02 -05:00
Rolf Eike Beer 894b775fa7 FindOpenSSL: fix library selection on Windows (#13645) 2012-11-05 08:17:02 -05:00
Alex Neundorf daf1c4d5a7 Squish: find executables also under Windows
This is required according to Volker Krause
(see http://public.kitware.com/Bug/view.php?id=9734)

Alex
2012-11-04 19:25:43 +01:00
Alex Neundorf b878cd6fb4 Squish: use FPHSA
Alex
2012-11-04 19:22:27 +01:00
Alex Neundorf 3fe2bc622e Squish: detect version
Alex
2012-11-04 19:19:40 +01:00
Alex Neundorf 65e9bbe78e Add support for Texas Instruments DSP compiler (#12405)
This is for the cl6x compiler from TI, which is used for TI DSPs.
The toolchain can be downloaded for free for Linux and Windows.

Alex
2012-11-04 15:46:57 +01:00
Rolf Eike Beer 8ebf74b02f Find* (and some other): use ${CMAKE_CURRENT_LIST_DIR} in include()
This solves a lots of warnings, e.g. in the FindModulesExecuteAll test. If the
installed version on the system is rather old this may even lead to bugs, e.g.
https://bugs.gentoo.org/show_bug.cgi?id=436540
2012-11-04 05:55:37 +01:00
Matt McCormick d0758290e7 ExternalProject: Only run 'git fetch' when required.
In the current default update step for Git under the ExternalProject_Add
command, a 'git fetch' is always performed, followed by a 'git checkout' and
'git submodule update --recursive'.  However, a 'git fetch' can be time
consuming and requires a network connection.

To save time, we look at the current checked out hash, and only perform the
fetch if required.  This is performed in a CMake script so we can handle
the conditional logic in a cross platform manner.
2012-11-03 17:18:14 -04:00
David Cole 99c95d5e1a Merge topic 'doc-external-language-policy'
854369f Document external language support policy
2012-10-31 16:35:31 -04:00
David Cole 2c3bfb6876 Merge topic 'FindQt-version-selection'
041fb29 FindQt: add some more places to look for Qt3
7bb9395 FindQt: improve version selection
2012-10-31 16:34:20 -04:00
David Cole 0b9dac6cbc Merge topic 'EclipseNoLinkedResources'
fbda958 Eclipse: add switch to disable linked resources (#13189)
2012-10-31 16:33:36 -04:00
David Cole af304a1c6a Merge topic 'FindIcotool'
86a184d Add module FindIcotool
2012-10-31 16:33:15 -04:00
David Cole 0f2735019a Merge topic 'simplify-FreeBSD-shared'
6f68ef4 BSD: Do not require dlfcn.h to build shared libs (#13573)
2012-10-31 16:33:06 -04:00
David Cole 634c8bf49f Merge topic 'FindBoost-cleanup'
0496782 FindBoost: Rewrite documentation
4d92f6c FindBoost: Refactor Boost_FOUND computation and version check
0100f88 FindBoost: Construct a clean Boost_LIBRARIES value
5b9149e FindBoost: Overhaul caching and search repeat behavior
5ec8a69 FindBoost: Use PATH_SUFFIXES to look in "Program Files"
d3260a4 FindBoost: Mark Boost_DIR cache entry as advanced
531612d FindBoost: Remove extra indentation level
2012-10-31 16:32:52 -04:00
Brad King 854369fd45 Document external language support policy
Describe in "Modules/CMakeAddNewLanguage.txt" our policy for external
language support.
2012-10-30 14:02:46 -04:00
Rolf Eike Beer 041fb29bd7 FindQt: add some more places to look for Qt3
Qt3 may be e.g. in /usr/lib64/qt-3 or in /usr/lib/qt3, too.
2012-10-24 20:19:54 +02:00
Rolf Eike Beer 7bb9395974 FindQt: improve version selection
-make "find_package(Qt 3)" work
-if DESIRED_QT_VERSION was set, but only the other Qt major version was found
 don't override the DESIRED_QT_VERSION set by the user
2012-10-24 20:19:50 +02:00
David Cole 89256e03cf BundleUtilities: Use a more inclusive REGEX for frameworks (#13600)
Some frameworks might be built with the library right at the root
of the framework rather than down in a versioned sub-folder with
a symlink at the root.

Make one of the slashes in the REGEX optional so BundleUtilities
can still properly work with such frameworks ... even if they are
weird. ;-)

Thanks to Tobias Hieta for the bug report and for trying out the fix
before I pushed this commit.
2012-10-23 18:10:28 -04:00
David Cole 23a257628b Merge topic 'test-SelectLibraryConfigurations'
a22f4fa SelectLibraryConfigurations: fix for release and debug libs being the same
5052fbc SelectLibraryConfigurations: add testcase
2012-10-23 16:37:37 -04:00
David Cole c26373f6ca Merge topic 'fix-SelectLibraryConfigurations-regression'
1cd2ec1 SelectLibraryConfigurations: Fix foreach(x IN LISTS ...) syntax
2012-10-23 16:37:28 -04:00
Stephen Kelly dc0b0f6b6d BasicConfigVersion: Make docs refer to the macro, not the module name
The -ExactVersion variant already refers to the macro, and I think
it makes more sense anyway.
2012-10-23 11:08:34 -04:00
Rolf Eike Beer a22f4fabb7 SelectLibraryConfigurations: fix for release and debug libs being the same 2012-10-21 15:24:25 +02:00
Thomas Arcila 1cd2ec1072 SelectLibraryConfigurations: Fix foreach(x IN LISTS ...) syntax
In commit 5797512c (SelectLibraryConfiguration: generate correct output
when input vars are lists, 2012-07-28) the "IN" keyword was left out.
2012-10-19 13:47:26 -04:00
Alex Neundorf fbda95883c Eclipse: add switch to disable linked resources (#13189)
Eclipse may get confused by these linked resources, because it sees
the same source file multiple times then and doesn't recognize
that it's the same file actually.

Alex
2012-10-17 23:45:02 +02:00
David Cole 7ded904329 Merge topic 'refactor-CTestUseLaunchers'
d63eb0b CTest: Ensure CTEST_USE_LAUNCHERS behaves nicely in Superbuild setup
2012-10-17 16:45:03 -04:00
David Cole e8b1c1ffc0 Merge topic 'fix-13578-wrong-reg-key'
12c092c NSIS: Fix incorrect uninstall registry key name (#13578)
2012-10-17 16:44:33 -04:00
David Cole 0ef55608e6 Merge topic 'fix-postgres-debian'
4cbc1e5 Find PostgreSQL headers on Debian
2012-10-17 16:44:25 -04:00
Jean-Christophe Fillion-Robin d63eb0be20 CTest: Ensure CTEST_USE_LAUNCHERS behaves nicely in Superbuild setup
When building a project relying on External projects, the launchers were
not used in subprojects built without testing enabled. This was preventing
errors and warnings associated with these subprojects from being
reported on the dashboard.

This commit allows enabling the launchers independently of the value of
"BUILD_TESTING" using one of these two approaches:

1) By setting both CTEST_USE_LAUNCHERS and the env variable
"CTEST_USE_LAUNCHERS_DEFAULT" to 1 in the ctest dashboard driver scripts.

2) By enabling the variable CTEST_USE_LAUNCHERS in the ctest dashboard
driver script and also by ensuring every external project passes the option
-DCMAKE_PROJECT_<projectname>_INCLUDE:FILEPATH=${CMAKE_ROOT}/Modules/CTestUseLaunchers.cmake
2012-10-16 15:27:59 -04:00
Aleksey Avdeev 86a184d8bb Add module FindIcotool
This module looks for icotool.

Signed-off-by: Aleksey Avdeev <solo@altlinux.ru>
2012-10-16 16:06:32 +04:00
David Cole 12c092cf67 NSIS: Fix incorrect uninstall registry key name (#13578)
Thanks to Alexander for the bug report.
2012-10-16 07:53:59 -04:00
Pere Nubiola i Radigales 4cbc1e5682 Find PostgreSQL headers on Debian
Fixes Debian bug 665721 (http://bugs.debian.org/665721)
2012-10-15 21:28:20 +02:00
Brad King 71491bbe8f FortranCInterface: Pass all flags to VERIFY project (#13579)
Teach FortranCInterface_VERIFY to build the test project in a specific
configuration and pass all flags for that configuration.  This ensures
that any modifications made by the user or project to the flag are used in
the test project consistently.
2012-10-10 15:42:55 -04:00
Brad King fb4de4495d Merge topic 'DocumentCMakeFindPackageName'
e2b1630 Document CMAKE_FIND_PACKAGE_NAME
2012-10-09 08:39:25 -04:00
Brad King 6f68ef426e BSD: Do not require dlfcn.h to build shared libs (#13573)
Remove ancient checks left from commit f5d95fb0 (Complete rework of
makefile generators expect trouble, 2002-11-08).  Modern FreeBSD and
NetBSD platforms support shared libraries.  When cross-compiling the
/usr/include/dlfcn.h may not exist on the host but the toolchain still
supports shared libraries.
2012-10-05 10:08:28 -04:00
Alex Neundorf e2b1630830 Document CMAKE_FIND_PACKAGE_NAME
Alex
2012-10-04 21:54:40 +02:00
Philip Lowman 0594bee578 FindGTK2: Update local changelog 2012-10-03 05:03:53 -04:00
Philip Lowman 8093f6cede FindGTK2: #12596 Missing paths for FindGTK2 on NetBSD 2012-10-03 04:57:45 -04:00
Philip Lowman 06638039aa FindGTK2: #12049 fix detection of header files on multiarch systems 2012-10-03 04:52:35 -04:00
Philip Lowman b74267745b FindGTK2: Rollback lib64 changes which broke header file finding
The changes in "use PATH_SUFFIXES to simplify find_* calls" on 8/14
regressed important functionality in FindGTK for using find_path to
locate header files in <prefix>/lib/<gtk_package>/include.

The find_path function doesn't search <prefix>/lib only <prefix>/include.
2012-10-03 04:45:22 -04:00
Brad King 47e50423bf Merge topic 'ninja-LIBPATH'
1e47ccb Ninja: add option to enforce usage of response files
e31df03 Ninja: move <OBJECTS> in front of the first linker option
8d674e7 Ninja: move -LIBPATH behind -link option
2012-10-02 10:07:32 -04:00
Brad King 851a3a0b75 Merge topic 'ninja-link-rsp-expand'
dbd99d6 Revert "Ninja: don't expand any rsp files"
f1670ab Ninja: don't confuse ninja's rsp files with nmake's
2012-10-02 10:06:54 -04:00
Brad King 3aa15d62f8 Merge topic 'FindCURL-libcurl'
708b53e FindCURL: Find older MSVC prebuilts
2012-10-02 10:06:37 -04:00
Peter Kümmel e31df03939 Ninja: move <OBJECTS> in front of the first linker option
In the response file also linker options could be passed,
and because <OBJECTS> is replaced by a response file, it
is necessary that no compiler option follows <OBJECTS>.
2012-10-01 17:06:38 -04:00
Bill Hoffman dbd99d6fbb Revert "Ninja: don't expand any rsp files"
This reverts commit 5598d9b2a0.

Since commit f1670ab1 (Ninja: don't confuse ninja's rsp files with
nmake's, 2012-09-26) Ninja generator response files are placed in
CMakeFiles/ so the previously existing check already avoids expanding
them.
2012-10-01 17:06:37 -04:00
Brad King 15cc55fe08 Merge topic 'documentation-cleanup'
4ad0233 Remove period at the end of the check message.
50b1ea5 Fix minor typos.
19c3206 Remove unused parameter marker and the unused parameter.
9d462b2 Document that generator expressions can be used in target properties.
daf88c3 Fix punctuation in some variables documentation.
3172cde Fix the layout of the generator expression documentation.
2012-10-01 14:05:44 -04:00
Brad King 49c7b649f9 Merge topic 'export-sets'
80112da Merge topic 'AutomocUseTargetProperties' into export-sets
955b966 exports: add a test for exporting dependent targets
6f50a04 exports: define a CMAKE_FIND_PACKAGE_NAME var set by find_package()
0cfd055 exports: move the handling of missing targets into subclasses
190f2c8 exports: fix build with MSVC6
8b5f448 exports: first try at error handling if a target is missing
87f4c01 exports: accept a missing target if it is exported exactly once
999061a exports: store pointers to all installations of each export set
64b3a6c exports: cmGlobalGenerator::ExportSets destructor will clear it
81cdab5 exports: Hold an ExportSet pointer in cm*Export*Generator
5c898fb exports: Add cmExportSetMap class
d13ec1a exports: Create class cmExportSet
4e2347c exports: Rename cmGlobalGenerator::AddTargetToExport{s,}
e846e70 exports: Remove cmTargetExport constructor
81c66c8 exports: Move cmTargetExport to a dedicated header file
ae4ab62 find_package: add support for a <package>_NOT_FOUND_MESSAGE variable
...
2012-10-01 14:05:35 -04:00
Andreas Mohr 708b53e709 FindCURL: Find older MSVC prebuilts
Older Windows MSVC CURL prebuilts have the .lib named as "libcurl.lib".
2012-10-01 13:21:46 -04:00
Alex Neundorf 80112da54e Merge topic 'AutomocUseTargetProperties' into export-sets
Conflicts:
	Source/cmGlobalGenerator.h
2012-09-30 10:27:44 -04:00
Stephen Kelly 4ad02332aa Remove period at the end of the check message.
Other messages don't have one.
2012-09-29 18:44:41 +02:00
David Cole 908f46a161 Merge topic 'fix-13549-make-findmpi-quiet'
8b7a5c6 FindMPI: Set correct variables for calls to FPHSA
2012-09-28 15:45:21 -04:00
David Cole af5fac8d17 Merge topic 'ctest-svn-non-interactive'
9ace801 ctest_update: Tell svn not to prompt interactively (#13024)
2012-09-28 15:45:02 -04:00
Alex Neundorf ae4ab62569 find_package: add support for a <package>_NOT_FOUND_MESSAGE variable
If a config-file sets <package>_FOUND to FALSE, it can now give a reason
using the variable <package>_NOT_FOUND_MESSAGE, which is used by cmFindPackage
and FPHSA.

Alex
2012-09-28 09:21:36 -04:00
Alex Neundorf 6508a8c804 Modules/readme.txt: fix typo
Alex
2012-09-28 09:20:38 -04:00
Brad King 0496782418 FindBoost: Rewrite documentation
Write new documentation for this module.  Ensure that it formats
correctly in "cmake --help-module FindBoost" output.  Show the basic
form of calling find_package(Boost).  Document all result variables,
input variables, and cache variables appropriately grouped together.
Explain the search process and how it re-runs when changes are made.
Explain the difference between finding headers/libraries versus finding
a "Boost CMake" package configuraiton file.

Drop the emphasis on Boost_ADDITIONAL_VERSIONS because the
implementation should predict most future versions instead.
2012-09-27 11:08:21 -04:00
Brad King 4d92f6ca33 FindBoost: Refactor Boost_FOUND computation and version check
Construct an initial Boost_FOUND value immediately after searching for
Boost_INCLUDE_DIR.  Base the result only on whether header files for the
requested version were found.  Then after searching for component
libraries update Boost_FOUND based on whether all requested components
were found.
2012-09-27 11:07:51 -04:00
Brad King 0100f88e29 FindBoost: Construct a clean Boost_LIBRARIES value
Construct the value from scratch based on the component library list.
Avoid accumulating values from repeated find_package(Boost) calls.
If Boost is not found, Boost_LIBRARIES should be empty.
2012-09-27 11:04:20 -04:00
Brad King 5b9149e083 FindBoost: Overhaul caching and search repeat behavior
Overhaul the implementation as follows:

(1) Do not cache result variables such as Boost_VERSION,
Boost_LIB_VERSION, Boost_LIBRARY_DIRS, Boost_${COMPONENT}_FOUND,
Boost_${COMPONENT}_LIBRARY, or Boost_LIB_DIAGNOSTIC_DEFINITIONS that are
derived uniquely from other search results.  The user should not edit
them anyway.

(2) Add cache value Boost_LIBRARY_DIR to hold the single directory
expected to contain all libraries.  Once one library is found, search
only that directory for other libraries.

(3) Use the find_library NAMES_PER_DIR option to consider all possible
library names at the same time.

(4) Collect all documented input and cache variables and detect when
they have been changed by the user.  Discard prior search results that
may have been influenced by the changes and search for them again.
Environment variables are not expected to be persistent so use them only
as hints and do not consider changes to them to be meaningful.
2012-09-27 11:04:19 -04:00
Brad King 5ec8a69cac FindBoost: Use PATH_SUFFIXES to look in "Program Files"
The CMake find_path command looks under the proper "Program Files"
directories on Windows with any of the provided PATH_SUFFIXES.  This is
simpler and more robust than directly reading ENV{ProgramFiles}.  Once
Boost_INCLUDE_DIR has been located we already look next to it for the lib
directory anyway, so we do not need special help to find Boost libraries
under "Program Files".
2012-09-27 11:01:11 -04:00
David Cole 8b7a5c6166 FindMPI: Set correct variables for calls to FPHSA
Since FPHSA is called for multiple compiler languages with "MPI_${lang}"
rather than just "MPI", make sure variables for controlling QUIET,
REQUIRED and VERSION are propagated with names prefixed by MPI_${lang}
as well, rather than just MPI.

The find_package call sets up the values of MPI_FIND_REQUIRED and friends,
but these calls to FPHSA need MPI_${lang}_FIND_REQUIRED and friends in
order to function as intended.
2012-09-27 00:41:28 -04:00
Brad King d3260a46be FindBoost: Mark Boost_DIR cache entry as advanced 2012-09-26 11:10:17 -04:00
Brad King 531612d370 FindBoost: Remove extra indentation level
A large portion of the file was still indented for historical reasons.
2012-09-25 17:11:20 -04:00
David Cole 2e489526fa Merge topic 'AutomocUseTargetProperties'
e83cc94 Use the cmGeneratorTarget for the include directories API.
9d8e59d Merge branch 'use-generator-target' into AutomocUseTargetProperties
ea12871 Automoc: also the makefile-COMPILE_DEFINITIONS
894e91a Automoc: do not use DEFINITIONS, but only COMPILE_DEFINITIONS
825d1ab Automoc: fix #13493, use target properties for include dirs
2012-09-25 15:18:43 -04:00
David Cole 021e66a25c Merge topic 'osx-sysroot-cleanup'
df92864 OS X: Ignore MACOSX_DEPLOYMENT_TARGET during Xcode compiler id
e7e613e OS X: Teach deployment target sanity check about SDK names
43b7479 OS X: Further improve default CMAKE_OSX_SYSROOT selection
2690738 OS X: If CMAKE_OSX_SYSROOT is already set do not compute default
7995722 OS X: Simplify selection of CMAKE_OSX_ARCHITECTURES
1786b12 OS X: Allow CMAKE_OSX_SYSROOT to be a logical SDK name
242f673 Tests/Assembler: Use CMAKE_OSX_SYSROOT to generate .s file
a1c032b bootstrap: Suppress CMAKE_OSX_SYSROOT if CFLAGS have -isysroot
230ea21 OS X: Improve default CMAKE_OSX_SYSROOT selection
a0a0877 OS X: Always generate -isysroot if any SDK is in use
33a60e6 Xcode: Remove unused code reading CMAKE_OSX_SYSROOT_DEFAULT
2012-09-25 15:18:24 -04:00
David Cole 7d03885d21 Merge topic 'ImproveFindSDLxxxModules'
68c6b13 FindSDL: Stay compatible with old input variables
9ed24c5 FindSDL: Remove from find_... calls PATHS that are set by default
38a0f71 FindSDL: Add my copyright tag to all FindSDL_* modules
020d213 FindSDL: Add version support
61a566c FindSDL: Format documentation
22154c7 FindSDL: Update documentation
4541c07 FindSDL: Add version support for FindSDL_ttf
a28c247 FindSDL: Use SDL_TTF prefix for variables
9f5dbf4 FindSDL: Update documentation
d83f80d FindSDL: Add version support for FindSDL_mixer
c10b691 FindSDL: Use SDL_MIXER prefix for variables
03dd6cc FindSDL: Pass SDL_SOUND_LIBRARY to FIND_PACKAGE_HANDLE_STANDARD_ARGS
326beca FindSDL: Use same capitalization for FPHSA as file name
cfe5b87 FindSDL: Version support for FindSDL_sound
776d3fe FindSDL: Format the documentation
a5194e2 FindSDL: Add "cmake_minimum_required" to "try_compile" project
...
2012-09-25 15:18:05 -04:00
David Cole 1dd41e6c3d Merge topic 'DetermineVsServicePack2012'
a722780 CMakeDetermineVSServicePack: Visual Studio 2012 added
2012-09-25 15:17:57 -04:00
David Cole f5513f93bf Merge topic 'clang-PIE'
ada9efd Clang: All versions know about -fPIE (#13550)
6e34aea Clang: Split Compiler/Clang* modules out from GNU (#13550)
2012-09-25 15:17:26 -04:00
David Cole 998a17d098 Merge topic 'file-DOWNLOAD-EXPECTED_HASH'
95a0011 file(DOWNLOAD): Change EXPECTED_HASH to take ALGO=value
2012-09-25 15:17:01 -04:00
Benjamin Eikel 68c6b134d0 FindSDL: Stay compatible with old input variables
Suggested-by: David Cole <david.cole@kitware.com>
2012-09-25 13:56:04 -04:00
Benjamin Eikel 9ed24c5316 FindSDL: Remove from find_... calls PATHS that are set by default
Use PATH_SUFFIXES to add SDL parts to standard paths.
2012-09-25 13:55:51 -04:00
Benjamin Eikel 38a0f71574 FindSDL: Add my copyright tag to all FindSDL_* modules 2012-09-25 13:52:48 -04:00
Benjamin Eikel 020d2131ed FindSDL: Add version support 2012-09-25 13:52:43 -04:00
Benjamin Eikel 61a566c02a FindSDL: Format documentation 2012-09-25 13:52:40 -04:00
Benjamin Eikel 22154c7fc2 FindSDL: Update documentation 2012-09-25 13:52:35 -04:00
Benjamin Eikel 4541c07864 FindSDL: Add version support for FindSDL_ttf 2012-09-25 13:52:30 -04:00
Benjamin Eikel a28c24726b FindSDL: Use SDL_TTF prefix for variables 2012-09-25 13:52:27 -04:00
Benjamin Eikel 9f5dbf4497 FindSDL: Update documentation 2012-09-25 13:52:25 -04:00
Benjamin Eikel d83f80d174 FindSDL: Add version support for FindSDL_mixer 2012-09-25 13:52:22 -04:00
Benjamin Eikel c10b69152c FindSDL: Use SDL_MIXER prefix for variables 2012-09-25 13:52:18 -04:00
Benjamin Eikel 03dd6cc4ff FindSDL: Pass SDL_SOUND_LIBRARY to FIND_PACKAGE_HANDLE_STANDARD_ARGS 2012-09-25 13:52:12 -04:00
Benjamin Eikel 326becad31 FindSDL: Use same capitalization for FPHSA as file name 2012-09-25 13:51:53 -04:00
Benjamin Eikel cfe5b87e8c FindSDL: Version support for FindSDL_sound 2012-09-25 13:51:50 -04:00
Benjamin Eikel 776d3fe325 FindSDL: Format the documentation 2012-09-25 13:51:46 -04:00
Benjamin Eikel a5194e2ffb FindSDL: Add "cmake_minimum_required" to "try_compile" project 2012-09-25 13:51:34 -04:00
Benjamin Eikel 2c3b8255c5 FindSDL: Use SDL_IMAGE prefix for varibales
This makes FindPackageHandleStandardArgs and FeatureSummary work correctly.
Keep old variables for compatibility.
Furthermore, format the documentation.
2012-09-25 13:51:19 -04:00
Benjamin Eikel ef5b439cc1 FindSDL: Use prefix SDL_NET, because it matches the file name.
Add new variables, keep the old ones for compatibility.
Format the documentation header.
2012-09-25 13:51:17 -04:00
Benjamin Eikel 34e1a2ae56 FindSDL: Version support for FindSDL_image 2012-09-25 13:51:14 -04:00
Benjamin Eikel a5796112cb FindSDL: Add version support for FindSDL_net 2012-09-25 13:51:06 -04:00
Nils Gladitz 9ace801578 ctest_update: Tell svn not to prompt interactively (#13024)
While at it, add SVNOptions/CTEST_SVN_OPTIONS configuration settings to
add options to all svn invocations instead of just "svn update".
2012-09-25 13:36:47 -04:00
Brad King df928646ba OS X: Ignore MACOSX_DEPLOYMENT_TARGET during Xcode compiler id
Xcode honors this environment variable if the project file does not set
it.  Hide it from Xcode while building the compiler id project.
2012-09-24 14:44:07 -04:00
Brad King e7e613efbf OS X: Teach deployment target sanity check about SDK names
Since commit 1786b121 (OS X: Allow CMAKE_OSX_SYSROOT to be a logical SDK
name, 2012-09-21) we support names like "macosx" or "macosx10.7" as the
specified value of CMAKE_OSX_SYSROOT.  Extend the SDK name->path
conversion to save the original value and also convert into a temporary
variable for the Xcode generator.  Re-implement the deployment target
sanity check to detect the version from the transformed path.
2012-09-22 07:43:43 -04:00
Philip Lowman a722780498 CMakeDetermineVSServicePack: Visual Studio 2012 added 2012-09-21 23:11:18 -04:00
Brad King 43b74793de OS X: Further improve default CMAKE_OSX_SYSROOT selection
Since commit 230ea218 (OS X: Improve default CMAKE_OSX_SYSROOT
selection, 2012-09-21) we always set CMAKE_OSX_SYSROOT if any SDK is
found in order to support Makefile generator builds with Xcode >= 4.3
without the command-line tools installed.  However, in the basic
POSIX-only case of the Makefile generator with command-line tools and no
CMAKE_OSX_ARCHITECTURES we should not select any SDK by default.
2012-09-21 14:45:54 -04:00
Brad King 2690738458 OS X: If CMAKE_OSX_SYSROOT is already set do not compute default
The default computation logic is non-trivial.  Do not bother with it if
the value is already known.
2012-09-21 14:45:54 -04:00
Brad King 7995722e91 OS X: Simplify selection of CMAKE_OSX_ARCHITECTURES
Incremental changes to the logic over time have led to simply
initializing the cache entry with the environment value.
2012-09-21 14:45:53 -04:00
Brad King 1786b121b4 OS X: Allow CMAKE_OSX_SYSROOT to be a logical SDK name
Xcode supports SDKROOT values that just name an SDK rather than
specifying the full path to it.  Recognize these values and handle them.
For Xcode we just put the value directly in the generated project file.
For Makefile generators we ask xcodebuild to provide the full path to
the named SDK.

Suggested-by: Jason DiCioccio <jd@ods.org>
2012-09-21 13:31:46 -04:00
Brad King 230ea218a7 OS X: Improve default CMAKE_OSX_SYSROOT selection
Simplify the search for OSX_DEVELOPER_ROOT and allow it to fail if no
"/Developer" exists.  When it does exist, always find a MacOSX SDK
inside it to use as the default CMAKE_OSX_SYSROOT.  Otherwise set
CMAKE_OSX_SYSROOT to empty.
2012-09-21 08:59:01 -04:00
Brad King a0a0877a1e OS X: Always generate -isysroot if any SDK is in use
Drop the last use of CMAKE_OSX_SYSROOT_DEFAULT.  Replace internal
platform variable CMAKE_${lang}_HAS_ISYSROOT with a more general
CMAKE_${lang}_SYSROOT_FLAG variable.  If the -isysroot flag exists and
CMAKE_OSX_SYSROOT points to an SDK (not "/") then always add it to
compiler command lines.  This is already done in the Xcode IDE.
2012-09-21 08:53:42 -04:00
Brad King ada9efd3af Clang: All versions know about -fPIE (#13550)
The GNU compiler information file tests for GNU >= 3.4 because earlier
versions do not have the flag.  The version number test is not valid for
Clang compiler versions, but we know Clang supports the flag.
2012-09-19 14:08:45 -04:00
Brad King 6e34aea93c Clang: Split Compiler/Clang* modules out from GNU (#13550)
While Clang presents an almost identical interface to GNU there will be
some differences.  Split the compiler information modules to allow
separate rules for Clang.  Start by loading the GNU rules but leave a
place to add Clang-specific information.
2012-09-19 14:06:28 -04:00
Brad King 8fc88b7eb0 Merge topic 'vs-link-rsp'
5598d9b Ninja: don't expand any rsp files
2012-09-19 13:58:12 -04:00
Brad King d58448544c Merge topic 'ExternalProject-DOWNLOAD_NAME'
8da0fe4 ExternalProject: Add DOWNLOAD_NAME option
2012-09-19 13:58:05 -04:00
Brad King fbe7b3cdfc Merge topic 'vs11-express'
7ee3cee VS11: Add VS 2012 Express support (#13348)
e17f345 VS11: Detect VS 2012 Express for default generator (#13348)
2012-09-19 13:57:53 -04:00
Brad King 816e4ca0eb Merge topic 'osx-clang-target-flags'
011d5a4 OS X: Add platform-specific Clang compiler info files (#13536)
2012-09-19 13:57:38 -04:00
Stephen Kelly 9d8e59db71 Merge branch 'use-generator-target' into AutomocUseTargetProperties 2012-09-19 18:33:11 +02:00
Peter Kuemmel 5598d9b2a0 Ninja: don't expand any rsp files 2012-09-19 11:40:47 -04:00
Brad King 95a0011604 file(DOWNLOAD): Change EXPECTED_HASH to take ALGO=value
Make the EXPECTED_HASH option take only a single value instead of two to
avoid handling sub-keyword arguments.  This is also consistent with
URL_HASH in ExternalProject.
2012-09-19 11:31:36 -04:00
David Cole a24830521b Merge topic 'findsdl-unlimited-main-13262'
adf7058 FindSDL: add SDLMAIN_LIBRARY only once (#13262)
2012-09-18 16:42:57 -04:00
David Cole 024bbad230 Merge topic 'cleanup-TLS-and-SSL-interface'
7369a8f file(DOWNLOAD): Make TLS options behave as documented
131d91a Rename SSL terminology to TLS
2012-09-18 16:42:47 -04:00
David Cole 893d84b221 Merge topic 'ExternalProject-check-hashes'
c266461 Add SSL_VERIFYPEER and CAINFO file options to ExternalProject_Add.
beb8a83 ExternalProject: Generalize URL_MD5 option to URL_HASH
2012-09-18 16:42:39 -04:00
David Cole 9642655c5b Merge topic 'openscenegraph-simplify-fphsa'
248db6c FindOpenSceneGraph: simplify by using more features of FPHSA
2012-09-18 16:42:16 -04:00
David Cole a98881ac8f Merge topic 'NewFindGLEWModule'
fbda7bb Initial version of find module
2012-09-18 16:41:44 -04:00
David Cole 3dea63d04d Merge topic 'topics/FindCUDA/Add-CUDA_HOST_COMPILER'
db207e4 FindCUDA: Added CUDA_HOST_COMPILER variable.
2012-09-18 16:41:20 -04:00
Brad King 8da0fe4b53 ExternalProject: Add DOWNLOAD_NAME option
Some download URLs do not have the filename embedded in the url.
Add an interface to specify the local filename explicitly.

Suggested-by: James Goppert <james.goppert@gmail.com>
2012-09-18 16:06:21 -04:00
Brad King 7ee3cee919 VS11: Add VS 2012 Express support (#13348)
Use the registry entries that vsvars32.bat uses to detect the location of
MSBuild.exe in the framework directory.  Invoke MSBuild with the option

 /p:VisualStudioVersion=$version

so it knows from which VS version to load the system build rules.  Teach
cmGlobalVisualStudio11Generator to set its ExpressEdition member using the
registry.
2012-09-18 14:03:02 -04:00
Brad King 011d5a4b47 OS X: Add platform-specific Clang compiler info files (#13536)
Clang has the same interface as GNU except that we do not need to test
for the deployment target and sysroot flags.  Simply set variables

 CMAKE_${lang}_HAS_ISYSROOT
 CMAKE_${lang}_OSX_DEPLOYMENT_TARGET_FLAG

to true because every version of Clang available on OS X supports these
flags.
2012-09-17 15:36:41 -04:00
Rolf Eike Beer adf705863c FindSDL: add SDLMAIN_LIBRARY only once (#13262) 2012-09-17 20:29:29 +02:00
Brad King 131d91a1f9 Rename SSL terminology to TLS
TLS has superseded SSL so rename the recently added file(DOWNLOAD) and
ExternalProject options using the newer terminology.  Drop "CURLOPT"
from names because curl is an implementation detail.
2012-09-14 15:40:09 -04:00
Bill Hoffman c266461084 Add SSL_VERIFYPEER and CAINFO file options to ExternalProject_Add.
This commit adds the ability to turn on and off ssl certificate
authority checking.  It also adds the ability to specify a
certificate authority information file.  This can be done
by setting global cmake variables CMAKE_CURLOPT_CAINFO_FILE
and or CMAKE_CURLOPT_SSL_VERIFYPEER in the project calling
ExternalProject_Add, or by passing those options to individual
ExternalProject_Add calls.
2012-09-12 18:31:52 -04:00
Rolf Eike Beer 248db6c034 FindOpenSceneGraph: simplify by using more features of FPHSA 2012-09-12 21:49:59 +02:00
Brad King 49e1819f0f Merge topic 'FortranCrossCompiling3'
7924aac CMakeDetermineFortranCompiler: add support for cross-compiling (#13379)
2012-09-12 07:51:28 -04:00
Brad King beb8a8309b ExternalProject: Generalize URL_MD5 option to URL_HASH
Add support for SHA algorithms.
2012-09-11 16:00:57 -04:00
Brad King ba72828edd Merge topic 'CPackRPM_handleAttrDirectiveProperly-reloaded'
d8a1dd5 Handles %attr(nnn,-,-) /path/to/file in CPACK_RPM_USER_FILELIST properly.
2012-09-11 15:01:52 -04:00
Brad King 13c36fac62 Merge topic 'include-FPHSA'
ff0d1a8 include FPHSA from current directory in all modules
2012-09-11 15:01:41 -04:00
Brad King 80e7d90a1e Merge topic 'gettext-no-duplicate-FPHSA'
656ab19 FindGettext: remove code duplicating FPHSA checks
2012-09-11 15:01:33 -04:00
Brad King 19fdc456a0 Merge topic 'fix-qt-dbus-on-mac-problem'
5c25df1 FindQt4: Avoid "finding" non-existent library in a .framework
2012-09-11 15:01:29 -04:00
Brad King 53568bd9b5 Merge topic 'findfreetype-13502'
9d91fc6 fix for discovering ft2build.h using FREETYPE_DIR environment var (#13502)
2012-09-11 15:01:25 -04:00
Brad King 047749bfe8 Merge topic 'windows-ce'
28d744c Add WindowsCE platform information files
e7cb805 Add additional architectures to CMakePlatformId.h.in
2012-09-11 15:01:09 -04:00
Alex Neundorf 7924aacbfa CMakeDetermineFortranCompiler: add support for cross-compiling (#13379)
This adds the same support code for cross compiling to
CMakeDetermineFortranCompiler as there is already in the
C and CXX versions of this file.

Alex
2012-09-11 11:20:51 -04:00
Eric NOULARD d8a1dd5865 Handles %attr(nnn,-,-) /path/to/file in CPACK_RPM_USER_FILELIST properly.
This triggered an unknown secondary bug when there is
no ABSOLUTE INSTALL file. This is fixed as well.

This is based on a fix of bug #0013468 from Viktor Dubrovsky.
2012-09-10 22:35:02 +02:00
Rolf Eike Beer ff0d1a8d84 include FPHSA from current directory in all modules 2012-09-09 00:39:47 +02:00
Rolf Eike Beer 656ab19b5c FindGettext: remove code duplicating FPHSA checks 2012-09-08 19:06:44 +02:00
David Cole 5c25df10ac FindQt4: Avoid "finding" non-existent library in a .framework
...if the library file does not exist inside the .framework then do
not allow a library variable to be set to the path to the framework.
Force set it to NOTFOUND instead.
2012-09-06 15:11:54 -04:00
Sergei Nikulov 9d91fc65fa fix for discovering ft2build.h using FREETYPE_DIR environment var (#13502) 2012-09-06 08:57:03 +02:00
Alex Neundorf 894e91a945 Automoc: do not use DEFINITIONS, but only COMPILE_DEFINITIONS
The docs say that this is for cmake 2.4 backwards compatibility only,
so we probably don't need to support it.

Alex
2012-09-05 22:13:30 +02:00
Patrick Gansterer 28d744c9ea Add WindowsCE platform information files
This enables CMake to create Makefiles targeting Windows CE devices.
CMake needs to be run within a cross compile command prompt and requires
a toolchain file which sets CMAKE_SYSTEM_NAME to "WindowsCE" and
optionally CMAKE_SYSTEM_VERSION.
2012-09-05 07:38:45 -04:00
Patrick Gansterer e7cb80556e Add additional architectures to CMakePlatformId.h.in
Detect the MIPS and SHx architecture for MSVC compiler.
2012-09-05 07:33:12 -04:00
David Cole d6643e9ae4 Merge topic 'flex-version-apple'
af06482 FindFLEX: fix version extraction on Apple
2012-09-04 15:47:49 -04:00
David Cole 1f2694f52e Merge topic 'Qt4Macros-fix-resource-parsing'
42bfc5a Read entire Qt4 qrc file when parsing for depends info.
2012-09-04 15:47:33 -04:00
Benjamin Eikel fbda7bb9f2 Initial version of find module 2012-09-01 10:19:12 +02:00
Brad King 25b0d94678 Merge topic 'msvc-compiler-info'
16fa7b7 VS: Fix MSVC_IDE definition recently broken by refactoring
2012-08-31 07:24:53 -04:00
Brad King 16fa7b7395 VS: Fix MSVC_IDE definition recently broken by refactoring
In commit 485a940e (VS: Simplify MSVC version reporting, 2012-08-23) we
accidentally flipped the 0/1 values of MSVC_IDE.  Flip them back and
teach the CheckCompilerRelatedVariables test to check the variable.
2012-08-30 16:18:05 -04:00
Brad King 4f3436dd11 Merge topic 'fix-Qt-casing'
3252149 Fix casing of 'Qt' in docs, comments and user-visible strings.
2012-08-30 11:55:36 -04:00
Brad King 98a6565b60 Merge topic 'mingw-unix-generator'
be9afbf Find mingw's windres also when Unix Makefiles are used
2012-08-30 11:54:32 -04:00
Brad King bbcd177f30 Merge topic 'cmcldeps-icl'
0af27f1 Ninja: also detect /showInclude prefix for icl
2012-08-30 11:54:25 -04:00
Brad King b69cf909b6 Merge topic 'qt4-windows8'
caa9151 Fix errors detecting Qt4 on Windows 8.
2012-08-30 11:54:21 -04:00
Brad King 0d094e3a77 Merge topic 'msvc-compiler-info'
32b7c72 Merge branch 'cmake-platform-info-version' into msvc-compiler-info
f3ddfef Modernize MSVC compiler information files
485a940 VS: Simplify MSVC version reporting
32db033 VS: Remove support for "free" version 2003 tools
2012-08-30 11:06:30 -04:00
Brad King a4c47fe0c7 Merge topic 'cmake-platform-info-version'
e5fee8a Store ABI detection results in compiler information files
3df81b4 Move CMAKE_<LANG>_COMPILER_WORKS to compiler information files
7195aca Make platform information files specific to the CMake version
2012-08-30 11:06:15 -04:00
Brad King 32b7c72623 Merge branch 'cmake-platform-info-version' into msvc-compiler-info
Conflicts:
	Modules/CMakeTestCCompiler.cmake
	Modules/CMakeTestCXXCompiler.cmake
	Modules/Platform/Windows-cl.cmake
2012-08-30 09:45:17 -04:00
Brad King f3ddfef137 Modernize MSVC compiler information files
Remove the old-style "Windows-cl.cmake" and its helper "cl.cmake".  Load
the information through new-style "Platform/Windows-MSVC-<lang>.cmake"
files.  Factor information common to C and CXX into a helper file
"Platform/Windows-MSVC.cmake" loaded from the per-language files.
2012-08-30 09:42:49 -04:00
Brad King 485a940e4c VS: Simplify MSVC version reporting
Teach Windows-cl.cmake to use CMAKE_(C|CXX)_COMPILER_VERSION to set the
"MSVC##" and MSVC_VERSION variables.  It no longer needs the IDE generator
to dictate the version or to detect the version by running the
command-line tool for NMake and Ninja generators.  Drop configuration of
CMakeCPlatform.cmake and CMakeCXXPlatform.cmake from Windows-cl.cmake.in
because all the results it saved are now cheap to compute every time.
2012-08-30 09:42:40 -04:00
Rolf Eike Beer af06482d24 FindFLEX: fix version extraction on Apple
The space in 'flex 2.5.35 Apple(flex-31)' caused the version extraction to
fail. Ignore everything after the first space following the version number.
2012-08-30 15:34:41 +02:00
Stephen Kelly 42bfc5a3e4 Read entire Qt4 qrc file when parsing for depends info.
The qrc file is an xml file, not line based, so the entire 'interesting'
content to parse is not necessarily found by STRINGS and a regexp.
2012-08-30 09:47:42 +02:00
Stephen Kelly 325214900b Fix casing of 'Qt' in docs, comments and user-visible strings.
QT (cue-tea) is Apple QuickTime.
Qt (cute) is the C++ framework.
2012-08-28 11:24:55 +02:00
Peter Kümmel be9afbf453 Find mingw's windres also when Unix Makefiles are used 2012-08-27 16:54:21 +02:00
Peter Kümmel 0af27f1f2a Ninja: also detect /showInclude prefix for icl 2012-08-27 14:49:51 +02:00
Brad King e5fee8a7c2 Store ABI detection results in compiler information files
Drop use of cache entry CMAKE_DETERMINE_<LANG>_ABI_COMPILED and replace
it with variable CMAKE_<LANG>_ABI_COMPILED.  Since the grandparent
commit this test result is specific to the version of CMake.  Store it
in the version-specific compiler information files instead of
CMakeCache.txt so testing can be re-done to meet the requirements of the
current version of CMake even if another version of CMake was already
used to configure the build tree.
2012-08-24 15:15:14 -04:00
David Cole 34a0284603 Merge topic 'ide-compiler-id'
403ead6 Document CMAKE_<LANG>_COMPILER_(ID|VERSION) values
8be51f6 Test variables CMAKE_(C|CXX|Fortran)_COMPILER(|_ID|_VERSION)
ec22a9b Cleanly enable a language in multiple subdirectories
66cb335 VS: Detect the compiler id and tool location
89595d6 VS10: Define CMAKE_VS_PLATFORM_TOOLSET variable
965a69d Xcode: Detect the compiler id and tool location
9a9e1ee CMakeDetermineCompilerId: Prepare to detect IDE compiler id
b8b5c83 Re-order C/C++/Fortran compiler determination logic
2012-08-24 14:25:40 -04:00
David Cole 0a9b51b6bc Merge topic 'more-compiler-versions'
e9bc502 Detect Analog VisualDSP++ compiler version with its id
cca386b Detect Cray compiler version with its id
622d9a7 Detect SDCC compiler version with its id
4ad7fa6 Detect Comeau compiler version with its id
952651c Detect TI compiler version with its id
74c57d9 Detect PathScale compiler version with its id
707aefd Detect Compaq compiler version with its id
2012-08-24 14:25:21 -04:00
David Cole 286f7c9644 Merge topic 'topics/FindCUDA/Add-CUDA_SOURCE_PROPERTY_FORMAT'
787287c Added CUDA_SOURCE_PROPERTY_FORMAT. Allows setting per file format (OBJ or PTX)
2012-08-24 14:24:11 -04:00
David Cole 6dab13c56e Merge topic 'topics/FindCUDA/Fix-g3-again'
a20c41d Replace -g3 with -g for CUDA 4.1 and 4.2 in addition to CUDA < 3.0.
2012-08-24 14:23:21 -04:00
Clinton Stimpson caa9151169 Fix errors detecting Qt4 on Windows 8.
Thanks to Petr Baloun for the patch.
2012-08-24 09:54:31 -06:00
Brad King 3df81b4912 Move CMAKE_<LANG>_COMPILER_WORKS to compiler information files
Since the parent commit this test result is specific to the version of
CMake.  Store it in the version-specific compiler information files
instead of CMakeCache.txt so testing can be re-done to meet the
requirements of the current version of CMake even if another version of
CMake was already used to configure the build tree.
2012-08-24 10:52:23 -04:00
Brad King 7195aca54f Make platform information files specific to the CMake version
At the top of a build tree we configure inside the CMakeFiles directory
files such as "CMakeSystem.cmake" and "CMake<lang>Compiler.cmake" to
save information detected about the system and compilers in use.  The
method of detection and the exact results store varies across CMake
versions as things improve.  This leads to problems when loading files
configured by a different version of CMake.  Previously we ignored such
existing files only if the major.minor part of the CMake version
component changed, and depended on the CMakeCache.txt to tell us the
last version of CMake that wrote the files.  This led to problems if the
user deletes the CMakeCache.txt or we add required information to the
files in a patch-level release of CMake (still a "feature point" release
by modern CMake versioning convention).

Ensure that we always have version-consistent platform information files
by storing them in a subdirectory named with the CMake version.  Every
version of CMake will do its own system and compiler identification
checks even when a build tree has already been configured by another
version of CMake.  Stored results will not clobber those from other
versions of CMake which may be run again on the same tree in the future.
Loaded results will match what the system and language modules expect.

Rename the undocumented variable CMAKE_PLATFORM_ROOT_BIN to
CMAKE_PLATFORM_INFO_DIR to clarify its purpose.  The new variable points
at the version-specific directory while the old variable did not.
2012-08-24 10:52:23 -04:00
Brad King 32db033b27 VS: Remove support for "free" version 2003 tools
Several more recent Visual Studio Express editions are now available and
they support debug builds.  Simplify our VS platform files by removing
support for these old tools.  If anyone still uses them we can restore
support with a more modern way to test for them.
2012-08-23 10:51:27 -04:00
Brad King ca9c287d1a Merge topic 'Qt4Macros-fix-resource-parsing'
3553001 Qt4Macros: Fix recently broken resource file parsing
2012-08-23 10:16:58 -04:00
Brad King 66cb3356f5 VS: Detect the compiler id and tool location
Configure a hand-generated Visual Studio project to build the compiler id
source file since we cannot run the compiler command-line tool directly.
Add a post-build command to print out the full path to the compiler tool.
Parse the full path to the compiler tool from the build output.
2012-08-22 16:35:54 -04:00
Brad King 965a69dcaa Xcode: Detect the compiler id and tool location
Configure a hand-generated Xcode project to build the compiler id source
file since we cannot run the compiler command-line tool directly.  Add a
post-build shell script phase to print out the compiler toolset build
setting.  Run xcodebuild to compile the identification binary.  Parse
the full path to the compiler tool from the xcodebuild output.
2012-08-22 15:14:33 -04:00
Brad King 9a9e1ee98d CMakeDetermineCompilerId: Prepare to detect IDE compiler id
Teach CMAKE_DETERMINE_COMPILER_ID to check for variable
CMAKE_${lang}_COMPILER_ID_TOOL after CMAKE_DETERMINE_COMPILER_ID_BUILD
to use as CMAKE_${lang}_COMPILER since it will not be known until after
the IDE runs.

In CMAKE_DETERMINE_COMPILER_ID_BUILD prepare a cascading "if" so we can
use a generator-specific method to compile the identification source
file.  Leave "if(0)" as a placeholder for now and put the direct
compiler invocation in "else()".  After running the compiler to build
the compiler identification source we file(GLOB) the list of output
files as candidates for extracting the compiler information.  An IDE may
create directories, so exclude exclude directories from this list.
2012-08-22 15:14:33 -04:00
Brad King b8b5c8342a Re-order C/C++/Fortran compiler determination logic
Re-organize CMakeDetermine(C|CXX|Fortran)Compiler.cmake to search for
the compiler command-line tool only under generators for which it makes
sense.  For the Visual Studio generators we do not expect to find the
compiler tool from the environment, nor would we use the result anyway.

Furthermore, set CMAKE_${lang}_COMPILER_ID_TEST_FLAGS only when it has a
chance to be used.  Extract _CMAKE_TOOLCHAIN_LOCATION from the compiler
path after running the compiler id step so in the future that step can
help find the path to the compiler.
2012-08-22 15:14:33 -04:00
Brad King e9bc502fb8 Detect Analog VisualDSP++ compiler version with its id
Decode hex digits from __VISUALDSPVERSION__ to compute the version
number components.  Note that the constant encodes decimal digits as hex
digits (never larger than 9).  We represent them as decimal after
extraction.  See documentation at:

  http://download.analog.com/dsp/tools/VisualDSP_45_Update_6_Release_Note_v4.pdf
  http://www.analog.com/static/imported-files/software_manuals/50_asm_man.rev3.1.pdf

Note that __VISUALDSPVERSION__ was introduced in version 4.5.6.
2012-08-22 11:48:07 -04:00
Brad King cca386b0a0 Detect Cray compiler version with its id
Decode decimal digits from

  _RELEASE
  _RELEASE_MINOR

to compute version number components.  See documentation at:

  http://docs.cray.com/books/S-2179-52/html-S-2179-52/zfixed5fvzxnxo.html
  http://sourceforge.net/p/predef/wiki/Compilers/#cray-c
2012-08-22 11:31:33 -04:00
Brad King 622d9a789d Detect SDCC compiler version with its id
Decode decimal digits from SDCC to compute version number components.
See documentation at:

  http://sdcc.sourceforge.net/doc/sdccman.pdf
  http://sourceforge.net/p/predef/wiki/Compilers/#small-device-c-compilerhttpenwikipediaorgwikismall_device_c_compiler
2012-08-22 10:27:09 -04:00
Brad King 4ad7fa6488 Detect Comeau compiler version with its id
Decode decimal digits from __COMO_VERSION__ to compute the version
number components.  See documentation at:

  http://www.comeaucomputing.com/4.0/docs/userman/predefs.html
  http://sourceforge.net/p/predef/wiki/Compilers/#comeau-chttpenwikipediaorgwikicomeau_cc2b2b
2012-08-22 10:17:01 -04:00
Brad King 952651c642 Detect TI compiler version with its id
Decode decimal digits from __TI_COMPILER_VERSION__ to compute version
number components.  See documentation at:

  http://processors.wiki.ti.com/index.php/Refer_to_Compiler_Version_in_Your_Source
  http://www.ti.com/general/docs/lit/getliterature.tsp?literatureNumber=spru187o
  http://sourceforge.net/p/predef/wiki/Compilers/#texas-instruments-cc-compiler
2012-08-22 10:17:01 -04:00
Brad King 74c57d99b4 Detect PathScale compiler version with its id
Decode decimal digits from

  __PATHCC__
  __PATHCC_MINOR__
  __PATHCC_PATCHLEVEL__

to compute version number components.  See documentation at:

  http://www.pathscale.com/docs/UserGuide.pdf
  http://sourceforge.net/p/predef/wiki/Compilers/#ekopathhttpenwikipediaorgwikipathscale
2012-08-22 10:17:01 -04:00
Brad King 707aefd853 Detect Compaq compiler version with its id
Decode decimal digits from __DECC_VER and __DECCXX_VER to compute
version number components.  See documentation at:

  http://www.openvms.compaq.com/commercial/c/docs/5492p024.html#decc_ver_sec
  http://www.tru64unix.compaq.com/cplus/ugu_impl.html#predef_vernum
  http://sourceforge.net/p/predef/wiki/Compilers/#compaq-cchttpwwwopenvmscompaqcomopenvmsbrochuresdeccplus
2012-08-22 10:17:01 -04:00
Brad King 3553001bcc Qt4Macros: Fix recently broken resource file parsing
Commit 4be67837 (read less from version headers into variables,
2012-08-19) switched from file(READ) and string(REGEX MATCHALL) to just
file(STRINGS) to extract the list of resource <file> entries.  However,
the latter extracts entire lines that match the regex, not just the part
that matches the regex, so the subsequent string(REGEX REPLACE) fails to
match and replace anything.  Return to the original parsing logic but
replace file(READ) with file(STRINGS) to load a minimal part of the file
before using string(REGEX MATCHALL) as before.
2012-08-22 08:37:27 -04:00
James Bigler 787287cc46 Added CUDA_SOURCE_PROPERTY_FORMAT. Allows setting per file format (OBJ or PTX)
Added CUDA_SOURCE_PROPERTY_FORMAT that allows users to set the format (OBJ or PTX) on a
per file basis.
2012-08-20 17:33:35 -06:00
James Bigler db207e4065 FindCUDA: Added CUDA_HOST_COMPILER variable.
Added a new CUDA variable for specifying the CUDA_HOST_COMPILER.  This will allow users to
be able to specify which host compiler to use for invoking NVCC with.  By default it will
use the compiler used for host compilation.  This is convenient for when you want to
specify a different compiler than the default compiler.  You end up using the same
compiler for both the NVCC compilation and the host compilation instead of using the
default compiler in the path for NVCC.
2012-08-20 15:14:37 -06:00
David Cole 32710211ad Merge topic 'qt4_use_modules'
1420691 Add new qt4_use_modules function.
2012-08-20 15:42:43 -04:00
David Cole c79dd4d951 Merge topic 'read-less-from-version-headers'
4be6783 read less from version headers into variables
2012-08-20 15:42:34 -04:00
David Cole 19e210af90 Merge topic 'no-regex-escape-space'
637207e do not escape spaces in regular expressions
2012-08-20 15:42:25 -04:00
David Cole 0afaedfb4a Merge topic 'FindGTK2_12306'
ad30210 FindGTK2: Add GTK2_CAIROMMCONFIG_INCLUDE_DIR for cairommconfig.h
2012-08-20 15:42:13 -04:00
David Cole e19f260712 Merge topic 'FindOpenSceneGraph_13094'
dd60ed2 Merge topic 'lib64-cleanup' into FindOpenSceneGraph_13094
224b5de FindOpenSceneGraph: CMake variable OSG_DIR influences detection now too
2012-08-20 15:42:03 -04:00
David Cole 9a4b4f2223 Merge topic 'lib64-cleanup'
cfe4ac4 use PATH_SUFFIXES to simplify find_* calls
b04650e use the find_* functions ENV parameter
2012-08-20 15:41:53 -04:00
David Cole 4097914bbd Merge topic 'fix-13236-mark-vars-as-advanced'
3f9fa5c ProcessorCount: Mark find_program vars as advanced (#13236)
2012-08-20 15:41:44 -04:00
David Cole ba9fde6503 Merge topic 'fix-13315-incorrect-mfc-file-name'
e4e6ea0 InstallRequiredSystemLibraries: Use correct file names (#13315)
2012-08-20 15:41:26 -04:00
David Cole e04245e2d5 Merge topic 'HandleMacFrameworkIncludeDirs_13465'
a3815e6 -fix line length
9110d0e Eclipse on OSX: improve handling of framework include dirs (#13367)
d97b385 Eclipse on OSX: fix handling of framework include dirs (#13464)
2012-08-20 15:41:14 -04:00
David Cole 1239b4881d Merge topic 'qt4-path-search'
35c6ae8 FindQt4: Give precedence to QTDIR environment variable, if set.
5a6a3d4 FindQt4: Give precedence to QTDIR environment variable, if set.
2012-08-20 15:40:36 -04:00
David Cole 321bbed130 Merge topic 'qt4-version-regex'
4a772a1 Fix regex for qt minor version.
2012-08-20 15:40:28 -04:00
David Cole e11e719796 Merge topic 'hg-modules'
91053cd ExternalProject: Add Mercurial (hg) repository support
ea5bfb1 Add FindHg module to find Mercurial
2012-08-20 15:40:19 -04:00
David Cole eb6b8c86bf Merge topic 'relwithdebinfo-consistency'
0ddfc51 Add -DNDEBUG to RelWithDebInfo flags where where Release flags had it.
2012-08-20 15:40:11 -04:00
David Cole 0075e7e033 Merge topic 'deployqt4-destdir'
1e3248c DeployQt4:  Include DESTDIR for some cpack generators.
2012-08-20 15:40:03 -04:00
David Cole c2022eb06d Merge topic 'fphsa-message'
213a9e5 fphsa: clarify message about minimum required version found.
2012-08-20 15:39:53 -04:00
David Cole 14c8096ba8 Merge topic 'more-endif-closing-style-cleanups'
84b49be Remove CMake multiline block-end command arguments
2012-08-20 15:39:26 -04:00
David Cole d4be75be12 Merge topic 'FindX11-duplicate-includes-13316'
dd784dd FindX11: avoid calling list(REMOVE_DUPLICATES) on an empty list
97c338b FindX11: remove duplicates from X11 include path list (#13316)
2012-08-20 15:39:18 -04:00
David Cole 2582994e57 Merge topic 'clang-asm'
7e8471c Recognize Clang ASM support (#13473)
2012-08-20 15:38:51 -04:00
David Cole 5cf828c028 Merge topic 'CheckTypeSize-doc-10579'
c6fed68 CheckTypeSize: add a test for size of struct members
48783b7 CheckTypeSize: show in documentation how to get struct member size (#10579)
2012-08-20 15:38:33 -04:00
Stephen Kelly 1420691b35 Add new qt4_use_modules function. 2012-08-19 23:45:09 +02:00
Rolf Eike Beer 4be6783711 read less from version headers into variables
Instead of reading the whole file using file(READ) and later matching on the
whole file use file(STRINGS ... REGEX) to get only those lines we are
interested in at all. This will make the list much smaller (good for debugging)
and also the regular expressions will need to match on much smaller strings.

Also unset the content variables once they are not used anymore.
2012-08-19 13:54:56 +02:00
Rolf Eike Beer 637207e62a do not escape spaces in regular expressions
The space has no special meaning in regular expressions so it doesn't need to
be escaped.
2012-08-19 11:49:56 +02:00
Philip Lowman ad30210ccf FindGTK2: Add GTK2_CAIROMMCONFIG_INCLUDE_DIR for cairommconfig.h 2012-08-18 17:56:46 -04:00
Philip Lowman dd60ed2f4f Merge topic 'lib64-cleanup' into FindOpenSceneGraph_13094
Resolved a few conflicts due to changes made in 13094 to paths
Conflicts:
	Modules/FindOpenThreads.cmake
	Modules/Findosg_functions.cmake
2012-08-18 17:03:18 -04:00
Philip Lowman 224b5dea78 FindOpenSceneGraph: CMake variable OSG_DIR influences detection now too 2012-08-18 16:46:08 -04:00
David Cole 3f9fa5cc7f ProcessorCount: Mark find_program vars as advanced (#13236)
After each find_program call, mark_as_advanced each find result
variable to avoid polluting the cache with non-advanced variables
2012-08-17 10:56:05 -04:00
David Cole e4e6ea0714 InstallRequiredSystemLibraries: Use correct file names (#13315)
The Spanish language MFC localization dll changed names from
VS 9 to 10. Use the correct file name ending with "esn.dll"
instead of the now non-existent one ending with "esp.dll"

Also, add the existing, but missing from our rules until now,
Russian language module.

Alphabetize the list while we're at it for easier reading in
the future.

We may want to consider adding some file(GLOB code here to
minimize the risk of missing files added in future versions
of VS.
2012-08-17 09:48:24 -04:00
Alex Neundorf d97b38529e Eclipse on OSX: fix handling of framework include dirs (#13464)
On OSX, the output from gcc looks like this:
 /usr/include/c++/4.2.1
 /usr/include/c++/4.2.1/i686-apple-darwin10/x86_64
 /usr/include/c++/4.2.1/backward
 /usr/lib/gcc/i686-apple-darwin10/4.2.1/include
 /usr/include
 /System/Library/Frameworks (framework directory)
 /Library/Frameworks (framework directory)
End of search list.

The "(framework directory)" part needs to be removed so that Eclipse handles it properly

Alex
2012-08-16 23:02:10 +02:00
Clinton Stimpson 35c6ae8877 FindQt4: Give precedence to QTDIR environment variable, if set.
Remove old search paths that aren't needed.

Keep using PATHS instead of HINTS because a Windows machine may have
a different Qt in its PATH and putting QTDIR and the registry entry
ahead of PATH could cause apps to fail when run.
2012-08-16 07:31:17 -06:00
Brad King 91053cdf7b ExternalProject: Add Mercurial (hg) repository support
Add options HG_REPOSITORY and HG_TAG to specify an external project
hosted in a Mercurial repository.  Teach ExternalProject to clone the
repository and update from it.  Extend the ExternalProject test to try a
Mercurial repository when hg is available.
2012-08-16 09:02:34 -04:00
Clinton Stimpson 0ddfc51f6a Add -DNDEBUG to RelWithDebInfo flags where where Release flags had it.
Previously, it was inconsistent in that some platforms/compilers
had this flag for the RelWithDebInfo configuration and some didn't.
This fixes issue #11366.
2012-08-15 20:00:45 -06:00
Clinton Stimpson 1e3248c9d0 DeployQt4: Include DESTDIR for some cpack generators. 2012-08-15 19:36:50 -06:00
Clinton Stimpson 213a9e5a7b fphsa: clarify message about minimum required version found.
Thanks to Dubrovskiy Viacheslav.
2012-08-15 18:23:55 -06:00
Clinton Stimpson 5a6a3d4342 FindQt4: Give precedence to QTDIR environment variable, if set. 2012-08-15 18:20:16 -06:00
Clinton Stimpson 4a772a1686 Fix regex for qt minor version.
Thanks to Dubrovskiy Viacheslav and Sergei Epifanov for patch.
2012-08-15 18:14:40 -06:00
Marcin Wojdyr 84b49be8f0 Remove CMake multiline block-end command arguments
removing arguments omitted in 9db3116226
2012-08-15 16:50:29 -04:00
Rolf Eike Beer dd784dde72 FindX11: avoid calling list(REMOVE_DUPLICATES) on an empty list 2012-08-15 19:28:50 +02:00
Brad King 7e8471ce7b Recognize Clang ASM support (#13473)
Since commit 571dc748 (Recognize Clang C and C++ compilers, 2010-05-17)
we recognize Clang C and C++ support.  Add Compiler/Clang-ASM.cmake to
enable use of Clang for ASM too.  Also teach Assembler test to try Clang
as an assembler.

Suggested-by: Tobias Pape <tobiaspape@gmail.com>
2012-08-15 09:40:20 -04:00
Rolf Eike Beer 48783b71fb CheckTypeSize: show in documentation how to get struct member size (#10579) 2012-08-14 21:14:33 +02:00
Rolf Eike Beer 97c338bac9 FindX11: remove duplicates from X11 include path list (#13316)
Most if not all X11 includes are typically in the same directory, so this
usually returns a huge list with only very few different entries.
2012-08-14 21:13:44 +02:00
Rolf Eike Beer cfe4ac4b41 use PATH_SUFFIXES to simplify find_* calls
Especially remove "lib64" when the given paths are all Unix ones and "lib" is
also explicitely given. In that case CMake will search "lib64" anyway for
platforms where it is known to make sense.
2012-08-14 21:03:23 +02:00
Rolf Eike Beer b04650e163 use the find_* functions ENV parameter
Instead of directly passing $ENV{SOMEVAR} to a find_* call pass in ENV SOMEVAR.
This will make sure the paths will get correctly handled through different
platforms, especially on Windows.

Also fixes one place where paths with windows delimiters (\) were hardcoded to
use forward slashes.
2012-08-14 21:02:58 +02:00
Brad King ea5bfb1d25 Add FindHg module to find Mercurial
Also teach the CMakeOnly.AllFindModules to verify Hg version detection.
2012-08-14 10:41:17 -04:00
Brad King d269984e53 GetPrerequisites: Mark file_cmd as advanced cache entry
This internal implementation detail should not pollute the main
cache view of projects that include GetPrerequisites.
2012-08-14 09:02:08 -04:00
Brad King 6c2c483ef9 Remove trailing TAB from NSIS.template.in
This was missed by commit 7bbaa428 (Remove trailing whitespace from most
CMake and C/C++ code, 2012-08-13) which only removed trailing spaces,
not TABs.
2012-08-14 08:05:41 -04:00
Kitware Robot 9db3116226 Remove CMake-language block-end command arguments
Ancient versions of CMake required else(), endif(), and similar block
termination commands to have arguments matching the command starting the
block.  This is no longer the preferred style.

Run the following shell code:

for c in else endif endforeach endfunction endmacro endwhile; do
    echo 's/\b'"$c"'\(\s*\)(.\+)/'"$c"'\1()/'
done >convert.sed &&
git ls-files -z -- bootstrap '*.cmake' '*.cmake.in' '*CMakeLists.txt' |
egrep -z -v '^(Utilities/cm|Source/kwsys/)' |
egrep -z -v 'Tests/CMakeTests/While-Endwhile-' |
xargs -0 sed -i -f convert.sed &&
rm convert.sed
2012-08-13 14:19:16 -04:00
Kitware Robot 77543bde41 Convert CMake-language commands to lower case
Ancient CMake versions required upper-case commands.  Later command
names became case-insensitive.  Now the preferred style is lower-case.

Run the following shell code:

cmake --help-command-list |
grep -v "cmake version" |
while read c; do
    echo 's/\b'"$(echo $c | tr '[:lower:]' '[:upper:]')"'\(\s*\)(/'"$c"'\1(/g'
done >convert.sed &&
git ls-files -z -- bootstrap '*.cmake' '*.cmake.in' '*CMakeLists.txt' |
egrep -z -v '^(Utilities/cm|Source/kwsys/)' |
xargs -0 sed -i -f convert.sed &&
rm convert.sed
2012-08-13 14:19:16 -04:00
Kitware Robot 7bbaa4283d Remove trailing whitespace from most CMake and C/C++ code
Our Git commit hooks disallow modification or addition of lines with
trailing whitespace.  Wipe out all remnants of trailing whitespace
everywhere except third-party code.

Run the following shell code:

git ls-files -z -- \
 bootstrap doxygen.config '*.readme' \
 '*.c' '*.cmake' '*.cpp' '*.cxx' \
 '*.el' '*.f' '*.f90' '*.h' '*.in' '*.in.l' '*.java' \
 '*.mm' '*.pike' '*.py' '*.txt' '*.vim' |
egrep -z -v '^(Utilities/cm|Source/(kwsys|CursesDialog/form)/)' |
egrep -z -v '^(Modules/CPack\..*\.in)' |
xargs -0 sed -i 's/ \+$//'
2012-08-13 14:18:39 -04:00
Brad King be9db98946 Merge topic 'watcom-compiler-version'
af42ae4 Watcom: Simplify compiler version detection (#11866)
2012-08-13 14:18:28 -04:00
David Cole e0f7d7fe5a Merge topic 'CPackRPM-fixRelocatablePrefix'
822c1ea Do not include directories which are part of the package install prefix.
2012-08-13 13:28:36 -04:00
David Cole 1f793ab6ba Merge topic 'fix-typo-13456'
67f11cf FindSelfPackers: fix typo (#13456)
2012-08-13 13:28:25 -04:00
David Cole 396bc28477 Merge topic 'doc_fixes'
76d6c59 Clean up documentation formatting so that it is rendered properly in HTML.
2012-08-13 13:28:16 -04:00
David Cole 0d28661999 Merge topic 'select-compiler'
7e58e5b Prefer generic system compilers by default for C, C++, and Fortran
796e337 Factor common code out of CMakeDetermine(ASM|C|CXX|Fortran)Compiler
b708f1a CMakeDetermine(C|CXX)Compiler: Consider Clang compilers
2012-08-13 13:27:57 -04:00
David Cole 4bdbdfbfef Merge topic 'directory-typo'
6c8722f Fix typo direcotry -> directory (and similar) [#13444]
2012-08-13 13:27:48 -04:00
David Cole 92b11383d9 Merge topic 'SelectLibraryConfiguration-multi-lib-per-var2'
5797512 SelectLibraryConfiguration: generate correct output when input vars are lists
2012-08-13 13:27:39 -04:00
David Cole 11a9ea35de Merge topic 'FindOpenSSL-improve'
3cfb68d FindOpenSSL: remove leftover comment
fc798ed FindOpenSSL: cleanup path hints
c78a7d1 FindOpenSSL: let CMake handle environment variable HINTS
7464519 FindOpenSSL: use SelectLibraryConfigurations
4b793ad FindOpenSSL: find cross-compiled OpenSSL from MinGW (#13431)
2012-08-13 13:27:31 -04:00
David Cole 1b9684562b Merge topic 'EclipseAddSupportForJuno'
53cc102 Eclipse: improve (fix ?) version detection on OSX
bcccddc Eclipse: add support for the 4.2 Juno release (#13367)
2012-08-13 13:27:07 -04:00
David Cole 85f843a7b4 Merge topic 'mixed-lib-to-lib64'
af80da3 remove lib64 Unix paths if the respective lib path is also given
733726e find_library: Fix mixed lib->lib64 (non-)conversion cases (#13419)
54add62 find_library: Simplify lib->lib<arch> expansion
6ca2f82 find_library: Refactor lib->lib64 conversion
1fe4b82 find_library: Add test covering lib->lib64 cases
2012-08-13 13:26:57 -04:00
Brad King af42ae4f81 Watcom: Simplify compiler version detection (#11866)
Since commit c198730b (Detect Watcom compiler version with its id,
2011-12-07) the CMAKE_(C|CXX)_COMPILER_VERSION variables are set for the
Watcom compiler.  Use these in Windows-wcl386.cmake to set the old
WATCOM1* version variables.  This avoids using the old EXECUTE_PROCESS
command which failed due to extra quotes anyway.
2012-08-13 08:19:23 -04:00
Andy Piper 822c1eaf9e Do not include directories which are part of the package install prefix.
This fix bug #0013451. The bug prevents theorerically relocatable RPM package
to be installed properly.
Signed-off-by: Eric NOULARD <eric.noulard@gmail.com>
2012-08-07 19:15:19 +02:00
Rolf Eike Beer 67f11cf1e9 FindSelfPackers: fix typo (#13456)
Correction by Modestas Vainius.
2012-08-04 14:44:38 +02:00
Zack Galbreath 76d6c59358 Clean up documentation formatting so that it is rendered properly in HTML. 2012-08-03 14:52:32 -04:00
Brad King 7e58e5bb68 Prefer generic system compilers by default for C, C++, and Fortran
Teach CMake to prefer the system default compiler automatically when no
compiler is specified.  By default use "cc" for C, "CC" for C++, and
"f95" for Fortran.  Load a new Platform/<os>-<lang>.cmake module to
allow each platform to specify for each language its system compiler
name(s) and/or exclude certain names.

Create Platform/(CYGWIN|Darwin|Linux|Windows)-CXX.cmake modules to
specify "c++" as the system C++ compiler name for these platforms.  On
systems that use case-insensitive filesystems exclude C++ compiler names
that are distinguished from C compiler names only by case.

This will change the default compiler selection for existing build
scripts that do not specify a compiler when run on machines with
separate system and GNU compilers both installed in the PATH.  We do not
make this change in default behavior lightly.  However:

(1) If a given build really needs specific compilers one should specify
    them explicitly e.g. by setting CC, CXX, and FC in the environment.

(2) The motivating case is to prefer the system Clang on newer OS X
    systems over the older GNU compilers typically also installed.  On
    such systems the names "cc" and "c++" link to Clang.  This is the
    first platform known to CMake on which "c++" is not a GNU compiler.
    The old behavior selected "gcc" for C and "c++" C++ and therefore
    chooses GNU for C and Clang for C++ by default.  The new behavior
    selects GNU or Clang consistently for both languages on older or
    newer OS X systems, respectively.

(3) Other than the motivating OS X case the conditions under which the
    behavior changes do not tend to exist in default OS installations.
    They typically occur only on non-GNU systems with manually-installed
    GNU compilers.

(4) The consequences of the new behavior are not dire.  At worst the
    project fails to compile with the system compiler when it previously
    worked with the non-system GNU compiler.  Such failure is easy to
    work around (see #1).

In short this change creates a more sensible default behavior everywhere
and fixes poor default behavior on a widely-used platform at the cost of
a modest change in behavior in less-common conditions.
2012-08-02 13:26:01 -04:00
Brad King 796e33734d Factor common code out of CMakeDetermine(ASM|C|CXX|Fortran)Compiler
The compiler candidate list selection and search code for C, C++, ASM,
and Fortran languages was duplicated across four modules.  To look for
compilers adjacent to already-enabled languages the C and CXX modules
each used _CMAKE_USER_(C|CXX)_COMPILER_PATH and the ASM module used
_CMAKE_TOOLCHAIN_LOCATION.  Since commit 4debb7ac (Bias Fortran compiler
search with C/C++ compilers, 2009-09-09) CMake prefers Fortran compilers
matching the vendor and directory of an enabled C or C++ compiler.

Factor out the common functionality among the four languages into a new
CMakeDetermineCompiler module.  Generalize the Fortran implementation so
that all languages may each use the vendor and directory of the other
languages that have already been enabled.  For now do not list any
vendor-specific names for C, C++, or ASM so that only the directory
preference is used for these languages (existing behavior).
2012-08-02 11:33:18 -04:00
Brad King b708f1a2b9 CMakeDetermine(C|CXX)Compiler: Consider Clang compilers
Look for "clang" or "clang++" compiler executables so Clang will be used
when it is the only compiler available.  Prefer them last to avoid
changing compiler default preferences for existing scripts.
2012-07-31 14:30:30 -04:00
Rolf Eike Beer 6c8722fab5 Fix typo direcotry -> directory (and similar) [#13444] 2012-07-30 08:08:33 +02:00
Rolf Eike Beer 5797512cec SelectLibraryConfiguration: generate correct output when input vars are lists
In case that any of the input variables that hold the library names contains
more than just a single library the "debug" or "optimized" keywords were only
prepended to the first item, making all other libs appear in all
configurations. Just treat both input variables as lists.

Thanks to Philipp Berger <newsletters@philippberger.de> for pointing me at
this.
2012-07-29 17:45:53 +02:00
Rolf Eike Beer 3cfb68d93e FindOpenSSL: remove leftover comment 2012-07-29 17:03:36 +02:00
Rolf Eike Beer fc798ed64f FindOpenSSL: cleanup path hints
-only use Windows-specific paths on Windows
-recode the contents of $ENV{PROGRAMFILES} to be a valid CMake path before
 using it
2012-07-29 17:02:00 +02:00
Rolf Eike Beer c78a7d11dd FindOpenSSL: let CMake handle environment variable HINTS
This will automatically make sure the paths will get recoded to proper separators on Windows
2012-07-29 16:53:39 +02:00
Rolf Eike Beer 7464519304 FindOpenSSL: use SelectLibraryConfigurations 2012-07-29 16:53:39 +02:00
Rolf Eike Beer 4b793ad196 FindOpenSSL: find cross-compiled OpenSSL from MinGW (#13431)
Suggested-by: Dominik Schmidt <dev@dominik-schmidt.de>
2012-07-29 16:53:39 +02:00
Alex Neundorf 53cc1026bc Eclipse: improve (fix ?) version detection on OSX
This is probably related to a framework installation I guess.
This is part of the patch in #13367 from Nicholas Yue.

Alex
2012-07-28 11:58:04 +02:00
Alex Neundorf bcccddc7e9 Eclipse: add support for the 4.2 Juno release (#13367)
Thanks for the path to Nicholas Yue.

Alex
2012-07-28 11:40:08 +02:00
Rolf Eike Beer af80da349b remove lib64 Unix paths if the respective lib path is also given
If FIND_LIBRARY_USE_LIB64_PATHS is set both will be searched anyway.
2012-07-21 10:15:52 +02:00
Alexey Ozeritsky 79a4e2bbdd Fixed: FindLAPACK does not find MKL 10.3 when using gcc 4.x 2012-07-18 11:17:45 +04:00
David Cole 58f5e77d6a Merge topic 'ninja-rspfile-link-libraries'
4bb94c9 Ninja: sysconf() is declared in unistd.h
bb36759 Ninja: enable response file support on Mac (length 262144)
3a2c8e8 Ninja: disable work around when linking with mingw
3856e66 Ninja: error on missing rspfile_content
8c1e35c Ninja: remove some unused default arguments
7f647cf Ninja: also write link libraries to rsp file
2012-07-12 16:00:42 -04:00
David Cole b1f6e688eb Merge topic 'aix-gnu-asm'
7755283 Add ASM platform information for GNU compiler on AIX (#13390)
2012-07-12 16:00:31 -04:00
David Cole 457041e5b3 Merge topic 'aix-GNU-shared-libs'
767a7ad AIX-GNU: Link shared libs with -brtl,-bnoipath (#13352)
2012-07-12 16:00:05 -04:00
David Cole 4b39302407 Merge topic 'deploy-qt4-workaround-bug-13258'
374b9b9 DeployQt4: workaround bug 13258 where ARGV1 is leaked into a sub function.
2012-07-12 15:59:43 -04:00
Peter Kümmel 3a2c8e8e66 Ninja: disable work around when linking with mingw
The work around is only needed by older GCCs (only testet 4.4/4.7)
Ninja is very new so chances are high that there is also a new mingw.

Use slashes in link rsp file, because ar.exe can't handle \.
2012-07-11 08:55:00 +02:00
Brad King 7755283e89 Add ASM platform information for GNU compiler on AIX (#13390)
Among other flags this sets RPATH flags correctly so that CMake knows
how to treat CMAKE_PLATFORM_REQUIRED_RUNTIME_PATH for the ASM language.
This is the GNU compiler equivalent to commit a0bab7ae (Add ASM platform
information for XL compiler on AIX, 2011-03-02), made for XL.
2012-07-10 15:18:55 -04:00
Brad King 767a7ad9da AIX-GNU: Link shared libs with -brtl,-bnoipath (#13352)
We already use these flags with the XL toolchain.  Use them for GNU too.
2012-07-09 17:18:41 -04:00
David Cole cdc00f0f7e Merge topic 'getprerequisites-pie-executables'
ac7a193 GetPrerequisites.cmake: detect executables built with the -pie linker flag.
2012-07-09 14:23:38 -04:00
David Cole b636728e39 Merge topic 'CPack-honorCPACK_XXX-valuesInScriptFile'
05a8630 Do not provide defaul value for CPACK_PACKAGE_DIRECTORY if found in config.
2012-07-09 14:23:28 -04:00
David Cole 6d75da5f38 Merge topic 'FindBoostNotFoundBug'
ca90709 FindBoost: Future proof to 1.56
accd042 FindBoost: Fix bug where Boost_FOUND could be false when version specified
2012-07-09 14:23:09 -04:00
David Cole 88c31c9017 Merge topic 'EclipseFixIncludeDirDetectionMinGW'
d7bc8dd Eclipse: fix #13313, always set LANG to C, also if unset
2012-07-09 14:22:20 -04:00
Clinton Stimpson 374b9b9e74 DeployQt4: workaround bug 13258 where ARGV1 is leaked into a sub function. 2012-07-09 10:18:45 -06:00
Clinton Stimpson ac7a193951 GetPrerequisites.cmake: detect executables built with the -pie linker flag. 2012-07-05 12:49:40 -06:00
Eric NOULARD 05a8630ee6 Do not provide defaul value for CPACK_PACKAGE_DIRECTORY if found in config.
This fixes bug #0012906.
2012-07-04 23:08:32 +02:00
Philip Lowman ca90709fd6 FindBoost: Future proof to 1.56 2012-06-30 03:40:37 -04:00
Philip Lowman accd0428f4 FindBoost: Fix bug where Boost_FOUND could be false when version specified
Fixes a problem where when specifying a version number without the REQUIRED
parameter, Boost_FOUND would be true on the first configure but false on
subsequent configures.
2012-06-30 03:33:56 -04:00
Alex Neundorf d7bc8dd6ea Eclipse: fix #13313, always set LANG to C, also if unset
Otherwise include dir detection does not work with MinGW on french systems.

Alex
2012-06-25 23:09:27 +02:00
Rolf Eike Beer 304562e7b5 FindJava: improve version matching (#12878) 2012-06-25 18:53:53 +02:00
David Cole 4042b50caa Merge topic 'CMakeDetermineCCompiler-clear-init'
b9ccaf5 CMakeDetermineCCompiler: Fix typo "_CXX_" -> "_C_" (#13330)
2012-06-21 11:55:34 -04:00
David Cole fd8fc2791b Merge topic 'qt4-macros'
0331a5a Qt4Macros: add some quotes to prevent damage from spaces in the paths
f46903b Qt4Macros: improve basename extraction in QT4_ADD_DBUS_INTERFACES
aa841ae FindQt4: extend documentation
2012-06-21 11:55:24 -04:00
David Cole 14576fc096 Merge topic 'find-devil-doc-formatting'
af988e8 FindDevIL: clean up documentation formatting
2012-06-21 11:54:25 -04:00
David Cole 3948cb4fe4 Merge topic 'use-string-to-cmake-path'
3505e68 replace open coded versions of file(TO_CMAKE_PATH)
2012-06-21 11:54:14 -04:00
David Cole 934f553f85 Merge topic 'no-explicit-usr-search'
e93ac6f do not explicitely specify /usr and /usr/local as search paths
2012-06-21 11:54:02 -04:00
Brad King b9ccaf5f79 CMakeDetermineCCompiler: Fix typo "_CXX_" -> "_C_" (#13330)
Initialize CMAKE_C_COMPILER_INIT before using it, rather than
CMAKE_CXX_COMPILER_INIT.
2012-06-20 15:38:53 -04:00
Rolf Eike Beer 0331a5adde Qt4Macros: add some quotes to prevent damage from spaces in the paths 2012-06-20 18:31:38 +02:00
Rolf Eike Beer f46903b4b2 Qt4Macros: improve basename extraction in QT4_ADD_DBUS_INTERFACES
-convert the filename to lowercase before the extraction, this allows this to
 work even if the filename as uppercase ".XML" extension
-use get_filename_component(... NAME) to strip the path
2012-06-20 18:31:37 +02:00
Rolf Eike Beer aa841ae3f3 FindQt4: extend documentation
-refer to AUTOMOC from QT4_AUTOMOC
-mention how source file properties influence QT4_ADD_DBUS_INTERFACE
2012-06-20 18:31:37 +02:00
Rolf Eike Beer af988e868c FindDevIL: clean up documentation formatting 2012-06-19 21:09:42 +02:00
Rolf Eike Beer 3505e68466 replace open coded versions of file(TO_CMAKE_PATH) 2012-06-19 21:08:44 +02:00
Rolf Eike Beer e93ac6fbfe do not explicitely specify /usr and /usr/local as search paths
If not explicitely excluded these paths are searched automatically anyway.
2012-06-19 21:06:27 +02:00
Rolf Eike Beer 188b96b100 fix some typos 2012-06-19 21:05:14 +02:00
David Cole 3f8c9073f9 Merge topic 'CPackDeb-docUpdate'
5ac6ca0 CPackDeb add missing documentation for some CPACK_DEBIAN_xx variables.
2012-06-19 14:43:20 -04:00
David Cole d3a61d1e0f Merge topic 'FindBullet-LinearMath_Debug'
4393b3b FindBullet: Add missing math library name (#13309)
2012-06-19 14:42:51 -04:00
David Cole 565744bd3d Merge topic 'ninja-cldeps'
eb410e8 Ninja: disable cldeps for bcc32, it's too old, and ninja would also not build
5ead31d Ninja: try work around for bcc32 bug
1333b57 Ninja: build server fixes
9081e3a remove warning about unused parameter
f430bea Ninja: maybe this fixes the bcc32 build
f2c1288 Ninja: msvc6 for-scoping
44b9bbc Ninja: build with old msvc versions
57156a5 Ninja: build server fixes
f1abdce Ninja: some bytes of the rc files couldn't be piped correctly
2de963d Ninja: don't remove space between command and parameters
50b6f33 Ninja: build cmcldeps with mingw
c05653e Ninja: try to make GetProcessId visible
ab245ff Ninja: but cl supports /nologo ...
bf58e9a Ninja: no /nologo option in old rc.exe
2fb07fc Ninja: Eclipse and KDevelop fixes for ninja
518c065 Ninja: don't pollute build dir with preprocessed rc files
...
2012-06-19 14:42:41 -04:00
Eric NOULARD 5ac6ca083f CPackDeb add missing documentation for some CPACK_DEBIAN_xx variables.
Inspired-By: Doug Linden <linderd@iinet.net.au>
2012-06-19 14:32:16 -04:00
James Bigler a20c41d032 Replace -g3 with -g for CUDA 4.1 and 4.2 in addition to CUDA < 3.0.
CUDA 4.1 reintroduced the bug where -g3 breaks compilation.  This
wasn't fixed until CUDA 5.0, so both CUDA 4.1 and 4.2 have this bug.
2012-06-19 10:04:51 -06:00
Jonathan Klein 4393b3bb43 FindBullet: Add missing math library name (#13309)
Add "LinearMath_Debug" to the list of names to search for
BULLET_MATH_LIBRARY_DEBUG.  The _Debug name is present in all other
lines already.  Now the script manages to find all debug&release
libraries on my system.
2012-06-18 08:29:41 -04:00
David Cole a7ae34a97f Merge topic 'RemoveASMDebugOutput'
0b343cb ASM compiler detection: remove debug output (#13270)
2012-06-14 16:28:44 -04:00
Alex Neundorf 0b343cb71e ASM compiler detection: remove debug output (#13270)
This must have been left in accidentially.

Alex
2012-06-12 22:27:34 +02:00
David Cole c95d1baa19 Merge topic 'position-independent-targets'
bd34963 Refactor generation of shared library flags
55d7aa4 Add platform variable for flags specific to shared libraries
31d7a0f Add platform variables for position independent code flags
2012-06-12 16:01:04 -04:00
David Cole c6f6929e31 Merge topic 'UseJava-13281'
5593d57 UseJava: fix find_jar() called with multiple files (#13281)
2012-06-12 16:00:49 -04:00
David Cole e21bcdc6c6 Merge topic 'FindBZip2-GnuWin32-registry'
7c912af FindBZip2: Search locations in GnuWin32 registry
2012-06-12 15:58:29 -04:00
David Cole d6483cb542 Merge topic 'FindPythonLibs-13216'
9d145b0 FindPythonLibs: honor EXACT version specification (#13216)
2012-06-12 15:58:18 -04:00
David Cole a8fa345ea2 Merge topic 'CPackRPM-emptyPerComponentREQUIRES'
7321c94 CPackRPM: avoid leakage of RPM directive from one component to another.
2012-06-12 15:58:03 -04:00
Stephen Kelly 55d7aa4c44 Add platform variable for flags specific to shared libraries
Store in CMAKE_${lang}_COMPILE_OPTIONS_DLL flags from
CMAKE_SHARED_LIBRARY_${lang}_FLAGS that are truly exclusive to shared
libraries.
2012-06-12 15:38:48 -04:00
Stephen Kelly 31d7a0f2e3 Add platform variables for position independent code flags
Store in new platform variables

  CMAKE_${lang}_COMPILE_OPTIONS_PIC
  CMAKE_${lang}_COMPILE_OPTIONS_PIE

flags for position independent code generation.

In almost all cases, this means duplication of the
CMAKE_SHARED_LIBRARY_${lang}_FLAGS for the _PIC case and using the
assumed pie equivalent for the _PIE case.  Note that the GNU compiler
has supported -fPIE since 3.4 and that there is no -fPIC on GNU for
Windows or Cygwin.

There is a possibility that the _PIE variables are not correct.
However, as there is no backwards compatibility to be concerned about
(as the POSITION_INDEPENDENT_CODE property is not used anywhere yet),
the current state suffices.
2012-06-12 15:37:53 -04:00
Peter Kuemmel 7553a3799a Ninja: fix ModuleNoticies test 2012-06-09 12:38:12 +02:00
Peter Kuemmel 8b27a94f28 Ninja: don't set cmcldeps vars to empty string when they are not defined 2012-06-09 12:10:52 +02:00
Peter Kuemmel 64c5752d93 Ninja: add copyright and description 2012-06-09 10:43:23 +02:00
Peter Kuemmel 0412e5c933 Ninja: assume cmcldeps in the same dir as cmake 2012-06-09 09:06:01 +02:00
Peter Kuemmel 941afa571c Ninja: allow spaces in source path
And make /showIncude prefix visible for all build rules
2012-06-08 22:59:18 +02:00
Peter Kuemmel 033a687acd Ninja: add wrapper for cl to extract dependencies
cmcldeps wraps cl and adds /showInclude before calling cl.
It parses the output of cl for used headers, drops system
headers and writes them to a GCC like dependency file.

cmcldeps uses ATM ninja code for process handling,
but could be ported later to SystemTools.

TODO: Why needs ninja multiple calls in the BuildDepends test?
2012-06-08 17:42:11 +02:00
Rolf Eike Beer 5593d5718e UseJava: fix find_jar() called with multiple files (#13281) 2012-06-08 17:35:32 +02:00
Brad King 7c912af2d0 FindBZip2: Search locations in GnuWin32 registry
The GnuWin32 "bzip2" installer stores in the registry key

 HKEY_LOCAL_MACHINE\SOFTWARE\GnuWin32\Bzip2

an "InstallPath" value.  Use this entry as a search location.
2012-06-05 16:01:54 -04:00
Rolf Eike Beer 9d145b0998 FindPythonLibs: honor EXACT version specification (#13216) 2012-06-05 21:00:24 +02:00
David Cole 7687d557dc Merge topic 'Ninja-EXPORT_COMPILE_COMMANDS'
3545645 Exclude the CompileCommandOutput test on WIN32.
fbaddf4 Escape the source file to be compiled if required.
db839be Make the CMAKE_EXPORT_COMPILE_COMMANDS option work with Ninja.
8778357 Add newline to the output.
2c04bc0 Move the EscapeJSON method to a sharable location.
2012-06-05 14:21:36 -04:00
David Cole 364b62747b Merge topic 'moduleLibLzma'
ee26019 Add FindLibLZMA Module
2012-06-05 14:21:18 -04:00
David Cole 9f933ffb3a Merge topic 'fix-13261-allow-variable-overrides'
8b2fb33 Mac: Add guards to CMAKE_FIND_FRAMEWORK and CMAKE_FIND_APPBUNDLE defaults
2012-06-05 14:21:09 -04:00
David Cole b0a8bc364d Merge topic 'qt4-phonon-backend'
ad7c80c Added conditional for the phonon backend plugin.
2012-06-05 14:20:47 -04:00
Eric NOULARD 7321c94e59 CPackRPM: avoid leakage of RPM directive from one component to another.
Fixes #0013248
Inspired-By: Sergei Golubchik
2012-06-05 10:20:43 +02:00
Stephen Kelly db839bec7d Make the CMAKE_EXPORT_COMPILE_COMMANDS option work with Ninja. 2012-06-04 23:42:37 +02:00
Mario Bensi ee26019bd4 Add FindLibLZMA Module 2012-05-31 09:10:38 -04:00
Charlie Sharpsteen 8b2fb3310b Mac: Add guards to CMAKE_FIND_FRAMEWORK and CMAKE_FIND_APPBUNDLE defaults
The default for `CMAKE_FIND_FRAMEWORK`, defined in `Darwin.cmake` and
`Darwin-icc.cmake`, is now guarded so that it will not override command line
arguments passed by users.

Similarly for `CMAKE_FIND_APPBUNDLE`
2012-05-31 08:10:17 -04:00
Kurtis Nusbaum ad7c80cd9f Added conditional for the phonon backend plugin.
If on APPLE, the phonon backend plugin is set to phonon_qt7. If on WIN32, the phonon backend plugin is set to phonon_ds9. I did not add any for generic UNIXes as they could have a whole host of things. A more comprehensive script would actually attempt to detect which phonon plugins were installed. However, this is a simple fix for now that will work for most people.
2012-05-29 14:56:07 -06:00
Tobias Bieniek 9ce67d3001 Qt4Macros: Added support for generated resource files
Using the QT4_ADD_RESOURCES() macro required the resource file to exist
already for dependency scanning.  This prevented the use of resource
files that are generated by cmake because it needs the file before
resolving the dependency.  This patch adds support for generated
resource files by not scanning the resource file for dependencies if it
doesn't exist yet.  The add_custom_command() to generate the resource
file should add the dependencies on the files used by the resource file.
2012-05-29 13:07:40 -04:00
David Cole 116a62c07e Merge topic 'HandleEmptySIZEOF_VOID_P'
14b213c add test for #13241: empty SIZEOF_VOIDP in write_basic_package_version_file
00ae36f write_basic_package_version_file() now works with unset CMAKE_SIZEOF_VOID_P
2012-05-24 13:39:00 -04:00
David Cole 8d83d20f2d Merge topic 'FindPythonLibs-doc-cache-vars'
c5c9af5 FindPythonLibs: Document cache variables (#13240)
2012-05-24 13:38:51 -04:00
David Cole 68d1774327 Merge topic 'ExternalProject-Ninja-superbuild'
c9097c7 ExternalProject: Fix 'make' builds with Ninja (#13159)
2012-05-24 13:38:25 -04:00
David Cole 59bdb879e8 Merge topic 'MakeDefaultInstallComponentNameConfigurable'
b71e731 -add docs for ${CMAKE_INSTALL_DEFAULT_COMPONENT_NAME}
7ced073 make default install component name configurable
b6fba35 -strip trailing whitespace
2012-05-24 13:37:54 -04:00
Alex Neundorf 00ae36fdff write_basic_package_version_file() now works with unset CMAKE_SIZEOF_VOID_P
This fixes #13241.
If CMAKE_SIZEOF_VOID_P is not set, either in the installed or in the
using project, don't check for it.

Alex
2012-05-23 20:46:48 +02:00
Zack Galbreath c5c9af5a73 FindPythonLibs: Document cache variables (#13240)
Add information on how to change which install of Python is found
by CMake.
2012-05-22 14:21:00 -04:00
Matt McCormick c9097c74b6 ExternalProject: Fix 'make' builds with Ninja (#13159)
Fix the build command when Ninja is the CMake Generator, but the
external project is created for a project that does not use CMake but
does use "make".
2012-05-21 18:57:11 -04:00
David Cole 3e595b9ee5 Merge topic 'FindwxWidgets-OpenBSD'
16ee197 FindwxWidgets: Do not use -isystem on OpenBSD (#13219)
2012-05-17 14:59:28 -04:00
David Cole d6ec477b52 Merge topic 'FeatureSummaryNicerFormatting'
b1d7c4b FeatureSummary.cmake: nicer formatting
2012-05-17 14:59:07 -04:00
David Cole 8f635d0268 Merge topic 'vs11-arm-generator'
5af93bb VS11: Fix ARM architecture hint typo (#13077)
0fa3d09 VS11: Add ARM architecture generator (#13077)
2012-05-17 14:58:41 -04:00
Alex Neundorf 7ced0732e8 make default install component name configurable
Until now an unnamed component was always named "Unspecified".
Now this name is taken from the new cmake variable CMAKE_INSTALL_DEFAULT_COMPONENT_NAME,
which is initialized to "Unspecified". But it can now be set to something
project-specific, per directory

Alex
2012-05-14 22:19:12 +02:00
Anthony J. Bentley 16ee19731e FindwxWidgets: Do not use -isystem on OpenBSD (#13219)
Set wxWidgets_INCLUDE_DIRS_NO_SYSTEM on OpenBSD in addition to Apple to
prevent UsewxWidgets.cmake from using the include_directories SYSTEM
option.
2012-05-14 16:01:35 -04:00
Alex Neundorf b6fba35411 -strip trailing whitespace
Alex
2012-05-13 17:38:31 +02:00
Alex Neundorf b1d7c4b1d2 FeatureSummary.cmake: nicer formatting
Alex
2012-05-13 14:37:51 +02:00
Brad King 5af93bb987 VS11: Fix ARM architecture hint typo (#13077) 2012-05-10 07:08:09 -04:00
Minmin Gong 0fa3d09369 VS11: Add ARM architecture generator (#13077) 2012-05-09 09:12:13 -04:00
Stephen Kelly 37a28ffa36 Fix the number variable comparison when Qt is not found. 2012-05-03 17:40:04 +02:00
David Faure 1dfe15c431 Abort FindQt4.cmake if Qt 5 is found. 2012-05-03 16:47:07 +02:00
David Cole 8df7aa54f0 Merge topic 'module-no-soname'
fdb3f87 Test NO_SONAME property (#13155)
e1409ac Support building shared libraries or modules without soname (#13155)
2012-05-01 14:09:59 -04:00
David Cole d05e12bc16 Merge topic 'intel-Windows-RTC1'
dd08062 Intel: On Windows use /RTC1 instead of deprecated /GZ (#13174)
2012-05-01 14:09:44 -04:00
David Cole 99f6055fe4 Merge topic 'fix-12564-avoid-git-re-clones'
08db81e ExternalProject: Avoid repeated git clone operations (#12564)
d14c024 ExternalProject: Refactor repeated code into function (#12564)
987c017 ExternalProject: Avoid unnecessary git clones (#12564)
2012-05-01 14:09:34 -04:00
David Cole 203be17fd0 Merge topic 'more-Intel-warnings'
f621ead Check{C,CXX}CompilerFlag: catch more Intel warning types (#12576)
2012-05-01 14:09:03 -04:00
Modestas Vainius e1409ac59b Support building shared libraries or modules without soname (#13155)
Add a boolean target property NO_SONAME which may be used to disable
soname for the specified shared library or module even if the platform
supports it.  This property should be useful for private shared
libraries or various plugins which live in private directories and have
not been designed to be found or loaded globally.

Replace references to <CMAKE_SHARED_LIBRARY_SONAME_${LANG}_FLAG> and
hard-coded -install_name flags with a conditional <SONAME_FLAG> which is
expanded to the value of the CMAKE_SHARED_LIBRARY_SONAME_${LANG}_FLAG
definition as long as soname supports is enabled for the target in
question.  Keep expanding CMAKE_SHARED_LIBRARY_SONAME_${LANG}_FLAG in
rules in case third party projects still use it.  Such projects would
not yet use NO_SONAME so the adjacent <TARGET_SONAME> will always be
expanded.  Make <TARGET_INSTALLNAME_DIR> NO_SONAME aware as well.  Since
-install_name is soname on OS X, this should not be a problem if this
variable is expanded only if soname is enabled.

The Ninja generator performs rule variable substitution only once
globally per rule to put its own placeholders.  Final substitution is
performed by ninja at build time.  Therefore we cannot conditionally
replace the soname placeholders on a per-target basis.  Rather than
omitting $SONAME from rules.ninja, simply do not write its contents for
targets which have NO_SONAME.  Since 3 variables are affected by
NO_SONAME ($SONAME, $SONAME_FLAG, $INSTALLNAME_DIR), set them only if
soname is enabled.
2012-04-30 11:50:27 -04:00
Brad King dd08062ac2 Intel: On Windows use /RTC1 instead of deprecated /GZ (#13174) 2012-04-30 08:29:47 -04:00
David Cole 08db81e008 ExternalProject: Avoid repeated git clone operations (#12564)
By tracking a stamp file within the git clone script itself.

Avoids a 2nd git clone operation after switching from Debug
to Release builds in Visual Studio, or vice-versa.
2012-04-28 15:02:17 -04:00
David Cole d14c02434a ExternalProject: Refactor repeated code into function (#12564)
Add "private/internal-use-only" function _ep_get_step_stampfile
to get the name of the stamp file for a given step.

The functionality provided by this commit should be identical
to its parent commit.
2012-04-28 14:54:04 -04:00
Rolf Eike Beer f621ead8b7 Check{C,CXX}CompilerFlag: catch more Intel warning types (#12576)
Patch provided by Szilárd Páll.
2012-04-27 00:52:55 +02:00
David Cole 987c017f6b ExternalProject: Avoid unnecessary git clones (#12564)
In the case of git, only track the repository in the
repository info dependency tracking file. Not the tag.

The download step should only re-run if the repository changes.
The download step should NOT re-run if the tag changes.

The update step is an 'always' re-running step, and so should
already re-run, unless it's been eliminated by use of

  UPDATE_COMMAND ""
2012-04-25 17:30:18 -04:00
David Cole 8bb46ee787 Merge topic 'intel-Windows-EHsc'
4f80896 Intel: On Windows use /EHsc instead of deprecated /GX (#13163)
2012-04-25 14:07:00 -04:00
David Cole 419f561b2f Merge topic 'fix-9946-uninstall-before-install'
fe58b67 Added CPACK_NSIS_ENABLE_UNINSTALL_BEFORE_INSTALL
2012-04-25 14:06:29 -04:00
David Cole 4b4a98d722 Merge topic 'fix-ExternalProject-COMMAND-niggly'
64818c1 ExternalProject: Add missing COMMAND keyword
2012-04-25 14:06:10 -04:00
David Cole d2230cdb5e Merge topic 'fix-13085-add-nsis-preinstall-hook'
aa8acea CPack/NSIS: Add CPACK_NSIS_EXTRA_PREINSTALL_COMMANDS (#13085)
2012-04-25 14:05:52 -04:00
David Cole 44e2bdc7a5 Merge topic 'CPack-fixManPage-typo'
94b24ad Fix CPack RPM man page typo detected by lintian.
2012-04-25 14:05:19 -04:00
David Cole 82c579de45 Merge topic 'fix-usejava-typo-13135'
8bdd449 UseJava: fix typo in variable name (#13135)
2012-04-25 14:02:32 -04:00
David Cole 65a4926326 Merge topic 'fix-pkgconfig-13125'
3ea850a FindPkgConfig.cmake: fix documented output variable not set (#13125,#13132)
2012-04-25 14:01:51 -04:00
David Cole 14be8dd264 Merge topic 'dev/fix-python3-findmodule'
4bdec58 Search for other ABIFLAGS builds of Python
6a46f5c Don't put legacy variables back into the cache
2012-04-25 14:00:41 -04:00
Brad King 4f80896e6c Intel: On Windows use /EHsc instead of deprecated /GX (#13163)
Use of the deprecated option with Intel 2011 produces

 icl: command line remark #10010: option '/GX' is deprecated and will
 be removed in a future release. See '/help deprecated'

so use its replacement option which has been supported for several
older versions anyway.
2012-04-24 09:00:37 -04:00
Patrick Gansterer fe58b67e24 Added CPACK_NSIS_ENABLE_UNINSTALL_BEFORE_INSTALL
If CPACK_NSIS_ENABLE_UNINSTALL_BEFORE_INSTALL is set to ON the NSIS installer will look for a previous installed version and ask the user about uninstall.
2012-04-22 11:30:34 -04:00
David Cole 64818c1077 ExternalProject: Add missing COMMAND keyword
Commit f67139ae added running a verify script in between running
the download and extract scripts. Since then, it has always been
missing the COMMAND keyword added in this commit.

It worked anyway (semi-accidentally) by running a command line like:

  cmake -P script1.cmake cmake -P script2.cmake

CMake, when running -P scripts on the command line, runs them in order,
and apparently ignores spurious arguments in between (the middle "cmake"
in the above example) and so, all appeared to work as intended.

This commit adds the missing keyword and the commands that run are
now two separate sequential cmake invocations like:

  cmake -P script1.cmake
  cmake -P script2.cmake

...which was the original intent of commit f67139ae
2012-04-22 09:10:01 -04:00
David Cole aa8acea398 CPack/NSIS: Add CPACK_NSIS_EXTRA_PREINSTALL_COMMANDS (#13085)
Allows custom NSIS commands to run prior to any installation
actions. Projects that need to run an uninstaller first,
especially one from a non-NSIS previous revision of a project
that is NOW using CPack and NSIS, may do so by putting custom
NSIS commands into this variable.

Inspired-by: David Golub
2012-04-21 11:36:25 -04:00
Modestas Vainius 94b24ad88d Fix CPack RPM man page typo detected by lintian.
Signed-off-by: Eric NOULARD <eric.noulard@gmail.com>
2012-04-20 20:41:18 +02:00
Rolf Eike Beer 8bdd44958b UseJava: fix typo in variable name (#13135)
As Dave Abrahams pointed out CMAKE_CURRENT_SOURCE_PATH is wrong, it's of
course CMAKE_CURRENT_SOURCE_DIR.

Also wrap the path in quotes so the example would even work if the source path
has spaces.
2012-04-16 22:41:49 +02:00
Rolf Eike Beer 3ea850a502 FindPkgConfig.cmake: fix documented output variable not set (#13125,#13132)
The real fix is from Yury G. Kudryashov while I added the surrounding cleanups.
An additional hint to really get this fixed came from Rex Dieter.
2012-04-15 08:39:51 +02:00
David Cole 194545643a Merge topic 'check_include_files_output'
5adb6b7 CheckIncludeFiles: Shorten check description message
2012-04-10 15:19:51 -04:00
David Cole 23dcf6ecd0 Merge topic 'new-boost-versions'
63d4960 FindBoost: add support for 1.49 and 1.50
2012-04-10 15:19:42 -04:00
David Cole 104f7cc00a Merge topic 'osx-search-paths'
6190415 OS X: Mark find_program results as advanced
d9edf46 OS X: Use correct extra path when searching for applicaton bundles (#13066)
98b9a7f OS X: Use OSX_DEVELOPER_ROOT for app search path (#13066)
2012-04-10 15:19:31 -04:00
David Cole 082fba0662 Merge topic 'CPackNSIS-smallDocTypoFix'
fcf265f CPackNSIS: Rewrite variable documentation to make it more readable.
8fe0da5 Fix some doc typo and add an undocumented var.
2012-04-10 15:19:22 -04:00
Brad King 5adb6b7a34 CheckIncludeFiles: Shorten check description message
Since commit 44d007b6 (CheckIncludeFiles: fix status output, 2012-02-01)
check_include_files reports the list of files tested instead of the name
of the variable storing the result.  Some projects incrementally test
and concatenate very long lists leading to long messages that do not
provide much information.  Users report confusion especially when the
lines wrap.

For lists of more than two files produce messages of the format

 Looing for N include files first.h, ..., last.h

where N is the list length and "..." is literal.  Leave the log file
entries and cache entry description unchanged as they should have the
full detail of the check performed.
2012-04-09 15:57:02 -04:00
Rolf Eike Beer 63d4960aef FindBoost: add support for 1.49 and 1.50
Boost 1.49 has already be released. Add this and the next to come version
number to the search list.
2012-04-07 10:21:02 +02:00
David Cole 6190415436 OS X: Mark find_program results as advanced
Avoid cluttering the gui with variables nearly nobody needs
to see.
2012-04-06 11:15:39 -04:00
David Cole d9edf46760 OS X: Use correct extra path when searching for applicaton bundles (#13066)
The parent commit added a search path relative to OSX_DEVELOPER_ROOT.
But with Xcode 4.3 the nested Applications folder is in a different
relative location compared to that root. This commit makes the intent
of the previous commit work with older and newer Xcode directory layouts.

Furthermore, it only adds paths that exist to the search path.
2012-04-06 11:14:37 -04:00
David Cole fcf265fe1a CPackNSIS: Rewrite variable documentation to make it more readable.
And avoid parsing problems at the first "."
2012-04-05 16:13:24 -04:00