Commit Graph

528 Commits

Author SHA1 Message Date
David Cole 10a4abddfd Add missing archive_read_finish calls to fix some of the presently reported valgrind memory leaks. 2009-12-28 13:15:19 -05:00
David Cole 4d3a387ac6 Preserve environment variables across calls to cmCTestScriptHandler::RunConfigurationScript. This will help prevent problems like we are currently experiencing (regarding CMake continuous dashboards only running once each day because the HOME environment variable is modified indirectly by a command in a called script, but affects the environment in the calling script). 2009-12-23 14:34:46 -05:00
Zach Mullen 3cb2a0ffa6 Move cURL dependent code out of CMakeLib to fix complex tests. 2009-12-22 14:37:06 -05:00
Zach Mullen 766ef1d011 Fix broken bootstrap test 2009-12-22 09:03:18 -05:00
Zach Mullen 5aad7bf2d4 Make new web api safe for bootstrap build. 2009-12-21 16:42:32 -05:00
Zach Mullen 3ff0b94055 Added functionality to allow CTest to easily access web APIs. This will be used for better communication with CDash. 2009-12-21 15:19:57 -05:00
Zach Mullen 7af553188e Added support for CTest awareness of the CDash version. This will help forward compatibility for both tools. Note that this changeset effectively makes the default to disable output compression. Now, to enable output compression, the CDASH_CTEST_VERSION must be explicity set to >= 1.6. Automated detection of the CDash version is the next step. 2009-12-21 12:27:04 -05:00
Bill Hoffman 22fb266d06 use different tar format to handle longer file names 2009-11-14 08:48:32 -05:00
Bill Hoffman 28664b96f7 Show the current file when there is a tar error 2009-11-13 16:07:42 -05:00
Bill Hoffman a875845be9 fix warning for borland 2009-11-13 07:39:10 -05:00
Bill Hoffman dc5d1edcfd Fix missing return value. 2009-11-12 10:52:32 -05:00
Bill Hoffman 79b8d61ae9 Fix for working with symlinks in tar files 2009-11-08 19:59:01 -05:00
Bill Hoffman f5fe20dc12 Fix some warnings 2009-11-08 10:34:12 -05:00
Bill Hoffman 7961c8685b go back to running stat and put size check in 2009-11-08 10:19:36 -05:00
Bill Hoffman 34ce92f151 Remove check for now so test passes on linux 2009-11-07 21:08:38 -05:00
Bill Hoffman 03cebb9a7f create a better error message 2009-11-07 20:45:34 -05:00
Bill Hoffman 3d1afdee4a add much better error checking on libarchive calls. 2009-11-07 19:35:35 -05:00
Zach Mullen a9a4814971 Fix compiler error in cmSystemTools.cxx 2009-11-05 16:14:46 -05:00
Bill Hoffman dd09d88065 Add JOM support and clean up some of the tar -E stuff 2009-11-05 15:00:15 -05:00
Zach Mullen 9f105a3f6d Fix style warning in cmsystemtools, cosmetic change to ctest code 2009-11-05 11:37:47 -05:00
Zach Mullen cdbbe00a8b Fix unused param warning resulting from libarchive API change. 2009-11-04 11:36:23 -05:00
Bill Hoffman 5f41fe03ca Fix warnings for unused variables 2009-11-03 16:50:49 -05:00
Bill Hoffman fb51d98562 Switch to using libarchive from libtar for cpack and cmake -E tar
This allows for a built in bzip and zip capability, so external tools
will not be needed for these packagers.  The cmake -E tar xf should be
able to handle all compression types now as well.
2009-10-30 13:10:56 -04:00
David Cole 43d07f6620 Fix more mismatched new[] / delete[] (eliminate invalid auto_ptr use) to correct valgrind reported memory issues. 2009-10-30 10:31:54 -04:00
David Cole ccb0cf1306 Fix warnings in CMake source code. 2009-10-02 15:30:01 -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 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 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
Brad King 57e14a4f97 COMP: Include <malloc.h> for 'free' on QNX 2009-07-13 17:08:38 -04:00
Brad King 724275b266 COMP: Include <stdlib.h> for 'free' 2009-07-13 16:46:53 -04:00
Brad King 3dd6f36d45 ENH: Add cmSystemTools::ParseUnixCommandLine
This method is a C++ wrapper around the KWSys System library function to
parse unix-style command lines.
2009-07-13 16:22:48 -04:00
Brad King b64aadc5b0 ENH: Remove unused cmSystemTools::RemoveEscapes
The RemoveEscapes method is no longer used anywhere.  All uses of it
have been replaced by a real lexer.  We can remove the method.
2009-06-24 15:09:50 -04:00
Bill Hoffman fdff8eb300 ENH: move PutEnv to SystemTools 2009-06-05 12:01:30 -04:00
Bill Hoffman ae95f656f3 ENH: vms fix 2009-04-24 11:44:42 -04:00
Brad King efe07c4e0a COMP: Fix calls to superclass methods for Borland
The superclass of cmSystemTools is cmsys::SystemTools, which should be
referencable by just SystemTools from inside the class.  Borland C++
does not seem to support this, so we use cmSystemTools instead.
2009-04-22 09:11:06 -04:00
Brad King 13e454f8d3 BUG: Avoid infinite loop at directory tree root
The system tools GetParentDirectory method no longer removes the root
path component.  This fixes cmSystemTools::FileExistsInParentDirectories
to not infinitely loop at when GetParentDirectory stops at the root.
2009-04-21 11:37:09 -04:00
Brad King 714d2fc04b ENH: Remove obscure method from KWSys SystemTools
This removes SystemTools::FileExistsInParentDirectories from KWSys since
it is a special-purpose method that is not generally useful.
2009-04-21 11:36:59 -04:00
Brad King 1ed7f381f1 COMP: Fix BOOL to bool conversion warning
The cmSystemTools::RenameFile method returns type bool, but its
implementation on Windows returns the result of an API function that
returns BOOL.  This change avoids the compiler warning.
2009-04-15 11:00:03 -04:00
Brad King d3363beb2f ENH: Move RenameFile to cmSystemTools
This moves the cmGeneratedFileStream::RenameFile method implementation
into cmSystemTools.  It works only within a single filesystem volume,
but is atomic when the operating system permits.
2009-04-15 09:57:57 -04:00
Brad King dc13914cd6 ENH: Create cmXMLSafe to help escapes in XML
This class provides easy syntax to efficiently insert blocks of data
into XML documents with proper escapes.  It replaces the old
cmCTest::MakeXMLSafe and cmSystemTools::MakeXMLSafe methods which
allocated extra memory instead of directly streaming the data.
2009-02-05 16:31:37 -05:00
Bill Hoffman 7f92b77997 BUG: fix crash with cmd.exe shell and cmake in the path 2009-01-20 10:06:39 -05:00
David Cole 306d517e82 COMP: Using the proper type for local variables can eliminate compiler warnings. 2008-11-26 15:41:16 -05:00
David Cole ceaef94ccc ENH: Implement feature request from issue 7885. Allow setting environment variables on a per-test basis for ctest using set_test_properties ENVIRONMENT. 2008-11-26 14:38:43 -05:00
Bill Hoffman 64fc597de2 ENH: add initial support for HAIKU OS from bug# 7425 2008-09-15 17:53:28 -04:00
Bill Hoffman 1629963e7c BUG: fix for 7045, use gcc for .m 2008-08-19 15:55:10 -04:00
Brad King ae60cc235c COMP: Work-around bogus compiler warning. 2008-08-15 09:47:21 -04:00
Brad King 8063dd293e ENH: Inform user when RPATH or RUNPATH is removed 2008-08-14 09:53:26 -04:00
Brad King 485c3faea7 BUG: Update both RPATH and RUNPATH entries
During installation the RPATH and RUNPATH entries of ELF binaries are
edited to match the user specification.  Usually either one entry is
present or both entries refer to the same string literal.  In the case
that they are both present and refer to separate string literals we need
to update both.  I have never seen this case in practice, but we should
do this just in case.
2008-08-14 09:53:21 -04:00
Brad King 2a85f8289f BUG: Remove both RPATH and RUNPATH entries
Removal of the RPATH and RUNPATH from ELF binaries must work when both
entries are present.  Both entries should be removed.  Previously only
one would be removed and the other would be blanked because it pointed
at the same string which was zeroed.  This fixes gentoo bug number
224901.
2008-08-14 09:53:17 -04:00
Brad King cea66664c5 ENH: Added WOW64 key view support to KWSys SystemTools' windows registry API.
- Add an argument to registry read/write/delete methods to specify
    a 32-bit or 64-bit view.
  - Default is the bit-ness of the running program.
  - See issue #7095.
