Commit Graph

10142 Commits

Author SHA1 Message Date
Zach Mullen 727fa7bcb6 Fix ctest output alignment for cases where total tests run is not the same width as max test index. 2009-10-15 12:02:22 -04:00
David Cole 886ae02356 Fix crash on Windows. Remove trailing white space from regex. These changes should correct all failures of the new FailedSubmit tests. 2009-10-15 07:38:51 -04:00
KWSys Robot b5f63c6b7d KWSys Nightly Date Stamp 2009-10-15 00:00:27 -04:00
KWSys Robot 85b2f936d6 KWSys Nightly Date Stamp 2009-10-14 00:00:28 -04:00
David Cole 85feea2d0d Fix floating point comparison warnings. Thanks to Alex Neundorf for the patch. 2009-10-13 16:39:48 -04:00
Alexander Neundorf 4dc224e99a fix line length
Alex
2009-10-13 13:35:24 -04:00
Zach Mullen 7199badb00 Fix line length. 2009-10-13 08:56:38 -04:00
KWSys Robot e0230d7bef KWSys Nightly Date Stamp 2009-10-13 00:00:35 -04:00
David Cole 4439f17b20 Fix issue #5668 - use CollapseFullPath when determining if covered file is within source or binary tree. Allows gcc/gcov coverage analysis using MinGW on Windows. 2009-10-12 14:51:54 -04:00
Alexander Neundorf 45b8f2e441 fix indentation
Alex
2009-10-12 13:44:42 -04:00
Alexander Neundorf 03d55fb4c7 fix #9687
The CodeBlocks generator did not put all cmake files into the cmake tree of
the generated project. Patch from Daniel Teske.

Alex
2009-10-12 13:37:09 -04:00
Zach Mullen bf0e67fea3 Uncomment block in InitializeFromCommand (accidentally checked this change in) 2009-10-12 11:11:43 -04:00
Zach Mullen a5aa23d4e1 CTest-side support for compiler name and compiler version information. Requires CDash update to show on CDash. 2009-10-12 11:06:49 -04:00
KWSys Robot 300dcd45a0 KWSys Nightly Date Stamp 2009-10-12 00:00:39 -04:00
KWSys Robot 7eee2f0062 KWSys Nightly Date Stamp 2009-10-11 00:00:45 -04:00
KWSys Robot a450048fd5 KWSys Nightly Date Stamp 2009-10-10 00:00:52 -04:00
Zach Mullen 8fe2738096 Added OS Platform (cpu architecture) detection support to windows systems 2009-10-09 11:10:06 -04:00
KWSys Robot a59e01795d KWSys Nightly Date Stamp 2009-10-09 00:00:57 -04:00
Brad King 9a77f65da7 Remove CMake Policy CMP0015 until it is revised
We revert commit "Create CMake Policy CMP0015 to fix set(CACHE)" because
the NEW behavior of the policy breaks a valid use case:

  # CMakeLists.txt
  option(BUILD_SHARED_LIBS "..." ON)
  add_library(mylib ...)
  set(BUILD_SHARED_LIBS OFF) # we want only mylib to be shared
  add_subdirectory(ThirdParty)

  # ThirdParty/CMakeLists.txt
  option(BUILD_SHARED_LIBS "..." ON)
  # uh, oh, with NEW behavior this dir uses shared libs!!!

We'll re-introduce the policy later with a different change in behavior
to resolve the motivating case, which was more subtle but less common.

See issue #9008.
2009-10-08 14:56:15 -04:00
Brad King 24bf97440f REALLY fix color check for dependency scanning
The commit "Really fix color check for dependency scanning" disabled
color unless "make COLOR=ON" is specified.  This restores the previous
default behavior when CMAKE_COLOR_MAKEFILE is ON while retaining the
previous commit's fix.  See issue #9680.
2009-10-08 14:54:19 -04:00
Brad King dfa3b4f145 Really fix color check for dependency scanning
The commit "Fix color check for dependency scanning" was meant to
disable color if CMAKE_COLOR_MAKEFILE was off.  It did remove use of the
activation option '--color' but it failed to make the default false when
the option was missing.  This commit corrects that.  See issue #9680.
2009-10-08 14:45:25 -04:00
Brad King 65b6a8f54a Do not use -fPIC to link executables
The commit "add support for borland run time flag for shared builds"
started using the value of CMAKE_SHARED_LIBRARY_CXX_FLAGS to link
executables because Borland requires some flags both at compile and link
time.  This change ended up propagating all the way to the current
Makefile generators and the behavior applies on all platforms.

In general it is incorrect to use these flags to link executables.  The
commit "Split Borland compiler information files" re-wrote Borland
support to work without this behavior, so we remove it in this commit.

Patch from Ben Hutchings.  See issue #9659.
2009-10-08 11:56:30 -04:00
Brad King 0653286dc6 Split Borland compiler information files
This commit re-writes Borland compiler build rules.  We split the rules
into modern <os>-<id>-<lang> information modules but share a common
macro between languages to avoid duplication.

We also address a bug in the previous rules that would build some target
types against the static Borland runtime and others against the shared
Borland runtime in one build tree.  Now we always use the shared runtime
as is the default in the rules for MS tools.
2009-10-08 11:56:07 -04:00
Zach Mullen 2af045dfc5 Trimmed off the newline from sw_vers output on mac, it could cause xml parsing errors if left in 2009-10-08 10:56:55 -04:00
KWSys Robot f3a0fba75e KWSys Nightly Date Stamp 2009-10-08 00:01:02 -04:00
Brad King 71910b3fd4 Fix find_package() when <pkg>_DIR is wrong
When <pkg>_DIR is set to an incorrect version we search again and store
the result in the variable, even if it is <pkg>_DIR-NOTFOUND.

