]> git.ipfire.org Git - thirdparty/lxc.git/commitdiff
cgroups: hide unnecessary symbols
authorChristian Brauner <christian.brauner@ubuntu.com>
Tue, 21 Jul 2020 11:28:08 +0000 (13:28 +0200)
committerChristian Brauner <christian.brauner@ubuntu.com>
Tue, 21 Jul 2020 11:28:08 +0000 (13:28 +0200)
Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
src/lxc/Makefile.am
src/lxc/cgroups/cgroup.h
src/lxc/cgroups/cgroup2_devices.h
src/lxc/cgroups/cgroup_utils.h
src/tests/Makefile.am

index 76902e363ab2ef52aafbcdc174dcf8e7e48f3a36..4ec6c7b8df503b845a575975996371a36d0b66fc 100644 (file)
@@ -333,6 +333,9 @@ lxc_attach_SOURCES = tools/lxc_attach.c \
                     tools/arguments.c tools/arguments.h \
                     af_unix.c af_unix.h \
                     caps.c caps.h \
+                    cgroups/cgroup.c cgroups/cgroup.h \
+                    cgroups/cgroup2_devices.c cgroups/cgroup2_devices.h \
+                    cgroups/cgroup_utils.c cgroups/cgroup_utils.h \
                     commands.c commands.h \
                     commands_utils.c commands_utils.h \
                     conf.c conf.h \
@@ -367,6 +370,9 @@ lxc_autostart_SOURCES = tools/lxc_autostart.c \
                        tools/arguments.c tools/arguments.h \
                        af_unix.c af_unix.h \
                        caps.c caps.h \
+                       cgroups/cgroup.c cgroups/cgroup.h \
+                       cgroups/cgroup2_devices.c cgroups/cgroup2_devices.h \
+                       cgroups/cgroup_utils.c cgroups/cgroup_utils.h \
                        commands.c commands.h \
                        commands_utils.c commands_utils.h \
                        conf.c conf.h \
@@ -400,6 +406,9 @@ lxc_cgroup_SOURCES = tools/lxc_cgroup.c \
                     tools/arguments.c tools/arguments.h \
                     af_unix.c af_unix.h \
                     caps.c caps.h \
+                    cgroups/cgroup.c cgroups/cgroup.h \
+                    cgroups/cgroup2_devices.c cgroups/cgroup2_devices.h \
+                    cgroups/cgroup_utils.c cgroups/cgroup_utils.h \
                     commands.c commands.h \
                     commands_utils.c commands_utils.h \
                     conf.c conf.h \
@@ -433,6 +442,9 @@ lxc_config_SOURCES = tools/lxc_config.c \
                     tools/arguments.c tools/arguments.h \
                     af_unix.c af_unix.h \
                     caps.c caps.h \
+                    cgroups/cgroup.c cgroups/cgroup.h \
+                    cgroups/cgroup2_devices.c cgroups/cgroup2_devices.h \
+                    cgroups/cgroup_utils.c cgroups/cgroup_utils.h \
                     commands.c commands.h \
                     commands_utils.c commands_utils.h \
                     conf.c conf.h \
@@ -466,6 +478,9 @@ lxc_console_SOURCES = tools/lxc_console.c \
                      tools/arguments.c tools/arguments.h \
                      af_unix.c af_unix.h \
                      caps.c caps.h \
+                     cgroups/cgroup.c cgroups/cgroup.h \
+                     cgroups/cgroup2_devices.c cgroups/cgroup2_devices.h \
+                     cgroups/cgroup_utils.c cgroups/cgroup_utils.h \
                      commands.c commands.h \
                      commands_utils.c commands_utils.h \
                      conf.c conf.h \
@@ -499,6 +514,9 @@ lxc_destroy_SOURCES = tools/lxc_destroy.c \
                      tools/arguments.c tools/arguments.h \
                      af_unix.c af_unix.h \
                      caps.c caps.h \
+                     cgroups/cgroup.c cgroups/cgroup.h \
+                     cgroups/cgroup2_devices.c cgroups/cgroup2_devices.h \
+                     cgroups/cgroup_utils.c cgroups/cgroup_utils.h \
                      commands.c commands.h \
                      commands_utils.c commands_utils.h \
                      conf.c conf.h \
