diff options
author | leha-bot <leha-bot@yandex.ru> | 2024-01-02 18:13:26 (GMT) |
---|---|---|
committer | leha-bot <leha-bot@yandex.ru> | 2024-01-16 07:41:31 (GMT) |
commit | 3d9d5046467dffe1ba7a22c89c67bf7b6632d9c2 (patch) | |
tree | 2291b3e469700f0faf5084ed09cda74bf47d2a6b | |
parent | 9f6c937408e7680a6b6bc01e13b4efe8aeca4623 (diff) | |
download | CMake-3d9d5046467dffe1ba7a22c89c67bf7b6632d9c2.zip CMake-3d9d5046467dffe1ba7a22c89c67bf7b6632d9c2.tar.gz CMake-3d9d5046467dffe1ba7a22c89c67bf7b6632d9c2.tar.bz2 |
cmMakefile: Store the exit code from cmExecutionStatus to cmake instance
-rw-r--r-- | Source/cmMakefile.cxx | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/Source/cmMakefile.cxx b/Source/cmMakefile.cxx index 936b282..36bd69b 100644 --- a/Source/cmMakefile.cxx +++ b/Source/cmMakefile.cxx @@ -898,6 +898,11 @@ void cmMakefile::RunListFile(cmListFile const& listFile, if (cmSystemTools::GetFatalErrorOccurred()) { break; } + if (status.HasExitCode()) { + // cmake_language EXIT was requested, early break. + this->GetCMakeInstance()->SetScriptModeExitCode(status.GetExitCode()); + break; + } if (status.GetReturnInvoked()) { this->RaiseScope(status.GetReturnVariables()); // Exit early due to return command. |