There was a bug in the case when the new search does not find anything
and the old value came from a cache entry with UNINITALIZED type.  The
command used to try to load a package configuration file from the last
place searched, and would leave the old wrong value in the entry.  This
commit fixes the behavior to avoid trying to load a missing file and to
set the value to <pkg>_DIR-NOTFOUND as expected.
2009-10-07 14:37:30 -04:00
Brad King 1b5a986a42 Do not collapse path of NOTFOUND values
In cmMakefile::AddCacheDefinition we collapse paths specified in PATH or
FILEPATH cache entries originally specified on the command line with
UNINITALIZED type.  This commit fixes the logic to avoid collapsing
<var>-NOTFOUND and other false values.  The change allows other CMake
code to force a NOTFOUND value on an entry with UNINITALIZED type.
2009-10-07 14:37:19 -04:00
Bill Hoffman 45d22b48ab fix Xcode 30 generator 2009-10-07 08:15:14 -04:00
KWSys Robot d542cc01cb KWSys Nightly Date Stamp 2009-10-07 00:01:07 -04:00
Brad King ca95b339fb Use integer literal instead of character
The commit "Support more special characters in file(STRINGS)" added code
using a 'char' literal as an array index.  Some compilers warn about
this because char might be a signed type, leading to negative indices.
We replace the literal with an integer to avoid the warning.
2009-10-06 17:51:34 -04:00
Brad King c6fdff2b22 Support more special characters in file(STRINGS)
The commits "Teach Fortran compiler identification about the Portland
Group compiler" and "Fix previous change to file(STRINGS) command"
taught file(STRINGS) to recognize the form-feed '\f' character as part
of string literals.  The Portland Group Fortran compiler also puts 0x14
bytes at the end of string literals in some cases.  We generalize the
previous solution and add the new character in this commit.
2009-10-06 16:33:15 -04:00
Zach Mullen 80533948b2 Fix bus error on mac. Was a result of not having null termination of arg list to sw_vers calls. 2009-10-06 14:55:48 -04:00
Alexander Neundorf 8a5ae4c15e speedup C dependency scanning even more
Scanning the dependencies for kdelibs/khtml/ (when all files are scanned) is
now down to 4.6 s from 6.3 s before this change (without the
headerLocationCache it takes about 14 s here).
It doesn't really make sense to include the complete include path as part
of the key for the map, since the include path will be the same for
all files in a project, so it doesn't add anything.

Alex
2009-10-06 13:57:41 -04:00
Brad King 9000b5a4de Avoid non-root copies of root-only targets
In cmGlobalGenerator::GetTargetSets we collect targets from all local
generators in a tree or subtree corresponding to a project() command.
Some targets, such as ALL_BUILD, are duplicated in each subdirectory
with a project() command.  For such targets we should keep only the copy
for the top-most (root) local generator.

Previously this filtering was done in each VS IDE generator, but it is
easier to do it in one place when the targets are first encountered.
This also fixes bad ALL_BUILD dependencies generated for VS 7.0 because
the cmGlobalVisualStudio7Generator::WriteTargetDepends method was not
filtering out duplicates.  Now we avoid duplicates from the start.
2009-10-06 13:30:00 -04:00
Zach Mullen 444e581860 Added better OS information for Mac OS X 2009-10-06 11:46:16 -04:00
Brad King d8f6d3a274 Target copy ctor should initialize internal state
The commit "Target copy ctor should copy internal state" created a new
cmTargetInternals constructor but failed to initialize a POD member that
the original constructor initializes.  This commit fixes it.
2009-10-06 09:59:05 -04:00
Brad King d4ef3bcf59 Use explicit conversion to avoid warnings in cmELF 2009-10-06 08:33:05 -04:00
KWSys Robot 6b14c1d273 KWSys Nightly Date Stamp 2009-10-06 00:01:05 -04:00
Brad King 02f85f98c6 Target copy ctor should copy internal state
Ideally we should never copy cmTarget instances, but it is a pain to
remove current uses of it.  The pimplized portion of cmTarget has mostly
members that cache results, but some are part of the object state.
These should be copied in the copy ctor instead of re-initialized.
2009-10-05 16:14:17 -04:00
Clinton Stimpson 08583fc58e don't allow consecutive generates without a configure. 2009-10-05 16:05:40 -04:00
Zach Mullen 7fd3d7cf80 BUG: #0009648 Change "The following tests FAILED" message to print on stdout rather than stderr 2009-10-05 12:47:09 -04:00
Brad King 4e1d610224 Remove old Encoding field from CMake.desktop
The Encoding key is now deprecated by the FreeDesktop standard and all
strings are required to be encoded in UTF-8.  This desktop entry
explicitly specified an Encoding of UTF-8, which is harmless but no
longer necessary.  See

  http://standards.freedesktop.org/desktop-entry-spec/1.0/apc.html

for details.  Patch from Modestas Vainius.  See issue #9659.
2009-10-05 10:26:08 -04:00
Zach Mullen b304186bc5 Match width of ctest "Start xx: " line to line up with the end test line 2009-10-05 10:20:52 -04:00
Brad King 0fb5b2c88c Invalidate target link info when necessary
In cmTarget we compute the link implementation, link interface, and link
closure structures on-demand and cache the results.  This commit teaches
cmTarget to invalidate results after a LINK_INTERFACE_* property changes
or a new link library is added.  We also clear the results at the end of
the Configure step to ensure the Generate step uses up-to-date results.
2009-10-05 09:06:59 -04:00
Brad King daa2f3aa41 Combine duplicate code in target property methods
In cmTarget::SetProperty and cmTarget::AppendProperty we check whether
changing the property invalidates cached information.  The check was
duplicated in the two methods, so this commit moves the check into a
helper method called from both.
2009-10-05 09:06:44 -04:00
Brad King 78f0811628 Create explicit cmTarget::FinishConfigure step
This method is called during ConfigureFinalPass on every target.  It
gives each target a chance to do some final processing after it is known
that no more commands will affect it.  Currently we just call the old
AnalyzeLibDependencies that used to be called directly.
2009-10-05 09:06:29 -04:00
Brad King 847875bebd Remove unused cmTarget::AddLinkLibrary method 2009-10-05 09:05:57 -04:00
KWSys Robot b783fbd04c KWSys Nightly Date Stamp 2009-10-05 00:01:03 -04:00
Alexander Neundorf b3040beb41 fix two more warnings from icpc
asfGlob and abfGlob were there since rev 1.3 of this file (Oct 17th 2004) and unused since
then, so remove them

