| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
| |
* Change some functions to take `std::string` instead of
`const char*` in the following classes: `cmMakeFile`, `cmake`,
`cmCoreTryCompile`, `cmSystemTools`, `cmState`, `cmLocalGenerator`
and a few others.
* Greatly reduce using of `const char*` overloads for
`cmSystemTools::MakeDirectory` and `cmSystemTools::RelativePath`.
* Remove many redundant `c_str()` conversions throughout the code.
|
|\
| |
| |
| |
| |
| |
| |
| | |
13347740 Help: add release notes, documentation for CTEST_RUN_CURRENT_SCRIPT behavior
74092d92 cmCTestScriptHandler: Add new field ShouldRunCurrentScript
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !1703
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
This is to avoid scope issues with CTEST_RUN_CURRENT_SCRIPT. If
ctest_start() is called within a function scope, the value of
CTEST_RUN_CURRENT_SCRIPT that it sets doesn't make it to the global
scope. With this change, ctest_start() no longer sets
CTEST_RUN_CURRENT_SCRIPT, and instead sets a field directly in
cmCTestScriptHandler. The old behavior of CTEST_RUN_CURRENT_SCRIPT
has also been kept for projects and tests that rely on setting it.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
A problem area by recent refactoring of time to std::chrono has been the
unsafe conversion from duration<double> to std::chrono::seconds, which
is of an unspecified integer type.
This commit adds a template function that for a given type provides a
safe conversion, effectively clamping a duration<double> into what fits
safely in that type. A specialisation for int and unsigned int are
provided.
It changes the protential problem areas to use this safe function.
|
|/
|
|
|
|
|
|
| |
This commit introduces cmDuration as a typedef for
std::chrono::duration<double, std::ratio<1>>. It is less verbose and
provides for a point to put future common functionality for durations.
No functional change intended.
|
|
|
|
|
| |
Calculate the stop time up front instead of re-parsing its string for
every test.
|
|
|
|
|
|
|
| |
This member was added by commit v2.8.2~285 (Better detection of
stop_time being passed, 2010-03-19), but its logic has no effect.
The member is only used for comparison against a value to which
it was just assigned.
|
|\
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
ba6caafa CTest: Use integer-representable value for "infinite" timeout
548e8f6f CTest: Simplify std::chrono::duration<double> conversion to double
de0035fd cmCTestBuildAndTestHandler: Convert timeout to std::chrono::duration
687a26b7 CTest: Fix regression in build-and-test timeout forwarding
e770b1b8 CTest: Fix regression in build-and-test timeout compuatation
Acked-by: Kitware Robot <kwrobot@kitware.com>
Acked-by: dublet <github@dublet.org>
Merge-request: !1574
|
| |
| |
| |
| |
| |
| |
| |
| | |
Refactoring in commit 66419bc046 (CTest: convert timeouts to
std::chrono::duration, 2017-11-20) changed out "infinite" timeout to a
value not representable by a 64-bit integer. This causes undefined
behavior when e.g. KWSys Process converts the duration to a `long` to
interact with system APIs. Use the old `1.0e7` maximum value.
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
The ratio of ticks to seconds for this type is 1, so we can just use its
`count()` directly. This also avoids converting through the integer
representation of `std::chrono::milliseconds`, which has a much smaller
allowed range.
Drop our `cmsysProcess_SetTimeout` wrapper as it is now very thin.
|
| |
| |
| |
| |
| |
| |
| |
| | |
Refactoring in commit 66419bc046 (CTest: convert timeouts to
std::chrono::duration, 2017-11-20) changed out "infinite" timeout
to a value not representable by a 64-bit integer. Update the
`--build-and-test` forwarding of `--test-timeout` to not forward
an "infinite" timeout.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Refactoring in commit 66419bc046 (CTest: convert timeouts to
std::chrono::duration, 2017-11-20) accidentally changed the logic used
to compute the timeout for a test when it starts. It incorrectly limits
the maximum possible timeout to 2 minutes rather than 2 minutes less
than the total allowed test time remaining. Update the new logic to
restore the original behavior.
Avoid subtracting 2 minutes from our "infinite" timeout value to avoid
creating very large timeouts that are not "infinite" and may exceed
integer type ranges.
|
|/
|
|
|
| |
This was partially implemented by commit v2.8.0~154 (Added some ctest
batch capabilities, 2009-09-10) but never finished.
|
|
|
|
|
|
|
|
|
| |
This commit continues the refactoring of CTest to adopt std::chrono.
After the last sets of changes that introduced std::chrono::steady_clock
and std::chrono::system_clock respectively, it makes sense to have all
the timeouts be stored as std::chrono::duration.
No functional change intended.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
After the refactor to make CTest use std::chrono::steady_clock for the
keeping of time for test duration, there are still references to
cmSystemTools::GetTime() left.
To further adopt std::chrono for time related activities, this commit
changes those remaining references to std::chrono::system_clock::now()
calls and alters the storage from either unsigned int or double to
std::chrono::system_clock::time_point.
For ease of conversion, a converter method is added to cmXMLWriter that
converts from a std::chrono::system_clock::time_point to the number of
seconds since the UN*X epoch as that is expected behaviour. This means
no more casts as required.
Functionally should be no difference as the system_clock is implemented
in the same terms.
|
|
|
|
| |
The option 'ctest-config' is ignored.
|
|
|
|
|
|
|
|
|
|
| |
Notes.xml was reporting its timestamp in E-notation. Here's an example of
what this looked like:
<Time>1.50938e+09</Time>
This format is unsuitable for precisely determining when the Notes file
was generated. As a result of this commit, the same field now appears as:
<Time>1509383044</Time>
|
|
|
|
|
|
|
| |
Fix issues diagnosed by clang-tidy by pre-allocating the vector capacity
before the loop [performance-inefficient-vector-operation].
Signed-off-by: Matthias Maennich <matthias@maennich.net>
|
|
|
|
| |
Signed-off-by: Matthias Maennich <matthias@maennich.net>
|
| |
|
|\
| |
| |
| |
| |
| |
| | |
5db3aac1 Meta: replace empty-string assignments with `clear()`.
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !1276
|
| | |
|
|/
|
|
|
|
|
| |
The only 2 callers took care to construct a properly escaped string, but not
using the documented way, and that string was passed only to be immediately
split into tokens again. Start with a vector and join it only for logging,
avoiding needless quotes during that.
|
|
|
|
|
|
| |
Changes done via `clang-tidy` with some manual fine-tuning
for the variable naming and `auto` type deduction
where appropriate.
|
|
|
|
|
|
| |
Changes done via `clang-tidy` with some manual fine-tuning
for the variable naming and `auto` type deduction
where appropriate.
|
| |
|
| |
|
|\
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
376dc3eb Help: Add notes for topic 'labels_for_subprojects'
a70d8e93 Add tests for new directory labels and labels-for-subprojects features
47b3a57c Display subproject timing summary
d3859624 Add directory property 'LABELS' and CMAKE_DIRECTORY_LABELS variable
d08ec4d2 Add CTEST_LABELS_FOR_SUBPROJECTS as a CTest module and script variable
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !1004
|
| |
| |
| |
| | |
Use the '--no-subproject-summary' option to disable timing summary.
|
| |
| |
| |
| |
| | |
Use this variable to specify a list of labels that will be reported to
CDash as subprojects.
|
|/
|
|
|
|
| |
Without this, GCC 7 warns.
Reported-by: Rolf Eike Beer <eike@sf-mail.de>
|
| |
|
| |
|
| |
|
|
|
|
|
| |
The new options allow the user to restrict the setup and cleanup tests
automatically added for fixtures.
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Automate with:
git grep -l '#include <cm_' -- Source \
| xargs sed -i 's/#include <\(cm_.*\)>/#include "\1"/g'
git grep -l '#include <cmsys/' -- Source \
| xargs sed -i 's/#include <\(cmsys\/.*\)>/#include "\1"/g'
git grep -l '#include <cm[A-Z]' -- Source \
| xargs sed -i 's/#include <\(cm[A-Z].*\)>/#include "\1"/g'
|
|
|
|
| |
The working directory changes here didn't really accomplish anything.
|
| |
|
| |
|
| |
|
|
|
|
|
|
| |
Typically Windows applications (eg. MSVC compiler) use current console's
codepage for output to pipes so we need to encode that to our
internally-used encoding (`KWSYS_ENCODING_DEFAULT_CODEPAGE`).
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This check was not functioning properly for the following reasons:
* The "DropSite" and "DropLocation" CTest Configurations do not
get set until ctest_submit() is called. So if ctest_submit()
was not called before ctest_test() we would end up with uncompressed
output, even if the CDash server was new enough to support this feature.
* CDash's API is now versioned. The current location to query is
now /api/v1/getversion.php, not /api/getversion.php.
As a result of these issues, CTest would not compress test/memcheck
output when it should. Rather than fix this check, we now assume that
CTest is communicating with a new enough version of CDash. This behavior
can be controlled through the use of the --no-compress-output command-line
argument.
|
| |
|
|
|
|
|
| |
Include it in dependents which have previously relied on it
transitively.
|
| |
|
|
|
|
| |
Port dependent code to the change.
|
|
|
|
|
|
| |
Apply the change from commit bd3d0eaf (cmCTest: don't redefine cout and
cerr, 2016-09-01) to the rest of ctest and cpack. These definitions
are no longer needed because our conventions are well established.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Per-source copyright/license notice headers that spell out copyright holder
names and years are hard to maintain and often out-of-date or plain wrong.
Precise contributor information is already maintained automatically by the
version control tool. Ultimately it is the receiver of a file who is
responsible for determining its licensing status, and per-source notices are
merely a convenience. Therefore it is simpler and more accurate for
each source to have a generic notice of the license name and references to
more detailed information on copyright holders and full license terms.
Our `Copyright.txt` file now contains a list of Contributors whose names
appeared source-level copyright notices. It also references version control
history for more precise information. Therefore we no longer need to spell
out the list of Contributors in each source file notice.
Replace CMake per-source copyright/license notice headers with a short
description of the license and links to `Copyright.txt` and online information
available from "https://cmake.org/licensing". The online URL also handles
cases of modules being copied out of our source into other projects, so we
can drop our notices about replacing links with full license text.
Run the `Utilities/Scripts/filter-notices.bash` script to perform the majority
of the replacements mechanically. Manually fix up shebang lines and trailing
newlines in a few files. Manually update the notices in a few files that the
script does not handle.
|
| |
|
| |
|