2008-05-27 14:47:00 -04:00
Brad King 757875df91 ENH: Inform user when RPATH is set during installation.
- Original patch from Alex.
  - Modified to print only when RPATH is actually set.
2008-05-27 10:22:03 -04:00
Brad King b9a5dccc8d ENH: Added RPATH methods to cmSystemTools
- RemoveRPath to remove the RPATH from a binary
  - CheckRPath to check for an existing RPATH in a binary
2008-04-14 15:02:34 -04:00
Brad King 9b8404a305 COMP: Fix new cmSystemTools file time methods on Windows. 2008-04-14 12:44:01 -04:00
Brad King 703b8c8225 ENH: Added methods to cmSystemTools to save and restore file modification times. 2008-04-14 11:43:45 -04:00
Bill Hoffman 0a61a70870 BUG: undo change as it breaks preprocess test for some reason?? 2008-04-08 17:37:13 -04:00
Bill Hoffman 5a079b151a BUG: half fix for 6688, expand registry stuff on unix just like it was not found on windows 2008-04-08 16:06:44 -04:00
Bill Hoffman cec897edc4 ENH: half fix for 6688, don't let [ count go negative 2008-04-08 16:05:23 -04:00
Brad King 871d80696b ENH: Update cmSystemTools::ChangeRPath to support replacing rpath values from the middle of the string. 2008-04-08 13:42:30 -04:00
Brad King c408760a8a ENH: Improve error message when installation file(CHRPATH) cannot change the RPATH. 2008-04-07 10:55:52 -04:00
Bill Hoffman cae34d2df3 ENH: try to fix mac symlinks to the executable 2008-03-28 14:29:29 -04:00
Brad King 34a338dcc1 ENH: In cmSystemTools::ChangeRPath check for the RUNPATH if RPATH does not exist. 2008-03-02 16:19:26 -05:00
Brad King d732de4a8a ENH: Cleanup builtin chrpath support
- Move computation of extended build-tree rpath
    to cmComputeLinkInformation
  - Only enable the extended build-tree rpath if
    the target will be installed
  - Generalize the interface of file(CHRPATH)
  - When changing the rpath on installation only
    replace the part generated by CMake because
    the native tools (ex SunCC on Linux) might have
    added their own part to the rpath