Alex
2009-10-04 11:40:02 -04:00
Bill Hoffman a9fa71a47c Try to avoid cronic random failures on some Macs. 2009-10-04 09:54:55 -04:00
Bill Hoffman 78f68ef1b7 Try to avoid cronic random failures on some Macs. 2009-10-04 09:32:48 -04:00
KWSys Robot eddfb095f9 KWSys Nightly Date Stamp 2009-10-04 00:01:06 -04:00
Alexander Neundorf eb91859d6f remove unused variables, reported by icpc
Alex
2009-10-03 08:35:57 -04:00
KWSys Robot b1686031e4 KWSys Nightly Date Stamp 2009-10-03 00:01:03 -04:00
David Cole ccb0cf1306 Fix warnings in CMake source code. 2009-10-02 15:30:01 -04:00
David Cole 837364cb04 Correct some typos in error messages in the string command. Add a test that covers more of the code implemented in cmStringCommand.cxx, especially the error handlers. 2009-10-02 14:51:43 -04:00
Brad King 3d3efbd3f5 Clarify documentation and message for CMP0012
This commit re-words the warning message produced for CMP0012 to avoid
the word 'you' since often the person reading the message is not the
author of the code.  We also add an example of the bad OLD behavior to
the policy documentation.
2009-10-02 14:36:47 -04:00
Brad King 5837f4a613 Fix documentation of CMP0012 and CMP0013 versions
These policies were originally developed during the 2.7.x series and
intended for 2.6.5.  There was never a 2.6.5 release, so we should refer
to 2.8.0 instead.
2009-10-02 14:04:57 -04:00
Brad King c513962701 Create INTERPROCEDURAL_OPTIMIZATION build feature
This commit creates target and directory properties to enable the Intel
interprocedural optimization support on Linux.  Enabling it adds the
compiler option '-ipo' and uses 'xiar' to create archives.

See issue #9615.
2009-10-02 13:52:13 -04:00
Brad King 1e48243591 Introduce "build feature" lookup framework
This creates cmTarget::GetFeature and cmMakefile::GetFeature methods to
query "build feature" properties.  These methods handle local-to-global
scope and per-configuration property lookup.  Specific build features
will be defined later.
2009-10-02 13:52:01 -04:00
Brad King 57df2abca8 Centralize language flag addition for Makefiles
We create cmMakefileTargetGenerator::AddFeatureFlags to consolidate
addition of language flags.  Currently it just adds the flags from
generic per-language flag variables (AddLanguageFlags).
2009-10-02 13:51:49 -04:00
Brad King 2117143103 Document CMAKE_CURRENT_LIST_FILE more precisely
There is confusion whether the file "currently being processed" inside a
function or macro is the file containing the definition or not.  This
commit explicitly describes the behavior.  See issue #9646.
2009-10-02 13:22:13 -04:00
KWSys Robot 2e78b58d79 KWSys Nightly Date Stamp 2009-10-02 00:01:09 -04:00
David Cole 44bcba7461 Fix warnings in CMake source code. Suppress rampant warnings emanating from Qt files. 2009-10-01 16:47:08 -04:00
Brad King 1b9e61f214 Add alternative _UTILITY targets to all solutions
In VS 6, 7, and 7.1 solutions we implement

  add_dependencies(myexe mylib) # depend without linking

by creating an intermediate mylib_UTILITY target with dependencies

  myexe -> mylib_UTILITY -> mylib

to avoid linking myexe to mylib.  Previously these extra targets were
only added to the solution files in an ancestor directory of that
defining mylib.  For example, in the project:

  # CMakeLists.txt
  project(TOP)
  add_subdirectory(A)
  add_subdirectory(b)

  # A/CMakeLists.txt
  add_library(mylib ...)

  # B/CMakeLists.txt
  project(B)
  add_executable(myexe ...)
  add_dependencies(myexe mylib)

the solution for TOP would have mylib_UTILITY but the solution for B
would not even though it pulls in mylib through the dependency.  This
commit fixes solutions generated in other directories so that any
solution that has mylib will get mylib_UTILITY also.

See issue #9568.
2009-10-01 10:27:02 -04:00
Brad King c8ddb6813b Cleanup cmGlobalGenerator::GetTargetSets method
This commit cleans up the declaration, definition, and invocations of
the GetTargetSets method and related code.  There is no change in
function except to make the method virtual.
2009-10-01 10:26:54 -04:00
KWSys Robot 3810911f56 KWSys Nightly Date Stamp 2009-10-01 00:01:11 -04:00
Brad King 51ba120844 Remove unused members of local VS 6 generator
The commit "Use target dependency closure for VS 6 solutions" removed
use of the CreatedProjectNames list, so we remove it.
2009-09-30 16:03:09 -04:00
Brad King 55eec2a5bf Use target dependency closure for VS 6 solutions
This teaches the VS 6 IDE generator to use the transitive closure of
target dependencies.  This re-uses much of the implementation already
done for the other VS>6 generators.  See issue #8223 and issue #9568.
2009-09-30 16:03:03 -04:00
Brad King 7e5c571cce Move OrderedTargetDependSet into VS superclass
We move cmGlobalVisualStudio7Generator::OrderedTargetDependSet up to
cmGlobalVisualStudioGenerator so it can be re-used for other VS
versions.  See issue #9568.
2009-09-30 16:02:58 -04:00
Brad King c63e3bd13c Fix get_filename_component() registry view
Some find-modules use get_filename_component() to expand registry
values.  We need to look in both the 32-bit and 64-bit registry views
when expanding values.  We prefer the one that the target application
would see.  See issue #8792.
2009-09-30 13:45:24 -04:00
Brad King 56d1a1780d Create cmMakefile::PlatformIs64Bit helper method
This method centralizes tests for whether CMAKE_SIZEOF_VOID_P is 8.
2009-09-30 13:45:14 -04:00
David Cole f9c0e13975 Fix warnings in CMake source code. 2009-09-30 11:46:42 -04:00
David Cole 004626d179 Fix warnings in CMake source code. 2009-09-30 11:42:40 -04:00
David Cole a9dcc7fd47 Fix warnings in CMake source code. Suppress warnings in Lexer and Parser files that are 'too hard' to fix. 2009-09-30 11:41:34 -04:00
Brad King 67530409a9 Fix module definition file reference for VS6 NMake
When building through NMake with VS 6, the module definition file must
be passed without spaces in the path.  This is because 'cl -link' does
not escape the spaces when passing the value on to the linker.
2009-09-30 10:12:54 -04:00
Brad King f40406ed6b Fix default install prefix on Haiku
Since Haiku does not have /usr (and therefore /usr/local), this commit
changes the default install prefix to the equivalent directory of
/boot/common.

