summaryrefslogtreecommitdiffstats
path: root/Source/cmcmd.cxx
Commit message (Collapse)AuthorAgeFilesLines
* cmAlgorithms: Add cmWrap.Stephen Kelly2015-02-201-3/+1
| | | | | | | | | | | | | Port some existing cmJoin to use it. cmJoin is cumbersome to use in cases where the objective is to somehow 'quote' each item and then join it with a separator. In that case, the joiner string is harder to read and reason about. cmWrap aims to solve that. Provide an overload taking char wrappers to simplify the case of surrounding every element in quotes without needing to escape the quote character.
* Use cmJoin where possible.Stephen Kelly2015-02-201-21/+3
|
* cmcmd: Remove some comment copy-pasta.Stephen Kelly2015-02-171-4/+0
|
* Convert loops to cmJoin algorithm with cmRange.Stephen Kelly2015-02-111-13/+2
|
* Makefile: Fix output during parallel builds (#12991)Brad King2015-02-061-42/+75
| | | | | | | | | | Replace use of separate "cmake -E cmake_progress_report" and "cmake -E cmake_echo_color" commands to report the progress and message portions of build output lines with --progress-* options to the latter to print everything with a single command. The line buffering of the stdout FILE stream should cause the whole line to be printed with one atomic write. This will avoid inter-mixing of line-wise messages from different processes during a parallel build.
* bootstrap: Enable color Makefile outputBrad King2015-02-051-9/+2
| | | | | | Build the needed infrastructure during bootstrap in order to allow "cmake -E cmake_echo_color" to be used unconditionally during generation.
* cmake: Teach "-E tar" command a "--files-from=" optionBrad King2015-01-261-0/+53
| | | | | | Read file names from the lines of a specified file. Reject input lines starting in '-' to leave room for option parsing to be added later. Add just '--add-file=' now to allow files starting in '-' to be specified.
* cmake: Teach "-E tar" command a "--mtime=" optionBrad King2015-01-191-2/+24
| | | | | | | | | | Add an option to set the mtime of entries in a tarball so that one can create a tarball with a consistent content hash (e.g. MD5) for a given set of files regardless of their current timestamps on disk. This will be useful for submission of tarballs to CDash, which tracks content hashes to avoid duplication. Inspired-by: Bill Hoffman <bill.hoffman@kitware.com>
* Replace 'foo.size() == 0' pattern with foo.empty().Stephen Kelly2015-01-181-1/+1
|
* Merge topic 'add-xz-support'Brad King2015-01-121-8/+22
|\ | | | | | | | | | | | | | | 4035ef78 cmake -E tar: error out on multiple compression formats d811d238 cmSystemTools: use an enumeration for compression formats df16dcfb cmake -E tar: add support for .xz files with 'J' b0a5d393 cmake -E tar: clean up flag documentation
| * cmake -E tar: error out on multiple compression formatsBen Boeckel2015-01-121-0/+10
| |
| * cmSystemTools: use an enumeration for compression formatsBen Boeckel2015-01-121-9/+8
| | | | | | | | Juggling 3 booleans was unwieldy.
| * cmake -E tar: add support for .xz files with 'J'Ben Boeckel2015-01-091-2/+7
| |
| * cmake -E tar: clean up flag documentationBen Boeckel2015-01-081-1/+1
| |
* | Port all cmOStringStream to std::ostringstream.Stephen Kelly2015-01-111-1/+1
| | | | | | | | All compilers hosting CMake support the std class.
* | cmcmd: fix copy/paste typo in '-E tar t' commandBen Boeckel2015-01-051-1/+1
|/
* Remove some unneeded c_str calls.Stephen Kelly2014-11-231-3/+3
|
* strings: Remove redundant calls to std::string::c_str()Nils Gladitz2014-10-151-20/+20
| | | | | Replacements were detected and performed by the clang tool remove-cstr-calls on a linux build.
* cmake: Add '-E env' command-line toolBrad King2014-06-231-0/+51
| | | | | | | | | | | | | Extend the cmake command-line interface to support cmake -E env [--unset=NAME]... [NAME=VALUE]... COMMAND [ARG]... This will be useful to run processes with modified environments without using a shell or a full "cmake -P" script to wrap it. Extend the RunCMake.CommandLine test to cover success and failure cases. Inspired-by: Jonathan Bohren <jbo@jhu.edu>
* Remove c_str calls when using stream APIs.Stephen Kelly2014-03-111-13/+13
| | | | | Use an ad-hoc clang tool for matching the calls which should be ported.
* Remove some c_str() calls.Stephen Kelly2014-03-111-8/+8
| | | | | | Use the clang RemoveCStrCalls tool to automatically migrate the code. This was only run on linux, so does not have any positive or negative effect on other platforms.
* stringapi: Pass configuration names as stringsBen Boeckel2014-03-081-1/+1
|
* strings: Remove cmStdString referencesBen Boeckel2014-03-081-9/+9
| | | | | | | | | | | Casts from std::string -> cmStdString were high on the list of things taking up time. Avoid such implicit casts across function calls by just using std::string everywhere. The comment that the symbol name is too long is no longer relevant since modern debuggers alias the templates anyways and the size is a non-issue since the underlying methods are generated since it's inherited.
* cmake: Add '-E sleep' commandBrad King2014-01-211-0/+28
| | | | Add a cmake command-line interface to provide a cross-platform 'sleep'.
* cmake: Improve '-E create_symlink' edge case handling (#14713)Brad King2014-01-201-15/+17
| | | | | | | | | | | | The logic added by commit ffc0b5e4 (Overwrite the symlink if it already exists, 2007-02-15) does not recognize and remove existing broken links before replacing them. Improve the logic to remove any existing destination file or link (but not directory). On failure, report an error message explaining why the existing path could not be removed or the new one could not be created. Add a RunCMake.CommandLine test to cover 'cmake -E' cases. Start with test cases covering 'cmake -E create_symlink' behavior on UNIX platforms.
* Use cmsys::[io]fstream instead of cmsys_ios::[io]fstream.Clinton Stimpson2014-01-071-8/+9
| | | | | Also use SystemTools::Fopen() instead of fopen(). This is to eventually support utf-8 filenames.
* cmake: Fix mt return value when hosted on posix (#14605)Flynn Marquardt2013-12-021-1/+2
| | | | | | On posix platforms return values are limited to a range from 0 to 255. Cross compiling/linking with MSVC on linux/wine leads to a misinterpretation of the return value 1090650113 of mt.exe.
* cmake: Validate -E cmake_autogen argument count (#14545)Brad King2013-11-051-1/+1
| | | | | | | Do not access an argument index not known to exist. Port the change from commit 9ef66f2b (cmake: Validate -E cmake_automoc argument count, 2013-11-05) to the new location of the code.
* Rename the cmake_automoc command to cmake_autogen.Stephen Kelly2013-10-241-1/+1
| | | | | | There is no need for a "cmake_automoc" backward compatibility command because it is internal, undocumented, and only executed from a matching version of cmake.
* Rename the cmQtAutoGenerator instances to reflect coming features.Stephen Kelly2013-10-241-3/+3
|
* Rename the cmQtAutomoc class to cmQtAutoGenerators.Stephen Kelly2013-10-241-2/+2
| | | | It will be extended to process .ui and .qrc files too.
* cmake: Drop "cmake -E comspec" Win9x helperBrad King2013-10-191-12/+2
| | | | Since we dropped Win9x support there is no need for this helper.
* cmake: Split -E command implementation into separate source fileBrad King2013-10-031-0/+1374
Move the cmake::ExecuteCMakeCommand static method and all the static methods it calls out of the 'cmake' class to a separate 'cmcmd' class. Build the latter as part of the main cmake executable with cmakemain.cxx and not in CMakeLib. Drop unused header includes from "cmake.cxx". By moving this implementation out of cmake.cxx we avoid carrying it around in all the executables that use class 'cmake'. It is needed only for the main "cmake -E" functionality.