diff options
Diffstat (limited to 'science/py-tensorflow/files/bazel/fix-environ.patch')
-rw-r--r-- | science/py-tensorflow/files/bazel/fix-environ.patch | 32 |
1 files changed, 16 insertions, 16 deletions
diff --git a/science/py-tensorflow/files/bazel/fix-environ.patch b/science/py-tensorflow/files/bazel/fix-environ.patch index 2e38ce60543d..d1437f158055 100644 --- a/science/py-tensorflow/files/bazel/fix-environ.patch +++ b/science/py-tensorflow/files/bazel/fix-environ.patch @@ -1,18 +1,18 @@ ---- a/llvm/lib/Support/Unix/Program.inc 2022-09-06 21:14:28.808580000 +0100 -+++ b/llvm/lib/Support/Unix/Program.inc 2022-09-06 21:16:15.007790000 +0100 +--- a/llvm/lib/Support/Unix/Program.inc 2023-04-28 21:51:01.000000000 +0200 ++++ b/llvm/lib/Support/Unix/Program.inc 2024-07-02 11:12:41.645169000 +0200 @@ -54,10 +54,8 @@ #define USE_NSGETENVIRON 0 #endif -#if !USE_NSGETENVIRON +#if USE_NSGETENVIRON - extern char **environ; + extern char **environ; -#else -#include <crt_externs.h> // _NSGetEnviron #endif #endif -@@ -240,14 +238,6 @@ +@@ -238,14 +236,6 @@ } } @@ -27,16 +27,16 @@ constexpr int maxRetries = 8; int retries = 0; pid_t PID; -@@ -308,11 +298,7 @@ +@@ -312,11 +302,7 @@ - // Execute! - std::string PathStr = std::string(Program); -- if (Envp != nullptr) -- execve(PathStr.c_str(), const_cast<char **>(Argv), -- const_cast<char **>(Envp)); -- else -- execv(PathStr.c_str(), const_cast<char **>(Argv)); -+ execv(PathStr.c_str(), const_cast<char **>(Argv)); - // If the execve() failed, we should exit. Follow Unix protocol and - // return 127 if the executable was not found, and 126 otherwise. - // Use _exit rather than exit so that atexit functions and static + // Execute! + std::string PathStr = std::string(Program); +- if (Envp != nullptr) +- execve(PathStr.c_str(), const_cast<char **>(Argv), +- const_cast<char **>(Envp)); +- else +- execv(PathStr.c_str(), const_cast<char **>(Argv)); ++ execv(PathStr.c_str(), const_cast<char **>(Argv)); + // If the execve() failed, we should exit. Follow Unix protocol and + // return 127 if the executable was not found, and 126 otherwise. + // Use _exit rather than exit so that atexit functions and static |