2008-03-02 14:35:23 -05:00
Brad King 32ca01bef0 COMP: Fix unused parameter warning when cmSystemTools::ChangeRPath is built without ELF support. 2008-03-01 15:16:49 -05:00
Brad King 26e58b74d1 BUG: Fix cmSystemTools::ChangeRPath to not complain if there is no RPATH entry in the file but the requested new rpath is empty. 2008-03-01 13:17:01 -05:00
Brad King 34c76d4304 ENH: Use builtin chrpath instead of relinking ELF targets
- Add cmSystemTools::ChangeRPath method
  - Add undocumented file(CHRPATH) command
  - When installing use file(CHRPATH) to change the rpath
    instead of relinking
  - Remove CMAKE_CHRPATH lookup from CMakeFindBinUtils
  - Remove CMAKE_USE_CHRPATH option since this should
    always work
2008-03-01 12:51:07 -05:00
Brad King 4c137bad6b ENH: Add ELF file parsing
- Enabled when system provides elf.h
  - Introduce cmELF class to parse ELF files
  - Use in cmSystemTools::GuessLibrarySOName to really get soname
2008-02-27 16:26:35 -05:00
Brad King 782e9f7ffe ENH: Improve linking to third-party shared libraries on soname platforms
- Reduce false positives in cases of unknown soname
  - Make library extension regular expressions match only at end of string
  - When linking to libraries in implicit dirs convert to the -l option
    only if the file name is one that can be found by the linker
    (ex. /usr/lib/libfoo.so.1 should be linked by full path)
  - Add cmSystemTools::GuessLibrarySOName to guess the soname of a
    library based on presence of a symlink
  - In cmComputeLinkInformation try to guess an soname before assuming
    that a third-party library is built without an soname
  - In cmOrderDirectories guess the soname of shared libraries in cases
    it is otherwise unknown
