about summary refs log tree commit diff
path: root/src/libstore/build.cc
diff options
context:
space:
mode:
authorEelco Dolstra <edolstra@gmail.com>2017-10-12T16·21+0200
committerEelco Dolstra <edolstra@gmail.com>2017-10-12T16·21+0200
commit1dd29d7aebae706f3e90a18bbfae727f2ed03c70 (patch)
tree9b8dc1516d14b4637dfc65a70989c53aa7de36dc /src/libstore/build.cc
parent97307811ee478c30472539a477981d24ec0971de (diff)
Add option to disable the seccomp filter
I needed this to test ACL/xattr removal in
canonicalisePathMetaData(). Might also be useful if you need to build
old Nixpkgs that doesn't have the required patches to remove
setuid/setgid creation.
Diffstat (limited to 'src/libstore/build.cc')
-rw-r--r--src/libstore/build.cc2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/libstore/build.cc b/src/libstore/build.cc
index 3b3cebfb18f1..64cbc19bd96f 100644
--- a/src/libstore/build.cc
+++ b/src/libstore/build.cc
@@ -2351,6 +2351,8 @@ void DerivationGoal::doExportReferencesGraph()
 void setupSeccomp()
 {
 #if __linux__
+    if (!settings.filterSyscalls) return;
+
     scmp_filter_ctx ctx;
 
     if (!(ctx = seccomp_init(SCMP_ACT_ALLOW)))