See issue #9607.
2009-09-30 08:31:53 -04:00
KWSys Robot 27c04be03a KWSys Nightly Date Stamp 2009-09-30 00:01:27 -04:00
Brad King 024d05adad Fix use of module .def files for MS tools
We recognize .def source files and map them to the /DEF:<file> option in
the MSVC tools.  Previously this worked only for shared libraries.  This
commit cleans up the implementation and makes it work for executables
too.  See issue #9613.
2009-09-29 16:39:07 -04:00
Brad King caee3af3c5 Do not parse preprocessor defs for VS 10 link/lib
When constructing cmVisualStudioGeneratorOptions to parse options for
tools 'link' and 'lib' the tool type is now Linker, not Compiler.  This
tells it not to recognize flags starting in '/D' as preprocessor macros,
such as the '/DEF:<file>' linker option.  See issue #9613.
2009-09-29 16:38:43 -04:00
Brad King d6b47bee79 Add StringProperty options for VS 10 flag table
The commit "cmparseMSBuildXML should output StringProperty values too"
fixed the script that generated

  Source/cmVS10CLFlagTable.h
  Source/cmVS10LibFlagTable.h
  Source/cmVS10LinkFlagTable.h

This commit updates the files with the new output.
2009-09-29 16:37:06 -04:00
Zack Galbreath 70614b9e6a BUG: cmparseMSBuildXML should output StringProperty values too 2009-09-29 15:07:39 -04:00
Zach Mullen a5be445ca9 BUG: CTest should honor test timeouts. 2009-09-29 14:31:58 -04:00
Zach Mullen 202bb45695 BUG: 0009612: --output-on-failure option doesn't work with the new parallel CTest handler 2009-09-29 09:45:43 -04:00
Brad King aa8c003609 Qualify std::map compare functor as const
Some older STL implementations invoke the comparison functor as a const
object, so the function call operator must be 'const' qualified.  This
fixes the commit "Fix support for OLD behavior of policy CMP0002" to
compile on older STLs.
2009-09-29 08:34:39 -04:00
KWSys Robot defd8b87e1 KWSys Nightly Date Stamp 2009-09-29 00:01:07 -04:00
Bill Hoffman 24624e02f1 Make sure LINK_FLAGS are seen by generator, fix for part of bug#9613 2009-09-28 21:19:20 -04:00
Brad King 0089f9cf8f Fix support for OLD behavior of policy CMP0002
The commit "Cleanup make progress rule generation code" introduced a map
from target name to the progress.make file location.  Policy CMP0002's
OLD behavior allows duplicate target names in different directories, so
only one ends up with a progress.make file.  This commit fixes the map
to order by target name first and build directory second, restoring
support for duplicate target names.
2009-09-28 17:34:23 -04:00
David Cole a091e99cb9 Fix issue #8818 - escape quotes in the license file when using the DragNDrop cpack generator. Thanks to Clinton Stimpson for the patch. 2009-09-28 17:14:53 -04:00
Brad King 96afb12087 Convert CMake to OSI-approved BSD License
This converts the CMake license to a pure 3-clause OSI-approved BSD
License.  We drop the previous license clause requiring modified
versions to be plainly marked.  We also update the CMake copyright to
cover the full development time range.
2009-09-28 11:43:28 -04:00
Brad King de955e4b6d Convert KWSys to OSI-approved BSD License
This converts the KWSys license to a pure 3-clause OSI-approved BSD
License.  We drop the previous license clause requiring modified
versions to be plainly marked.  We also update the KWSys copyright to
cover the full development time range.
2009-09-28 11:37:35 -04:00
Brad King 832f0a88f0 Install KWSys Copyright.txt as documentation
This commit adds KWSys configuration option KWSYS_INSTALL_DOC_DIR to
specify the directory for installation of documentation.  We use it to
put the KWSys Copyright.txt file at the location

  ${KWSYS_INSTALL_DOC_DIR}/${KWSYS_NAMESPACE}/Copyright.txt

in the project installation tree.  This helps containing projects meet
the license requirement to distribute the copyright and license with
binary forms.
2009-09-28 11:36:54 -04:00
Brad King 6f010f1c40 Fix .vfproj file version for Intel Fortran 10.1
The commit "Generate proper Intel Fortran project version" replaced the
hard-coded 9.10 value with a runtime registry lookup of the real
version.  Version 10.1 actually uses project file format 9.10, so this
commit switches it back for that version.  See issue #9169.
2009-09-28 10:00:14 -04:00
Brad King 6c59b924d2 Use BeAPI for per-user package registry on Haiku
Applications on Haiku are discouraged from storing their data in $HOME.
This teaches export(PACKAGE) and find_package() to use the BeAPI on
Haiku to store the package registry instead of using ~/.cmake/packages.

See issue #9603.
2009-09-28 09:45:34 -04:00
KWSys Robot f73c769dd6 KWSys Nightly Date Stamp 2009-09-28 00:01:04 -04:00
KWSys Robot babd4c6da8 KWSys Nightly Date Stamp 2009-09-27 00:01:04 -04:00
Alexander Neundorf 253dafd025 Fix bug #9529.
Set the working_dir entry in the codeblocks project file of executable
targets to the directory where the executable is created. Then when running
CB, executing the target (not building), will run it from that directory.