@@ -532,6 +550,9 @@ lxc_device_SOURCES = tools/lxc_device.c \
                     tools/arguments.c tools/arguments.h \
                     af_unix.c af_unix.h \
                     caps.c caps.h \
+                    cgroups/cgroup.c cgroups/cgroup.h \
+                    cgroups/cgroup2_devices.c cgroups/cgroup2_devices.h \
+                    cgroups/cgroup_utils.c cgroups/cgroup_utils.h \
                     commands.c commands.h \
                     commands_utils.c commands_utils.h \
                     conf.c conf.h \
@@ -565,6 +586,9 @@ lxc_execute_SOURCES = tools/lxc_execute.c \
                      tools/arguments.c tools/arguments.h \
                      af_unix.c af_unix.h \
                      caps.c caps.h \
+                     cgroups/cgroup.c cgroups/cgroup.h \
+                     cgroups/cgroup2_devices.c cgroups/cgroup2_devices.h \
+                     cgroups/cgroup_utils.c cgroups/cgroup_utils.h \
                      commands.c commands.h \
                      commands_utils.c commands_utils.h \
                      conf.c conf.h \
@@ -598,6 +622,9 @@ lxc_freeze_SOURCES = tools/lxc_freeze.c \
                     tools/arguments.c tools/arguments.h \
                     af_unix.c af_unix.h \
                     caps.c caps.h \
+                    cgroups/cgroup.c cgroups/cgroup.h \
+                    cgroups/cgroup2_devices.c cgroups/cgroup2_devices.h \
+                    cgroups/cgroup_utils.c cgroups/cgroup_utils.h \
                     commands.c commands.h \
                     commands_utils.c commands_utils.h \
                     conf.c conf.h \
@@ -631,6 +658,9 @@ lxc_info_SOURCES = tools/lxc_info.c \
                   tools/arguments.c tools/arguments.h \
                   af_unix.c af_unix.h \
                   caps.c caps.h \
+                  cgroups/cgroup.c cgroups/cgroup.h \
+                  cgroups/cgroup2_devices.c cgroups/cgroup2_devices.h \
+                  cgroups/cgroup_utils.c cgroups/cgroup_utils.h \
                   commands.c commands.h \
                   commands_utils.c commands_utils.h \
                   conf.c conf.h \
@@ -664,6 +694,9 @@ lxc_monitor_SOURCES = tools/lxc_monitor.c \
                      tools/arguments.c tools/arguments.h \
                      af_unix.c af_unix.h \
                      caps.c caps.h \
+                     cgroups/cgroup.c cgroups/cgroup.h \
+                     cgroups/cgroup2_devices.c cgroups/cgroup2_devices.h \
+                     cgroups/cgroup_utils.c cgroups/cgroup_utils.h \
                      commands.c commands.h \
                      commands_utils.c commands_utils.h \
                      conf.c conf.h \
@@ -698,6 +731,9 @@ lxc_ls_SOURCES = tools/lxc_ls.c \
                 tools/arguments.c tools/arguments.h \
                 af_unix.c af_unix.h \
                 caps.c caps.h \
+                cgroups/cgroup.c cgroups/cgroup.h \
+                cgroups/cgroup2_devices.c cgroups/cgroup2_devices.h \
+                cgroups/cgroup_utils.c cgroups/cgroup_utils.h \
                 commands.c commands.h \
                 commands_utils.c commands_utils.h \
                 conf.c conf.h \
@@ -732,6 +768,9 @@ lxc_copy_SOURCES = tools/lxc_copy.c \
                   tools/arguments.c tools/arguments.h \
                   af_unix.c af_unix.h \
                   caps.c caps.h \
+                  cgroups/cgroup.c cgroups/cgroup.h \
+                  cgroups/cgroup2_devices.c cgroups/cgroup2_devices.h \
+                  cgroups/cgroup_utils.c cgroups/cgroup_utils.h \
                   commands.c commands.h \
                   commands_utils.c commands_utils.h \
                   conf.c conf.h \
@@ -766,6 +805,9 @@ lxc_start_SOURCES = tools/lxc_start.c \
                    tools/arguments.c tools/arguments.h \
                    af_unix.c af_unix.h \
                    caps.c caps.h \