2008-02-21 13:58:41 -05:00
Brad King 386a6ebf25 COMP: Need to return a value from fake MD5 method under bootstrap. 2008-01-25 08:11:04 -05:00
Brad King f1c5b50cb7 COMP: Cannot do MD5 from KWSys during CMake bootstrap. 2008-01-24 16:11:06 -05:00
Brad King 1dec54489a ENH: Add cmSystemTools::ComputeStringMD5 method. 2008-01-24 14:41:18 -05:00
Bill Hoffman b479c6a8a9 ENH: add ability to have manifest files and incremental linking with make and nmake 2008-01-01 15:13:41 -05:00
Brad King 73704ede42 ENH: Enabled color printing of "Scanning dependencies of target ..." message. 2007-12-19 17:15:41 -05:00
Brad King 9f61e2a235 ENH: Centralized and globalized computation of CMake program locations. This eliminates startup paths that failed to produce this information. 2007-12-13 17:56:50 -05:00
Brad King e684c35295 STYLE: Fixed line-too-long. 2007-10-08 10:05:42 -04:00
Brad King 5df777edd7 COMP: Added inadvertantly removed include. 2007-10-08 10:03:37 -04:00
Brad King 71400cad02 COMP: Simplified include file logic. The windows.h header should be included for all compilers on windows. 2007-10-07 16:22:16 -04:00
Ken Martin adffd10cce COMP: fix to compile on VS 8 2007-10-05 15:51:01 -04:00
Brad King 23c6b90080 BUG: Fix call to SetFileTime to set it on the proper file. 2007-10-05 10:03:16 -04:00
Brad King a2b2742543 ENH: During file installation treat the source file as a dependency of the installed file. Install the file only if the destination is older than the source. Set the file times on the installed file to match those of the source file. This should greatly improve the speed of repeated installations because it removes the comparison of file contents. This addresses bug#3349. 2007-10-05 09:46:28 -04:00
Bill Hoffman 887699184a COMP: remove warnings 2007-09-27 14:44:11 -04:00
Bill Hoffman 9c3ffe2474 BUG: fix problem with stdout and stderr not showing up in ms dos shells 2007-09-25 10:57:49 -04:00
Bill Hoffman 150805258a ENH: add new machines 2007-09-24 13:21:25 -04:00
Bill Hoffman c190756e24 ENH: fix warning 2007-09-17 11:17:38 -04:00
Bill Hoffman 66a094a9eb ENH: opps 2007-09-11 12:23:59 -04:00
Bill Hoffman f262298bb0 ENH: fix 2 ctest issues, do not use the build type of ctest to look for config types, do not inherit pipes in child procs for ctest so it can kill them 2007-09-11 11:21:36 -04:00
Alexander Neundorf f13c3eef83 COMP: patch from Mathieu: fix warning about unused variables in bootstrap
mode

Alex
2007-08-14 10:27:34 -04:00
Bill Hoffman c693a23a7d ENH: use gnu tar for cygwin 2007-07-30 22:51:21 -04:00
Alexander Neundorf e69958c3cf BUG: fix bootstrapping, md5sum disabled in bootstrapping mode
Alex
2007-07-16 15:10:40 -04:00
Alexander Neundorf 5bb94ce166 ENH: apply patch from Mathieu, add argument -E md5sum to compute md5sums of
files, compatible to md5sum output