Alex
2009-09-26 04:26:28 -04:00
KWSys Robot 680c780b22 KWSys Nightly Date Stamp 2009-09-26 00:01:04 -04:00
David Cole f199385605 Fix CMake Internal Error from cmTarget::GetOutputInfo - triggered by calling GetLocation on a utility target - caused by custom command output file with same name as custom target. The fix is to avoid calling GetLocation unless the target is of a type that is expected to have a location... 2009-09-25 13:23:19 -04:00
Brad King 9c626d8f68 Policies 14 and 15 will be first released in 2.8.0
CMake policies CMP0014 and CMP0015 were implemented in the development
series version 2.7.x but will be first released in 2.8.0.  Now that the
development version number is higher than that (2.9.x) we can update
their version of introduction to the actual release number.
2009-09-25 13:09:43 -04:00
Brad King 528097c794 Document full version number with policy default
In CMake Policy documentation we specify the default behavior for the
current version of CMake.  This commit fixes that version by reporting
the full version number instead of just major and minor.
2009-09-25 13:09:36 -04:00
Zach Mullen 5e06f0a557 Fixed uninitialized memory issue in ctest show-only mode 2009-09-25 11:45:19 -04:00
Brad King 9027506b10 Avoid word 'Copyright' in KWSys MD5 encode test
We replace the test text in the kwsys.testEncode test to avoid the word
'Copyright'.  This simplifies grep results for Copyright verification.
2009-09-25 11:19:39 -04:00
KWSys Robot 35c8e2e35e KWSys Nightly Date Stamp 2009-09-25 00:01:08 -04:00
Zach Mullen 5a2f24856e Output a message in ctest when each test is started 2009-09-24 13:49:20 -04:00
Zach Mullen 2e5ccdbc18 Removed comment 2009-09-24 11:09:10 -04:00
Zach Mullen 65c418e56f Reformat ctest -N output. Removed the "Start processing tests" message as well. 2009-09-24 09:49:46 -04:00
Brad King f10929ae7c Restore KWSys SystemTools _WIN32 state on cygwin
The commit "Fix KWSys SystemTools build on cygwin with -mwin32" tried to
restore the state of the _WIN32 definition that was broken by the commit
"Optimize KWSys SystemTools::FileExists on Windows".  It did so for the
case of building with -mwin32 on cygwin, but since including <windows.h>
defines _WIN32, it failed for the case of not using -mwin32.

This commit restores the state of _WIN32 in all cases by undefining it
after including <windows.h> if it was not defined beforehand.
2009-09-24 08:10:46 -04:00
KWSys Robot d6ffe2d512 KWSys Nightly Date Stamp 2009-09-24 00:01:04 -04:00
Zach Mullen 84f3f6cad6 Tests which are not run should be added to the failed test list. 2009-09-23 15:37:50 -04:00
Brad King bd33da9fcc Add Xcode SYMROOT setting for custom targets
Xcode 1.5 writes helper scripts at the projectDirPath location for
targets that do not set SYMROOT.  We now add SYMROOT to custom targets
so that all targets set it.  This prevents Xcode 1.5 from touching the
source directory now that we always set projectDirPath.

See issue #8481.
2009-09-23 14:10:08 -04:00
Alexander Neundorf 39383ef8cb Major optimization of C/C++ dependency scanning.
Now only the dependencies for the file where the dependencies actually may
have changed are rescanned, before that this was done for all source files
even if only one source file had changed.
This reduces e.g. on my machine the time for scanning the dependencies
of kdelibs/khtml/ when only one file (khtml_global.cpp) has changed from
around 7.5 seconds to 1.2 seconds.

The tests succeed, it does what I expected it to do on kdelibs, and Brad
also reviewed the patch, so I think it should be ok.

Alex
2009-09-23 14:02:05 -04:00
Clinton Stimpson 551fcc23c2 fix compile warnings 2009-09-23 13:09:56 -04:00
Brad King 4e121af95e Fix KWSys SystemTools build on cygwin with -mwin32
Commit "Optimize KWSys SystemTools::FileExists on Windows" accidentally
added "#undef _WIN32" when including <windows.h> on cygwin, which breaks
builds using the -mwin32 flag.  This commit removes that line and fixes
the real error it was intended to avoid.
2009-09-23 10:45:00 -04:00
Brad King e55bbab88b Teach Xcode generator to set XCODE_VERSION
We set the variable 'XCODE_VERSION' in the CMake language to the Xcode
version string (e.g. "3.1.2").  Platform config files may use it later.
2009-09-23 08:48:39 -04:00
KWSys Robot 07a473d5f5 KWSys Nightly Date Stamp 2009-09-23 00:01:07 -04:00
Clinton Stimpson ecfca5d0a8 fix issue 9346. add binary directory to window title to make it easier to deal with multiple cmake-gui instances 2009-09-22 18:29:35 -04:00
Brad King 61495cdaae Fix Xcode project references to the source tree
Xcode project source file references need to always be relative to the
top of the source tree in order for SCM and debug symbols to work right.
We must even allow the relative paths to cross outside of the top source
or build directories.

For subdirectory project() command Xcode projects we use the source
directory containing the project() command as the top.  Relative paths
are generated accordingly for each subproject.

See issue #8481.
2009-09-22 16:18:31 -04:00
Brad King 3fe5f8d960 Optionally force conversion to relative path
In cmLocalGenerator::ConvertToRelativePath we normally convert to
relative path only if the local and remote paths both lie inside the
source tree or both lie inside the build tree.  This commit adds an
optional 'force' argument to allow conversion even when this rule is
violated.
2009-09-22 16:16:56 -04:00
Bill Hoffman fe57e7252f Can not use cmakedefine in kwsys because bootstrap of cmake does not support it. 2009-09-22 15:59:26 -04:00
Bill Hoffman 472966ed5f Can not use cmakedefine in kwsys because bootstrap of cmake does not support it. 2009-09-22 15:58:13 -04:00
Bill Hoffman e7601ca600 Put a flag in that will stop system tools from deleting system environment memory on exit, as it can cause gcov to crash the programs. 2009-09-22 14:56:33 -04:00
Alexander Neundorf 03d032b637 Rescan dependencies also if CMakeDirectoryInformation.cmake has changed.
If CMakeDirectoryInformation.cmake is newer than depend.internal the include
directories may have changed, so dependencies need to be scanned again.
Ok by Brad.