+                   cgroups/cgroup.c cgroups/cgroup.h \
+                   cgroups/cgroup2_devices.c cgroups/cgroup2_devices.h \
+                   cgroups/cgroup_utils.c cgroups/cgroup_utils.h \
                    commands.c commands.h \
                    commands_utils.c commands_utils.h \
                    conf.c conf.h \
@@ -799,6 +841,9 @@ lxc_stop_SOURCES = tools/lxc_stop.c \
                   tools/arguments.c tools/arguments.h \
                   af_unix.c af_unix.h \
                   caps.c caps.h \
+                  cgroups/cgroup.c cgroups/cgroup.h \
+                  cgroups/cgroup2_devices.c cgroups/cgroup2_devices.h \
+                  cgroups/cgroup_utils.c cgroups/cgroup_utils.h \
                   commands.c commands.h \
                   commands_utils.c commands_utils.h \
                   conf.c conf.h \
@@ -832,6 +877,9 @@ lxc_top_SOURCES = tools/lxc_top.c \
                  tools/arguments.c tools/arguments.h \
                  af_unix.c af_unix.h \
                  caps.c caps.h \
+                 cgroups/cgroup.c cgroups/cgroup.h \
+                 cgroups/cgroup2_devices.c cgroups/cgroup2_devices.h \
+                 cgroups/cgroup_utils.c cgroups/cgroup_utils.h \
                  commands.c commands.h \
                  commands_utils.c commands_utils.h \
                  conf.c conf.h \
@@ -865,6 +913,9 @@ lxc_unfreeze_SOURCES = tools/lxc_unfreeze.c \
                       tools/arguments.c tools/arguments.h \
                       af_unix.c af_unix.h \
                       caps.c caps.h \
+                      cgroups/cgroup.c cgroups/cgroup.h \
+                      cgroups/cgroup2_devices.c cgroups/cgroup2_devices.h \
+                      cgroups/cgroup_utils.c cgroups/cgroup_utils.h \
                       commands.c commands.h \
                       commands_utils.c commands_utils.h \
                       conf.c conf.h \
@@ -898,6 +949,9 @@ lxc_unshare_SOURCES = tools/lxc_unshare.c \
                      tools/arguments.c tools/arguments.h \
                      af_unix.c af_unix.h \
                      caps.c caps.h \
+                     cgroups/cgroup.c cgroups/cgroup.h \
+                     cgroups/cgroup2_devices.c cgroups/cgroup2_devices.h \
+                     cgroups/cgroup_utils.c cgroups/cgroup_utils.h \
                      commands.c commands.h \
                      commands_utils.c commands_utils.h \
                      conf.c conf.h \
@@ -933,6 +987,9 @@ lxc_wait_SOURCES = tools/lxc_wait.c \
                   tools/arguments.c tools/arguments.h \
                   af_unix.c af_unix.h \
                   caps.c caps.h \
+                  cgroups/cgroup.c cgroups/cgroup.h \
+                  cgroups/cgroup2_devices.c cgroups/cgroup2_devices.h \
+                  cgroups/cgroup_utils.c cgroups/cgroup_utils.h \
                   commands.c commands.h \
                   commands_utils.c commands_utils.h \
                   conf.c conf.h \
@@ -966,6 +1023,9 @@ lxc_create_SOURCES = tools/lxc_create.c \
                     tools/arguments.c tools/arguments.h \
                     af_unix.c af_unix.h \
                     caps.c caps.h \
+                    cgroups/cgroup.c cgroups/cgroup.h \
+                    cgroups/cgroup2_devices.c cgroups/cgroup2_devices.h \
+                    cgroups/cgroup_utils.c cgroups/cgroup_utils.h \
                     commands.c commands.h \
                     commands_utils.c commands_utils.h \
                     conf.c conf.h \
@@ -1000,6 +1060,9 @@ lxc_snapshot_SOURCES = tools/lxc_snapshot.c \
                       tools/arguments.c tools/arguments.h \
                       af_unix.c af_unix.h \
                       caps.c caps.h \
