diff options
author | Kai Nacke <kai.nacke@de.ibm.com> | 2020-05-20 11:10:31 +0200 |
---|---|---|
committer | Kai Nacke <kai@redstar.de> | 2020-08-26 12:44:30 -0400 |
commit | ed07e1fe0ffdb2c1dbff26ff4cf7558e0c419737 (patch) | |
tree | 4dc33ce94c7836464c127827d24e2e8b0f7da048 /llvm/lib/Support/CrashRecoveryContext.cpp | |
parent | 2392ff093af128d5e46ce31e2ffa0b3e17185e32 (diff) | |
download | llvm-ed07e1fe0ffdb2c1dbff26ff4cf7558e0c419737.zip llvm-ed07e1fe0ffdb2c1dbff26ff4cf7558e0c419737.tar.gz llvm-ed07e1fe0ffdb2c1dbff26ff4cf7558e0c419737.tar.bz2 |
[SystemZ/ZOS] Add header file to encapsulate use of <sysexits.h>
The non-standard header file `<sysexits.h>` provides some return values.
`EX_IOERR` is used to as a special value to signal a broken pipe to the clang driver.
On z/OS Unix System Services, this header file does not exists. This patch
- adds a check for `<sysexits.h>`, removing the dependency on `LLVM_ON_UNIX`
- adds a new header file `llvm/Support/ExitCodes`, which either includes
`<sysexits.h>` or defines `EX_IOERR`
- updates the users of `EX_IOERR` to include the new header file
Reviewed By: hubert.reinterpretcast
Differential Revision: https://reviews.llvm.org/D83472
Diffstat (limited to 'llvm/lib/Support/CrashRecoveryContext.cpp')
-rw-r--r-- | llvm/lib/Support/CrashRecoveryContext.cpp | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/llvm/lib/Support/CrashRecoveryContext.cpp b/llvm/lib/Support/CrashRecoveryContext.cpp index ec7d7d6..d4fd821 100644 --- a/llvm/lib/Support/CrashRecoveryContext.cpp +++ b/llvm/lib/Support/CrashRecoveryContext.cpp @@ -9,14 +9,12 @@ #include "llvm/Support/CrashRecoveryContext.h" #include "llvm/Config/llvm-config.h" #include "llvm/Support/ErrorHandling.h" +#include "llvm/Support/ExitCodes.h" #include "llvm/Support/ManagedStatic.h" #include "llvm/Support/Signals.h" #include "llvm/Support/ThreadLocal.h" #include <mutex> #include <setjmp.h> -#if LLVM_ON_UNIX -#include <sysexits.h> // EX_IOERR -#endif using namespace llvm; |