summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorleha-bot <leha-bot@yandex.ru>2024-01-02 18:13:26 (GMT)
committerleha-bot <leha-bot@yandex.ru>2024-01-16 07:41:31 (GMT)
commit3d9d5046467dffe1ba7a22c89c67bf7b6632d9c2 (patch)
tree2291b3e469700f0faf5084ed09cda74bf47d2a6b
parent9f6c937408e7680a6b6bc01e13b4efe8aeca4623 (diff)
downloadCMake-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.cxx5
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.