+                      cgroups/cgroup.c cgroups/cgroup.h \
+                      cgroups/cgroup2_devices.c cgroups/cgroup2_devices.h \
+                      cgroups/cgroup_utils.c cgroups/cgroup_utils.h \
                       commands.c commands.h \
                       commands_utils.c commands_utils.h \
                       conf.c conf.h \
@@ -1033,6 +1096,9 @@ lxc_checkpoint_SOURCES = tools/lxc_checkpoint.c \
                         tools/arguments.c tools/arguments.h \
                         af_unix.c af_unix.h \
                         caps.c caps.h \
+                        cgroups/cgroup.c cgroups/cgroup.h \
+                        cgroups/cgroup2_devices.c cgroups/cgroup2_devices.h \
+                        cgroups/cgroup_utils.c cgroups/cgroup_utils.h \
                         commands.c commands.h \
                         commands_utils.c commands_utils.h \
                         conf.c conf.h \
@@ -1088,6 +1154,9 @@ init_lxc_LDFLAGS = -pthread
 lxc_monitord_SOURCES = cmd/lxc_monitord.c \
                       af_unix.c af_unix.h \
                       caps.c caps.h \
+                      cgroups/cgroup.c cgroups/cgroup.h \
+                      cgroups/cgroup2_devices.c cgroups/cgroup2_devices.h \
+                      cgroups/cgroup_utils.c cgroups/cgroup_utils.h \
                       commands.c commands.h \
                       commands_utils.c commands_utils.h \
                       conf.c conf.h \
@@ -1122,6 +1191,9 @@ lxc_user_nic_SOURCES = cmd/lxc_user_nic.c \
                       ../include/netns_ifaddrs.c ../include/netns_ifaddrs.h \
                       af_unix.c af_unix.h \
                       caps.c caps.h \
+                      cgroups/cgroup.c cgroups/cgroup.h \
+                      cgroups/cgroup2_devices.c cgroups/cgroup2_devices.h \
+                      cgroups/cgroup_utils.c cgroups/cgroup_utils.h \
                       commands.c commands.h \
                       commands_utils.c commands_utils.h \
                       conf.c conf.h \
@@ -1157,6 +1229,9 @@ endif
 lxc_usernsexec_SOURCES = cmd/lxc_usernsexec.c \
                         af_unix.c af_unix.h \
                         caps.c caps.h \
+                        cgroups/cgroup.c cgroups/cgroup.h \
+                        cgroups/cgroup2_devices.c cgroups/cgroup2_devices.h \
+                        cgroups/cgroup_utils.c cgroups/cgroup_utils.h \
                         commands.c commands.h \
                         commands_utils.c commands_utils.h \
                         conf.c conf.h \
index e3712b710e499df7a7af7d61e8c3fc0bd9ccdca4..7dec05a5c2506065b0626674200deb2bd4214c91 100644 (file)
@@ -7,6 +7,7 @@
 #include <stddef.h>
 #include <sys/types.h>
 
+#include "compiler.h"
 #include "macro.h"
 #include "memory_utils.h"
 
@@ -179,15 +180,15 @@ struct cgroup_ops {
        const char *(*get_limiting_cgroup)(struct cgroup_ops *ops, const char *controller);
 };
 
-extern struct cgroup_ops *cgroup_init(struct lxc_conf *conf);
+__hidden extern struct cgroup_ops *cgroup_init(struct lxc_conf *conf);
 
-extern void cgroup_exit(struct cgroup_ops *ops);
+__hidden extern void cgroup_exit(struct cgroup_ops *ops);
 define_cleanup_function(struct cgroup_ops *, cgroup_exit);
 
-extern void prune_init_scope(char *cg);
+__hidden extern void prune_init_scope(char *cg);
 
-extern int cgroup_attach(const struct lxc_conf *conf, const char *name,
-                        const char *lxcpath, pid_t pid);
+__hidden extern int cgroup_attach(const struct lxc_conf *conf, const char *name,
+                                 const char *lxcpath, pid_t pid);
 
 static inline bool pure_unified_layout(const struct cgroup_ops *ops)
 {
@@ -202,4 +203,4 @@ static inline int cgroup_unified_fd(const struct cgroup_ops *ops)
        return ops->unified->cgfd_con;
 }
 
