diff options
Diffstat (limited to 'pkgs/development/compilers/swift/swiftpm/patches/disable-sandbox.patch')
-rw-r--r-- | pkgs/development/compilers/swift/swiftpm/patches/disable-sandbox.patch | 21 |
1 files changed, 0 insertions, 21 deletions
diff --git a/pkgs/development/compilers/swift/swiftpm/patches/disable-sandbox.patch b/pkgs/development/compilers/swift/swiftpm/patches/disable-sandbox.patch deleted file mode 100644 index 0c76d59f9dfb..000000000000 --- a/pkgs/development/compilers/swift/swiftpm/patches/disable-sandbox.patch +++ /dev/null @@ -1,21 +0,0 @@ -Nix may already sandbox the build, in which case sandbox_apply will fail. - ---- a/Sources/Basics/Sandbox.swift -+++ b/Sources/Basics/Sandbox.swift -@@ -33,12 +33,14 @@ public enum Sandbox { - readOnlyDirectories: [AbsolutePath] = [] - ) throws -> [String] { - #if os(macOS) -+ let env = ProcessInfo.processInfo.environment -+ if env["NIX_BUILD_TOP"] == nil || env["IN_NIX_SHELL"] != nil { - let profile = try macOSSandboxProfile(strictness: strictness, writableDirectories: writableDirectories, readOnlyDirectories: readOnlyDirectories) - return ["/usr/bin/sandbox-exec", "-p", profile] + command -- #else -+ } -+ #endif - // rdar://40235432, rdar://75636874 tracks implementing sandboxes for other platforms. - return command -- #endif - } - - /// Basic strictness level of a sandbox applied to a command line. |