Alex
2009-09-22 14:40:23 -04:00
Brad King 9b6c3d0782 Optimize KWSys SystemTools::FileExists on Windows
We optimize this method by using the GetFileAttributesExA native Windows
API to check for file existence when possible.  For real Windows builds
we always use it.  For Cygwin we use cygwin_conv_to_win32_path to get a
native Windows path if possible and otherwise fall back to 'access'.

Cygwin-to-Windows path conversion and cache by Wojciech Migda.
See issue #8826.
2009-09-22 13:02:20 -04:00
KWSys Robot ca29998943 KWSys Nightly Date Stamp 2009-09-22 00:01:03 -04:00
Zach Mullen 4342e37d63 More SLURM experimentation (ctest batch mode) 2009-09-21 15:29:34 -04:00
Zach Mullen a4c6f178fe Fixed a slurm batch argument identifier. 2009-09-21 14:58:30 -04:00
Zach Mullen 87b4c66ca8 Need to quote args when generating batch scripts from ctest 2009-09-21 14:21:41 -04:00
Zach Mullen e4293b4b38 Re-enabled failing tests; fixed ctest_build output to be consistent in the error condition across different make programs so that these tests would pass. 2009-09-21 13:40:40 -04:00
Bill Hoffman 43499b1ecb Fix Bug #8332, add support for .pch files for Xcode. 2009-09-21 13:18:45 -04:00
Bill Hoffman 441cd9ce0b Fix Bug #8928, add support for .xib files for Xcode. 2009-09-21 13:15:11 -04:00
KWSys Robot 004f9931a9 KWSys Nightly Date Stamp 2009-09-21 00:01:04 -04:00
KWSys Robot 2396ff9889 KWSys Nightly Date Stamp 2009-09-20 00:01:18 -04:00
Alexander Neundorf 864e2670d6 Minor optimization in dependency checking.
When reading the depend.internal file, check only once for every depender
whether it exists, instead of repeatedly in a loop for each dependee. Within
that function it can only change of the depender is removed. This is taken
care of.
This reduces the number of access() calls in kdelibs/khtml from 180000 to
90000 (i.e. 50%), and reduces the time for that (without the actual
scanning) from 0.3 s to 0.21 s on my system.

Alex
2009-09-19 13:02:12 -04:00
Brad King d4cfb77ffe Remove cmGlobalXCode21Generator subclass
This subclass of cmGlobalXCodeGenerator only provided two virtual method
overrides, and it made construction of the Xcode generator instance
complicated.  This commit removes it and replaces the virtual methods
with tests of the Xcode version.  The change removes duplicate code.
2009-09-19 12:00:09 -04:00
Brad King 180c60a86f Fix check for -isysroot on OS X
Previously we checked for this flag by parsing the version number of GCC
out of 'gcc --version', but this is not reliable because the format can
vary greatly.  Now we run 'gcc -v --help' and look for '-isysroot' in
the list of options.

We also now store the result on a per-language basis in the per-compiler
info file "CMake<LANG>Compiler.cmake".  This is necessary to make it
accessible from try-compile projects so that they generate correctly.
2009-09-19 10:14:31 -04:00
KWSys Robot 5ea5ca3c88 KWSys Nightly Date Stamp 2009-09-19 00:01:41 -04:00
Bill Hoffman e7d75864d1 Only do the OSX arch stuff on OSX. 2009-09-18 15:16:33 -04:00
Bill Hoffman 58818d5168 Add detection of gcc versions that do not support isysroot option and do not use it for them. 2009-09-18 14:22:20 -04:00
Bill Hoffman 311eb30672 Fix the build for version 2.5 of Xcode. 2009-09-18 10:28:28 -04:00
KWSys Robot b872d09ea2 KWSys Nightly Date Stamp 2009-09-18 00:01:06 -04:00
Bill Hoffman 6362d4c743 Fix case where no archs are found on older macs. 2009-09-17 16:09:52 -04:00
Bill Hoffman ea282284d5 Fix for bug #9466. Change the implementation of OSX arch lists. If no ARCHs are specified by the user then no flags are set. We no longer use CMAKE_OSX_ARCHITECTURES_DEFAULT. 2009-09-17 11:53:02 -04:00
Bill Hoffman 8e8c9b7242 Bug #9430, recognize the FR flag 2009-09-17 09:18:21 -04:00
Brad King c87a35a326 Do not call CollapseFullPath for PDB file names
Some vendor tools convert PDB file names given on the command line to
lower-case before creating the file.  When CMake places a mixed-case PDB
file name into the build system, the file does not exist the first time
and it is written with mixed case.  After the first build though the
native tool has created a lower-case version of the file.  If CMake does
CollapseFullPath again, the file exists so the actual-case lookup gets
the lower-case name.  This causes the build files to change so the
project rebuilds.

The solution is to avoid calling CollapseFullPath for files generated by
the build.  In the case of PDB files we already construct them from
paths that have been collapsed, so we can just skip the call altogether.
See issue #9350.
2009-09-17 08:42:31 -04:00
Brad King ef8434284f Remove old check for duplicate subdirectories
In cmMakefile::AddSubDirectory we were checking for addition of the same
source directory multiple times.  However, the check code was incorrect
because it compared pointers instetad of pointed-to strings.  Since the
check was written, a better check was added right after it to enforce
unique binary directories (in which case duplicate sources are fine).
This commit simply removes the old-style check code.
2009-09-17 08:25:33 -04:00
KWSys Robot ab64fba44f KWSys Nightly Date Stamp 2009-09-17 00:01:03 -04:00
Bill Hoffman bf9a561cfa Fix typo in name 2009-09-16 21:02:57 -04:00
Alexander Neundorf 298de4374b Major improvement of the generated targets in Eclipse.
Before this change all targets were displayed in the top level directory of
the project. Now the targets are displayed in the correct directory.
The targets "clean" and "all" are now created in every subdirectory.
Also now the targets for just compiling one file, preprocessing one file,
assembling one file are are created for Eclipse.
Additionally all targets get a prefix now in eclipse, so that they are
sorted in a way which makes sense (global targets first, then executable and
libraries, then object files, then preprocessed, then assembly). Also
this prefix gives the user a hint what the target is, i.e. whether it's a
library or an executable or something else.