-#endif
+#endif /* __LXC_CGROUP_H */
index 5c848d81e5781ebbd6cece5b335842842b45397b..83d2fd3cc1babbff1449335e48d12d5e84684af7 100644 (file)
@@ -15,6 +15,7 @@
 #include <sys/types.h>
 #include <unistd.h>
 
+#include "compiler.h"
 #include "conf.h"
 #include "config.h"
 #include "syscall_numbers.h"
@@ -52,17 +53,17 @@ struct bpf_program {
 };
 
 #ifdef HAVE_STRUCT_BPF_CGROUP_DEV_CTX
-struct bpf_program *bpf_program_new(uint32_t prog_type);
-int bpf_program_init(struct bpf_program *prog);
-int bpf_program_append_device(struct bpf_program *prog,
-                             struct device_item *device);
-int bpf_program_finalize(struct bpf_program *prog);
-int bpf_program_cgroup_attach(struct bpf_program *prog, int type,
-                             const char *path, uint32_t flags);
-int bpf_program_cgroup_detach(struct bpf_program *prog);
-void bpf_program_free(struct bpf_program *prog);
-void lxc_clear_cgroup2_devices(struct lxc_conf *conf);
-bool bpf_devices_cgroup_supported(void);
+__hidden extern struct bpf_program *bpf_program_new(uint32_t prog_type);
+__hidden extern int bpf_program_init(struct bpf_program *prog);
+__hidden extern int bpf_program_append_device(struct bpf_program *prog, struct device_item *device);
+__hidden extern int bpf_program_finalize(struct bpf_program *prog);
+__hidden extern int bpf_program_cgroup_attach(struct bpf_program *prog, int type, const char *path,
+                                             uint32_t flags);
+__hidden extern int bpf_program_cgroup_detach(struct bpf_program *prog);
+__hidden extern void bpf_program_free(struct bpf_program *prog);
+__hidden extern void lxc_clear_cgroup2_devices(struct lxc_conf *conf);
+__hidden extern bool bpf_devices_cgroup_supported(void);
+
 static inline void __auto_bpf_program_free__(struct bpf_program **prog)
 {
        if (*prog) {
@@ -70,8 +71,11 @@ static inline void __auto_bpf_program_free__(struct bpf_program **prog)
                *prog = NULL;
        }
 }
-int bpf_list_add_device(struct lxc_conf *conf, struct device_item *device);
+
+__hidden extern int bpf_list_add_device(struct lxc_conf *conf, struct device_item *device);
+
 #else /* !HAVE_STRUCT_BPF_CGROUP_DEV_CTX */
