mirror of
https://github.com/fish-shell/fish-shell
synced 2025-01-26 03:35:17 +00:00
Don't override CTEST_PARALLEL_LEVEL env variable
I think the dynamic detection patch ends up overriding the environment variable set by CI (if present), because `if(NOT CTEST_PARALLEL_LEVEL)` would define to false even if an environment variable of that name existed then we end up explicitly assigning the environment variable by that name upon invocation with `env`.
This commit is contained in:
parent
1f45ab63d1
commit
a4f91a8543
1 changed files with 7 additions and 3 deletions
|
@ -2,10 +2,14 @@
|
|||
enable_testing()
|
||||
|
||||
# By default, ctest runs tests serially
|
||||
# Support CTEST_PARALLEL_LEVEL as an environment variable in addition to a CMake variable
|
||||
if(NOT CTEST_PARALLEL_LEVEL)
|
||||
include(ProcessorCount)
|
||||
ProcessorCount(CORES)
|
||||
set(CTEST_PARALLEL_LEVEL ${CORES})
|
||||
set(CTEST_PARALLEL_LEVEL $ENV{CTEST_PARALLEL_LEVEL})
|
||||
if(NOT CTEST_PARALLEL_LEVEL)
|
||||
include(ProcessorCount)
|
||||
ProcessorCount(CORES)
|
||||
set(CTEST_PARALLEL_LEVEL ${CORES})
|
||||
endif()
|
||||
endif()
|
||||
|
||||
|
||||
|
|
Loading…
Reference in a new issue