aboutsummaryrefslogtreecommitdiff
path: root/src/libstore
diff options
context:
space:
mode:
Diffstat (limited to 'src/libstore')
-rw-r--r--src/libstore/globals.hh8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/libstore/globals.hh b/src/libstore/globals.hh
index dd01f832d..12917a438 100644
--- a/src/libstore/globals.hh
+++ b/src/libstore/globals.hh
@@ -220,7 +220,13 @@ public:
Setting<bool> enableNativeCode{this, false, "allow-unsafe-native-code-during-evaluation",
"Whether builtin functions that allow executing native code should be enabled."};
- Setting<SandboxMode> sandboxMode{this, smDisabled, "sandbox",
+ Setting<SandboxMode> sandboxMode{this,
+ #if __linux__
+ smEnabled
+ #else
+ smDisabled
+ #endif
+ , "sandbox",
"Whether to enable sandboxed builds. Can be \"true\", \"false\" or \"relaxed\".",
{"build-use-chroot", "build-use-sandbox"}};