+
 static inline struct bpf_program *bpf_program_new(uint32_t prog_type)
 {
        errno = ENOSYS;
index 5e7c582b0ed4d27604dd105f0f77199fbf037165..17d7b2ffee0fcec240db5b4d48e33697779043b7 100644 (file)
@@ -6,26 +6,28 @@
 #include <stdbool.h>
 #include <stdio.h>
 
+#include "compiler.h"
+
 /* Retrieve the cgroup version of a given entry from /proc/<pid>/mountinfo. */
-extern int get_cgroup_version(char *line);
+__hidden extern int get_cgroup_version(char *line);
 
 /* Check if given entry from /proc/<pid>/mountinfo is a cgroupfs v1 mount. */
-extern bool is_cgroupfs_v1(char *line);
+__hidden extern bool is_cgroupfs_v1(char *line);
 
 /* Check if given entry from /proc/<pid>/mountinfo is a cgroupfs v2 mount. */
-extern bool is_cgroupfs_v2(char *line);
+__hidden extern bool is_cgroupfs_v2(char *line);
 
 /* Given a v1 hierarchy @mountpoint and base @path, verify that we can create
  * directories underneath it.
  */
-extern bool test_writeable_v1(char *mountpoint, char *path);
+__hidden extern bool test_writeable_v1(char *mountpoint, char *path);
 
 /* Given a v2 hierarchy @mountpoint and base @path, verify that we can create
  * directories underneath it and that we have write access to the cgroup's
  * "cgroup.procs" file.
  */
-extern bool test_writeable_v2(char *mountpoint, char *path);
+__hidden extern bool test_writeable_v2(char *mountpoint, char *path);
 
-extern int unified_cgroup_hierarchy(void);
+__hidden extern int unified_cgroup_hierarchy(void);
 
 #endif /* __LXC_CGROUP_UTILS_H */
index daced9bb037cbfefecf0ab77673c036dd85061dd..c63799bbdf05af1e46cc2c82bf2ace14110a325d 100644 (file)
@@ -10,6 +10,9 @@ LDADD = ../lxc/liblxc.la \
 lxc_test_api_reboot_SOURCES = api_reboot.c \
                              ../lxc/af_unix.c ../lxc/af_unix.h \
                              ../lxc/caps.c ../lxc/caps.h \
+                             ../lxc/cgroups/cgroup.c ../lxc/cgroups/cgroup.h \
+                             ../lxc/cgroups/cgroup2_devices.c ../lxc/cgroups/cgroup2_devices.h \
+                             ../lxc/cgroups/cgroup_utils.c ../lxc/cgroups/cgroup_utils.h \
                              ../lxc/commands.c ../lxc/commands.h \
                              ../lxc/commands_utils.c ../lxc/commands_utils.h \
                              ../lxc/conf.c ../lxc/conf.h \
@@ -42,6 +45,9 @@ endif
 lxc_test_apparmor_SOURCES = aa.c \
                            ../lxc/af_unix.c ../lxc/af_unix.h \
                            ../lxc/caps.c ../lxc/caps.h \
+                           ../lxc/cgroups/cgroup.c ../lxc/cgroups/cgroup.h \
+                           ../lxc/cgroups/cgroup2_devices.c ../lxc/cgroups/cgroup2_devices.h \
+                           ../lxc/cgroups/cgroup_utils.c ../lxc/cgroups/cgroup_utils.h \
                            ../lxc/commands.c ../lxc/commands.h \
                            ../lxc/commands_utils.c ../lxc/commands_utils.h \
                            ../lxc/conf.c ../lxc/conf.h \
@@ -74,6 +80,9 @@ endif
 lxc_test_attach_SOURCES = attach.c \
                          ../lxc/af_unix.c ../lxc/af_unix.h \
                          ../lxc/caps.c ../lxc/caps.h \
+                         ../lxc/cgroups/cgroup.c ../lxc/cgroups/cgroup.h \
+                         ../lxc/cgroups/cgroup2_devices.c ../lxc/cgroups/cgroup2_devices.h \
+                         ../lxc/cgroups/cgroup_utils.c ../lxc/cgroups/cgroup_utils.h \
                          ../lxc/commands.c ../lxc/commands.h \
                          ../lxc/commands_utils.c ../lxc/commands_utils.h \
                          ../lxc/conf.c ../lxc/conf.h \
@@ -107,6 +116,9 @@ lxc_test_basic_SOURCES = basic.c
 lxc_test_cgpath_SOURCES = cgpath.c \
                          ../lxc/af_unix.c ../lxc/af_unix.h \
                          ../lxc/caps.c ../lxc/caps.h \
+                         ../lxc/cgroups/cgroup.c ../lxc/cgroups/cgroup.h \
+                         ../lxc/cgroups/cgroup2_devices.c ../lxc/cgroups/cgroup2_devices.h \
+                         ../lxc/cgroups/cgroup_utils.c ../lxc/cgroups/cgroup_utils.h \
                          ../lxc/commands.c ../lxc/commands.h \
                          ../lxc/commands_utils.c ../lxc/commands_utils.h \
                          ../lxc/conf.c ../lxc/conf.h \
@@ -142,6 +154,9 @@ lxc_test_config_jump_table_SOURCES = config_jump_table.c \
                                     lxctest.h \
                                     ../lxc/af_unix.c ../lxc/af_unix.h \
                                     ../lxc/caps.c ../lxc/caps.h \
+                                    ../lxc/cgroups/cgroup.c ../lxc/cgroups/cgroup.h \
+                                    ../lxc/cgroups/cgroup2_devices.c ../lxc/cgroups/cgroup2_devices.h \
+                                    ../lxc/cgroups/cgroup_utils.c ../lxc/cgroups/cgroup_utils.h \
                                     ../lxc/commands.c ../lxc/commands.h \
                                     ../lxc/commands_utils.c ../lxc/commands_utils.h \
                                     ../lxc/conf.c ../lxc/conf.h \
@@ -185,6 +200,9 @@ lxc_test_list_SOURCES = list.c
 lxc_test_locktests_SOURCES = locktests.c \
                             ../lxc/af_unix.c ../lxc/af_unix.h \
                             ../lxc/caps.c ../lxc/caps.h \
+                            ../lxc/cgroups/cgroup.c ../lxc/cgroups/cgroup.h \
+                            ../lxc/cgroups/cgroup2_devices.c ../lxc/cgroups/cgroup2_devices.h \
+                            ../lxc/cgroups/cgroup_utils.c ../lxc/cgroups/cgroup_utils.h \
                             ../lxc/commands.c ../lxc/commands.h \
                             ../lxc/commands_utils.c ../lxc/commands_utils.h \
                             ../lxc/conf.c ../lxc/conf.h \
@@ -220,6 +238,9 @@ lxc_test_mount_injection_SOURCES = mount_injection.c \
                                   lxctest.h \
                                   ../lxc/af_unix.c ../lxc/af_unix.h \
                                   ../lxc/caps.c ../lxc/caps.h \
+                                  ../lxc/cgroups/cgroup.c ../lxc/cgroups/cgroup.h \
+                                  ../lxc/cgroups/cgroup2_devices.c ../lxc/cgroups/cgroup2_devices.h \
+                                  ../lxc/cgroups/cgroup_utils.c ../lxc/cgroups/cgroup_utils.h \
                                   ../lxc/commands.c ../lxc/commands.h \
                                   ../lxc/commands_utils.c ../lxc/commands_utils.h \
                                   ../lxc/conf.c ../lxc/conf.h \
@@ -253,6 +274,9 @@ lxc_test_parse_config_file_SOURCES = parse_config_file.c \
                                     lxctest.h \
                                     ../lxc/af_unix.c ../lxc/af_unix.h \
                                     ../lxc/caps.c ../lxc/caps.h \
+                                    ../lxc/cgroups/cgroup.c ../lxc/cgroups/cgroup.h \
+                                    ../lxc/cgroups/cgroup2_devices.c ../lxc/cgroups/cgroup2_devices.h \
+                                    ../lxc/cgroups/cgroup_utils.c ../lxc/cgroups/cgroup_utils.h \
                                     ../lxc/commands.c ../lxc/commands.h \
                                     ../lxc/commands_utils.c ../lxc/commands_utils.h \
                                     ../lxc/conf.c ../lxc/conf.h \
@@ -285,6 +309,9 @@ endif
 lxc_test_raw_clone_SOURCES = lxc_raw_clone.c \
                             lxctest.h \
                             ../lxc/caps.c ../lxc/caps.h \
+                            ../lxc/cgroups/cgroup.c ../lxc/cgroups/cgroup.h \
+                            ../lxc/cgroups/cgroup2_devices.c ../lxc/cgroups/cgroup2_devices.h \
+                            ../lxc/cgroups/cgroup_utils.c ../lxc/cgroups/cgroup_utils.h \
                             ../lxc/file_utils.c ../lxc/file_utils.h \
                             ../lxc/log.c ../lxc/log.h \
                             ../lxc/namespace.c ../lxc/namespace.h \
@@ -309,6 +336,9 @@ lxc_test_utils_SOURCES = lxc-test-utils.c \
                         lxctest.h \
                          ../lxc/af_unix.c ../lxc/af_unix.h \
                          ../lxc/caps.c ../lxc/caps.h \
+                         ../lxc/cgroups/cgroup.c ../lxc/cgroups/cgroup.h \
+                         ../lxc/cgroups/cgroup2_devices.c ../lxc/cgroups/cgroup2_devices.h \
+                         ../lxc/cgroups/cgroup_utils.c ../lxc/cgroups/cgroup_utils.h \
                          ../lxc/commands.c ../lxc/commands.h \
                          ../lxc/commands_utils.c ../lxc/commands_utils.h \
                          ../lxc/conf.c ../lxc/conf.h \