Alex
2009-09-16 18:01:23 -04:00
Brad King 6e8aeba415 Teach configure_file to handle directory names
This commit teaches configure_file how to handle directories for input
and output.  It is an error if the input is a directory.  If the output
is a directory we put the configured copy of the input file in it with
the same name.  See issue #9537.
2009-09-16 15:09:42 -04:00
Brad King 700cdf393a Teach configure_file to handle relative paths
The configure_file() command now converts relative output paths to full
paths using the current binary directory.  Input relative paths were
already converted using the current source directory, but this behavior
was not previously documented.
2009-09-16 15:09:29 -04:00
Brad King dda0da8b9e Fix typo in cmConfigureFileCommand ivar name
Rename 'OuputFile' to 'OutputFile'.
2009-09-16 15:09:19 -04:00
Alexander Neundorf 9d967ed47b Put compiler defined macros into eclipse project files
Now gcc is queried also for the builtin definitions, and they are then added
to the .cproject file. This should make the preprocessor highlighting in
eclipse work better (#9272)
Patch mostly from Miguel.

Alex
2009-09-16 14:37:21 -04:00
Bill Hoffman 932dac93b7 Fix uninitialized errors. 2009-09-16 11:49:09 -04:00
Brad King 2006e4a405 Generate proper Intel Fortran project version
The Intel Visual Fortran compiler plugin for MS Visual Studio may be one
of several versions of the Intel compiler.  This commit teaches CMake to
detect the plugin version and set the version number in .vfproj files.
See issue #9169.
2009-09-16 11:44:50 -04:00
Brad King 09e398fa9f Create VS generator GetRegistryBase method
This method returns the registry key

  HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\VisualStudio\<version>

A protected GetIDEVersion method retrieves the version-specific part of
the key name.
2009-09-16 11:44:08 -04:00
Brad King 24861459b5 Initialize directory scope with closure of parent
The commit "Improve dynamic variable scope implementation" optimized
function scopes using an efficient parent scope pointer.  However, the
parent scope used to initialize a new directory might not exist later
(like add_subdirectory called inside a function of the parent scope).
This caused CMake to crash when following the dangling pointer to the
original parent scope.

We fix the problem in this commit by always computing the closure of the
parent scope at directory initialization time so that no parent scope
pointer is needed.  See issue #9538.
2009-09-16 09:51:47 -04:00
KWSys Robot 2c8e929a70 KWSys Nightly Date Stamp 2009-09-16 00:01:21 -04:00
KWSys Robot 842098defc KWSys Nightly Date Stamp 2009-09-15 00:01:03 -04:00
Bill Hoffman 77dfbd49b4 Fix for bug #8969, pick a better default version for VS, and make it easier to add new versions of VS to look for. 2009-09-14 22:16:43 -04:00
Bill Hoffman 899f11f919 Fix for bug# 5373, include CMake verison in generated docs. 2009-09-14 20:54:22 -04:00
Bill Hoffman 0a8532c3a0 Bug #8356, add support for image types in Xcode files. 2009-09-14 15:20:15 -04:00
Bill Hoffman 324f51cfc8 Fix for bug #8807, add support for CMAKE_EXE_LINKER_FLAGS_(config) to Xcode generator. 2009-09-14 14:59:28 -04:00
Bill Hoffman c83591e818 Fix for Bug #9190, -U did not work on case insensitive file systems because of call to glob convert to regex that expected to work with files. 2009-09-14 13:45:40 -04:00
Bill Hoffman 14715ce813 Clarify documentation for if. 2009-09-14 13:42:04 -04:00
Zach Mullen 243bbae954 Removed fork-and-continue option from ctest generated batch script entries 2009-09-14 11:23:20 -04:00
Bill Hoffman 6a9a958591 Fix open solaris build issue with concept checking that breaks std vector for a class of itself. Bug #9523. 2009-09-14 10:31:38 -04:00
KWSys Robot c32ad6ce32 KWSys Nightly Date Stamp 2009-09-14 00:01:10 -04:00
KWSys Robot ab3d48a008 KWSys Nightly Date Stamp 2009-09-13 00:01:03 -04:00
Brad King bcbb4626a3 Avoid shadowing std::vector member
The cmProcess::Buffer class derives from std::vector.  We were using
local variable 'data' in the GetLine method but this name shadowed a
member of vector with GNU.  This renames it to 'text'.
2009-09-12 10:20:00 -04:00
KWSys Robot 054be74f8d KWSys Nightly Date Stamp 2009-09-12 00:01:03 -04:00
Bill Hoffman 63a7d85249 Fix for bug#9442, ctest crash if CTEST_SOURCE_DIRECTORY was not set. 2009-09-11 17:15:02 -04:00
Brad King 8c24c1dcc3 Fix new CTest output handling for no newline
When we clear the buffer for an output pipe after returning the last
partial line (without a newline) we need to set the partial line range
to empty.  Otherwise the buffer object is left in an inconsistent state.
2009-09-11 16:20:24 -04:00
Bill Hoffman 8a690289c2 Add label summary times to ctest default output. Also, remove parallel time output. Add flag to disable label summary. 2009-09-11 13:34:35 -04:00
Brad King 6a7eae7184 Rewrite CTest child output handling
This commit fixes cmCTestRunTest and cmProcess to more efficiently
handle child output.  We now use the buffer for each child output pipe
to hold at most a partial line plus one new block of data at a time.
All complete lines are scanned in-place, and then only the partial line
at the end of the buffer is moved back to the beginning before appending
new data.

We also simplify the cmProcess interface by making GetNextOutputLine the
only method that needs to be called while the process is running.  This
simplifies cmCTestRunTest so that CheckOutput can be called until it
returns false when the process is done.
2009-09-11 12:26:41 -04:00
Brad King b6c26cded2 Initialize cmCTestRunTest instances robustly
All instances of this class need a cmCTestTestHandler, so we now require
one to construct it.  The instance also provides the cmCTest instance
too.
2009-09-11 10:09:48 -04:00
Brad King 74b79d3b39 Remove barely-used cmCacheManager::AddCacheEntry
The commit "Remove barely-used cmMakefile::AddCacheDefinition" removed
all but one use of the cmCacheManager method 'bool' overload.  This
commit removes the other use and the entire method, thus reducing code
duplication.
2009-09-11 10:04:10 -04:00
Brad King 7a409fd573 Fix option() interpretation of non-boolean values
The commit "Remove barely-used cmMakefile::AddCacheDefinition" broke
option() calls that pass a non-boolean default value.  We restore the
old behavior by always coercing the value to 'ON' or 'OFF'.
2009-09-11 10:03:59 -04:00
Brad King b41a548d86 Add parentheses around '&&' between '||' for gcc
The GNU compiler warns about possible operator precedence mistakes and
asks for explicit parentheses (-Wparentheses).  We add the parentheses
to silence the warning.  This also fixes one real logic error in the
find_package() implementation by correcting expression evaluation order.
2009-09-11 08:18:15 -04:00
KWSys Robot e0df0495e5 KWSys Nightly Date Stamp 2009-09-11 00:01:04 -04:00
Brad King ee2b446c95 Create CMake Policy CMP0015 to fix set(CACHE)
The set(CACHE) and option() commands should always expose the cache
value.  Previously we failed to expose the value when it was already set
if a local variable definition hid it.  When set to NEW, this policy
tells the commands to always remove the local variable definition to
expose the cache value.  See issue #9008.
2009-09-10 16:59:45 -04:00
Brad King afbe088309 Remove barely-used cmMakefile::AddCacheDefinition
The boolean overload of this method was used only to implement option().
We re-implement option() in terms of the main method and removes the
now-unused signature.  This removes some duplicate code that had already
fallen behind on changes (it was not removing the local definition
instead of setting it).
2009-09-10 16:59:36 -04:00
Alexander Neundorf 6097c04c4d sync target generation with the CodeBlocks generator
Basically the code is now a copy of the one from the CodeBlocks generator,
maybe this could move into a common helper function somewhere:
-only insert GLOBAL targets from the toplevel directory
-don't insert the edit_cache target if it calls ccmake, since this doesn't
work in the output tab of Eclipse
-add the /fast targets

Alex
2009-09-10 13:49:51 -04:00
Alexander Neundorf 10f39d8c80 As in the Eclipse generator: don't insert the edit_cache target if it is ccmake, since this doesn't work in the output tab of the IDE 2009-09-10 13:44:02 -04:00
Zach Mullen c57fb18920 Added some ctest batch capabilities 2009-09-10 11:18:05 -04:00
Zach Mullen 4b4e801eba BUG: Fixed segfault and bad reporting if a ctest executable could not be found. Also added some batch testing code that is not yet complete. 2009-09-10 11:16:08 -04:00
KWSys Robot 55e4ac5ad1 KWSys Nightly Date Stamp 2009-09-10 00:01:03 -04:00
KWSys Robot 4678c619ce KWSys Nightly Date Stamp 2009-09-09 00:01:05 -04:00
Zach Mullen a516040579 ENH: ctest now writes time cost data to a file after a test set is run, and uses these time costs to schedule the processes the next time ctest is run in that build tree. 2009-09-08 17:10:35 -04:00
Zach Mullen 6727834a8c BUG: Fixed extraneous newlines from ctest process output 2009-09-08 14:48:23 -04:00
Zach Mullen 39e5f9d963 ENH: Replaced the EXPENSIVE test property with a COST test property taking a floating point value. Tests are now started in descending order of their cost, which defaults to 0 if none is specified. 2009-09-08 13:39:13 -04:00
Zach Mullen a02ef56401 BUG: Fixed issue where ctest would hang if a process terminated with output in its buffers but no newline 2009-09-08 10:16:16 -04:00
Zach Mullen 384f4d1f3f Fixed warning 2009-09-08 09:12:44 -04:00
KWSys Robot 5252ef4862 KWSys Nightly Date Stamp 2009-09-08 00:01:04 -04:00
Zach Mullen 5fb958fde9 ENH: Added ctest test options PROCESSORS and RUN_SERIAL. These allow specification of resource allocation for given tests running with the ctest -j N option. RUN_SERIAL ensures that a given test does not run in parallel with any other test. Also forced appending of "..." to the longest test name in ctest. 2009-09-07 10:26:17 -04:00
Brad King 4e16813f63 Put custom commands in topological order for VS 10
Visual Studio 10 uses MSBuild to drive the build.  Custom commands
appear in MSBuild files inside CustomBuild elements, which appear inside
ItemGroup elements.  The Outputs and AdditionalInputs elements of each
CustomBuild element are evaluated according to timestamps on disk.

MSBuild does not use inputs/outputs to order CustomBuild steps within a
single ItemGroup or across multiple ItemGroup elements.  Instead we must
put only unrelated CustomBuild elements in a single ItemGroup and order
the item groups from top to bottom using a topological order of the
custom command dependency graph.

This fixes CustomCommand and ExternalProject test failures, so we remove
the expectation of these failures.
2009-09-07 10:12:18 -04:00
Brad King 4224513cce Save source dependencies from custom command trace
In each target we trace dependencies among custom commands to pull in
all source files and build rules necessary to complete the target.  This
commit teaches cmTarget to save the inter-source dependencies found
during its analysis.  Later this can be used by generators that need to
topologically order custom command rules.
2009-09-07 10:11:43 -04:00
Brad King 355511ade9 Do Windows command line escapes for VS 10 too
Until now the VS 10 generator did no Windows command-line escaping and
just did XML escapes.  This commit teaches the generator to use the same
command-line escape addition code used by other generators.  The script
construction method cmLocalVisualStudioGenerator::ConstructScript need
not do XML escapes.  Each VS generator version adds the XML escapes
necessary for that version.
2009-09-07 10:11:20 -04:00
KWSys Robot f143dc2af2 KWSys Nightly Date Stamp 2009-09-07 00:01:04 -04:00
Alexander Neundorf 21179a2ade Try to fix the failing new StringFileTest on HP-UX
It seems that
while(i=file.get(), file)
iterates one character too much on HP-UX, let's see whether
while(file.get(c))
works, at least this is given as example on http://h30097.www3.hp.com/cplus/ifstream_3c__std.htm

Alex
2009-09-06 13:24:56 -04:00