Alex
2007-07-16 10:54:32 -04:00
Brad King 9bfe711ef1 BUG: Fix ExpandListArgument when the string ends in a backslash. 2007-05-17 11:27:46 -04:00
Brad King e01cdf2065 ENH: Added kwsys SystemTools::CreateSymlink and SystemTools::ReadSymlink. 2007-03-12 13:50:28 -04:00
Brad King 91c2b84a92 ENH: Added ConvertToOutputSlashes method to convert slashes with the same policy as ConvertToOutputPath but without escaping. 2007-03-08 11:49:26 -05:00
Brad King d37577d9e0 STYLE: Removing unused methods ConvertToShellPath and EscapeForUnixShell. 2007-03-08 09:48:17 -05:00
Bill Hoffman 5647e6e254 ENH: fix parens in the path with spaces in the path 2007-02-21 21:24:17 -05:00
Brad King d37abb6b5d ENH: Added EscapeWindowsShellArgument and ParseWindowsCommandLine methods to cmSystemTools. 2007-02-01 11:45:37 -05:00
Brad King 0fcccb151f ENH: Changes from Ryan C. Gordon to fix old process execution on BeOS. 2006-12-14 10:03:25 -05:00
Bill Hoffman c2308e796f COMP: fix line length style error 2006-12-05 09:14:32 -05:00
Bill Hoffman 3a32cec969 ENH: merge in changes for beos support 2006-12-04 17:26:41 -05:00
Brad King f91b3c1daa ENH: Add options to build with system utility libraries. Organize inclusion of third party libraries into a single header per library. This addresses bug#3653. 2006-10-19 15:00:10 -04:00
Andy Cedilnik a9c0929d39 COMP: Handle both ansi and non-ansi C 2006-07-26 11:46:22 -04:00
Ken Martin daa37f1163 STYLE: fix line length 2006-05-12 13:53:21 -04:00
Ken Martin d81ebf0c23 ENH: added support for -SP scripts in new processes 2006-04-04 13:04:28 -04:00
Andy Cedilnik b507f8f0d1 ENH: Simplify the test 2006-03-17 16:14:04 -05:00
Andy Cedilnik b20cb78049 ENH: Handle missing unsetenv and add check for environ 2006-03-17 15:46:20 -05:00
Bill Hoffman ca8d1bc99b ENH: make cmake compile 2006-03-17 15:33:21 -05:00
Andy Cedilnik 733a0e787e COMP: Fix windows 2006-03-17 12:31:35 -05:00
Andy Cedilnik 0addc75520 COMP: Handle windows with hack for now 2006-03-17 12:24:37 -05:00
Andy Cedilnik d5631f370b ENH: Add a method to remove environment variables 2006-03-17 11:44:07 -05:00
Andy Cedilnik fe1fda6431 ENH: Use vector of plain strings and add cmake -E command for getting environment 2006-03-17 11:14:14 -05:00
Andy Cedilnik f44fedd3e9 ENH: Add access for all environment variables 2006-03-17 10:58:37 -05:00
Andy Cedilnik f483e48d2a ENH: Cleanup DynamicLoader so that the symbols have more consistent names, start using dynamic loader from kwsys in CMake 2006-03-16 11:01:05 -05:00
Bill Hoffman 89e5fc63fe STYLE: fix line lengths 2006-03-10 13:54:57 -05:00
Andy Cedilnik ff50bb9f77 BUG: Even more VS8 issues 2006-03-01 13:05:57 -05:00
Brad King f2cf7e9197 ENH: Enable capture of output from VCExpress.exe and devenv.exe. 2006-02-15 10:22:55 -05:00
Brad King db0681d2f6 ENH: Adding option to return empty arguments when expanding a list. 2006-02-09 19:03:27 -05:00
Andy Cedilnik e5a8e115bc ENH: Move relative path to kwsys 2006-02-07 10:23:17 -05:00
Andy Cedilnik 1e6bc6e5ee COMP: Remove warnings on HP-UX 2006-01-03 08:39:24 -05:00
Andy Cedilnik 8477aa59e5 ENH: Merge from cpack branch 2006-01-01 23:31:17 -05:00
Andy Cedilnik 6534e66e61 COMP: Fix warning on sun 2005-12-30 16:28:30 -05:00
Andy Cedilnik 00371678d3 COMP: Remove sun warning 2005-12-30 15:32:20 -05:00
Andy Cedilnik bb618a7db5 ENH: Cleanup the file handler stuf so that now any file descriptor type can be used 2005-12-30 14:51:15 -05:00
Andy Cedilnik 7b02221059 COMP: Remove unused variable 2005-12-30 14:31:13 -05:00
Andy Cedilnik 6d0f0e0acb COMP: Fix support for gzip on non-32 bit platforms 2005-12-30 14:22:46 -05:00
Andy Cedilnik 081625c610 COMP: Use mangle names 2005-12-30 12:58:33 -05:00
Andy Cedilnik abe4fd77fc ENH: Make the syntax more line tar 2005-12-29 12:19:13 -05:00
Andy Cedilnik d1180fc4e1 ENH: Add untaring support 2005-12-29 10:43:12 -05:00
Andy Cedilnik 2fcd41323b COMP: Fix complex test and fix bootstrap 2005-12-28 17:02:16 -05:00
Andy Cedilnik 0ef674b906 COMP: Add missing include 2005-12-28 16:53:46 -05:00
Andy Cedilnik 7a49a0ce4a BUG: Return proper values 2005-12-28 16:44:32 -05:00
Andy Cedilnik fdc844ecdb ENH: Add method to create tar 2005-12-28 16:30:55 -05:00
Bill Hoffman 452925649a ENH: add better support for framework linking 2005-12-26 13:14:19 -05:00
Brad King 0df3c162fb BUG: Do not dereference an end iterator. 2005-11-17 15:44:43 -05:00
Brad King 1c96fa4a41 BUG: RunSingleCommand should translate NULL characters in the output to valid text. This should fix the missing-output problem caused by NULL-characters in VS build output. 2005-08-17 17:39:59 -04:00
Brad King bac564356b COMP: Added pragma directives for SGI compilers to avoid useless warnings. 2005-05-03 14:58:13 -04:00
Andy Cedilnik c09f6172a4 ENH: Improve performance by using vector of char instead of string 2005-04-13 16:25:55 -04:00
Brad King e2ec4a1845 ENH: Adding kwsys::SystemTools::FileTimeCompare method to compare file modification times with the highest resolution possible on the file system. 2005-02-17 11:28:13 -05:00
Andy Cedilnik ad5115d00f ENH: Add support for single ' 2005-02-17 10:51:18 -05:00
Brad King 1c663cf41c BUG: Fix to avoid relative path with ..s all the way to the root. 2004-12-09 16:14:46 -05:00
Bill Hoffman ef07a8565e COMP: remove an unused variable warning 2004-10-25 13:40:17 -04:00
Bill Hoffman 626be7884a FIX: go back to not trying to handle spaces in the path for run single command and comment it so that people know to call the right thing 2004-10-25 13:16:05 -04:00
Bill Hoffman 7ed631311c FIX: fix RunSingleCommand to work with spaces in the path, and with an already quoted command 2004-10-25 11:59:50 -04:00
Bill Hoffman 9f98481a65 undo last check in as it breaks borland with spaces some how 2004-10-22 21:03:56 -04:00
Bill Hoffman 040f776885 FIX: fix the problem where a target is a single character and nmake gets confused and add a test for it 2004-10-22 17:00:00 -04:00
Bill Hoffman e9b6e65cbd BUG: if the paths share nothing then just return the remote path with no .. 2004-10-19 13:02:42 -04:00
Bill Hoffman 89d35bc8fb ENH: better comments and variable names 2004-10-18 13:19:43 -04:00
Brad King b4176dcab9 ENH: Added FileTimeCompare method to compare file modification times. Currently the resolution is limited to one second. 2004-10-15 09:23:14 -04:00
Bill Hoffman ef8385744b BUG: allow split string to know if it is separating a path 2004-10-14 11:46:30 -04:00
Bill Hoffman 78e8f12b86 BUG: fix and comment relative path funciton 2004-10-13 11:37:55 -04:00
Andy Cedilnik 3fc7dc5e70 ENH: Move permissions code to kwsys so that copyfile can use it. Fixes Bug #1133 - cmake -E copy file dir sets the wrong permissions on the destination directory 2004-09-29 12:20:52 -04:00
Bill Hoffman 2a1bbabb6b ENH: minor fortran fixes 2004-08-11 16:37:56 -04:00