Merge pull request #10416 from obsidiansystems/cgroup-linux-only

Make `cgroup.{cc,hh}` linux-only files
This commit is contained in:
Robert Hensing 2024-04-07 16:52:31 +02:00 committed by GitHub
commit 5f9aaa86eb
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 1 additions and 9 deletions

View File

@ -14,7 +14,6 @@
#include "topo-sort.hh"
#include "callback.hh"
#include "json-utils.hh"
#include "cgroup.hh"
#include "personality.hh"
#include "current-process.hh"
#include "child.hh"
@ -52,6 +51,7 @@
# include <seccomp.h>
# endif
# define pivot_root(new_root, put_old) (syscall(SYS_pivot_root, new_root, put_old))
# include "cgroup.hh"
#endif
#if __APPLE__

View File

@ -1,5 +1,3 @@
#if __linux__
#include "cgroup.hh"
#include "util.hh"
#include "file-system.hh"
@ -145,5 +143,3 @@ CgroupStats destroyCgroup(const Path & cgroup)
}
}
#endif

View File

@ -1,8 +1,6 @@
#pragma once
///@file
#if __linux__
#include <chrono>
#include <optional>
@ -28,5 +26,3 @@ struct CgroupStats
CgroupStats destroyCgroup(const Path & cgroup);
}
#endif