20 bdev/storage_utils.h \
44 ../include/ifaddrs.h \
45 ../include/openpty.h \
46 ../include/lxcmntent.h
48 noinst_HEADERS += ../include/prlimit.h
54 noinst_HEADERS += ../include/getline.h
59 noinst_HEADERS += ../include/getsubopt.h
69 LSM_SOURCES += lsm/apparmor.c
73 LSM_SOURCES += lsm/selinux.c
76 lib_LTLIBRARIES = liblxc.la
78 arguments.c arguments.h \
79 bdev/bdev.c bdev/bdev.h \
80 bdev/lxcaufs.c bdev/lxcaufs.h \
81 bdev/lxcbtrfs.c bdev/lxcbtrfs.h \
82 bdev/lxcdir.c bdev/lxcdir.h \
83 bdev/lxcloop.c bdev/lxcloop.h \
84 bdev/lxclvm.c bdev/lxclvm.h \
85 bdev/lxcnbd.c bdev/lxcnbd.h \
86 bdev/lxcoverlay.c bdev/lxcoverlay.h \
87 bdev/lxcrbd.c bdev/lxcrbd.h \
88 bdev/lxcrsync.c bdev/lxcrsync.h \
89 bdev/lxczfs.c bdev/lxczfs.h \
90 bdev/storage_utils.c bdev/storage_utils.h \
93 cgroups/cgroup.c cgroups/cgroup.h \
94 commands.c commands.h \
103 initutils.c initutils.h \
106 namespace.h namespace.c \
108 confile.c confile.h \
109 confile_legacy.c confile_legacy.h \
110 confile_utils.c confile_utils.h \
117 network.c network.h \
124 mainloop.c mainloop.h \
125 af_unix.c af_unix.h \
127 lxcutmp.c lxcutmp.h \
128 lxclock.h lxclock.c \
129 lxccontainer.c lxccontainer.h \
135 liblxc_la_SOURCES += cgroups/cgmanager.c
139 liblxc_la_SOURCES += \
140 ../include/ifaddrs.c ../include/ifaddrs.h \
141 ../include/openpty.c ../include/openpty.h \
142 ../include/lxcmntent.c ../include/lxcmntent.h
144 liblxc_la_SOURCES += ../include/prlimit.c ../include/prlimit.h
150 liblxc_la_SOURCES += ../include/getline.c ../include/getline.h
154 AM_CFLAGS=-DLXCROOTFSMOUNT=\"$(LXCROOTFSMOUNT)\" \
155 -DLXCPATH=\"$(LXCPATH)\" \
156 -DLXC_GLOBAL_CONF=\"$(LXC_GLOBAL_CONF)\" \
157 -DLXCINITDIR=\"$(LXCINITDIR)\" \
158 -DLIBEXECDIR=\"$(LIBEXECDIR)\" \
159 -DLXCTEMPLATEDIR=\"$(LXCTEMPLATEDIR)\" \
160 -DLXCTEMPLATECONFIG=\"$(LXCTEMPLATECONFIG)\" \
161 -DLOGPATH=\"$(LOGPATH)\" \
162 -DLXC_DEFAULT_CONFIG=\"$(LXC_DEFAULT_CONFIG)\" \
163 -DLXC_USERNIC_DB=\"$(LXC_USERNIC_DB)\" \
164 -DLXC_USERNIC_CONF=\"$(LXC_USERNIC_CONF)\" \
165 -DDEFAULT_CGROUP_PATTERN=\"$(DEFAULT_CGROUP_PATTERN)\" \
166 -DRUNTIME_PATH=\"$(RUNTIME_PATH)\" \
167 -DSBINDIR=\"$(SBINDIR)\" \
168 -I $(top_srcdir)/src \
169 -I $(top_srcdir)/src/lxc \
170 -I $(top_srcdir)/src/lxc/bdev \
171 -I $(top_srcdir)/src/lxc/cgroups
174 AM_CFLAGS += -DHAVE_APPARMOR
178 AM_CFLAGS += -DHAVE_CGMANAGER
182 AM_CFLAGS += -DHAVE_SELINUX
185 if USE_CONFIGPATH_LOGS
186 AM_CFLAGS += -DUSE_CONFIGPATH_LOGS
190 AM_CFLAGS += -DHAVE_SECCOMP $(SECCOMP_CFLAGS)
191 liblxc_la_SOURCES += seccomp.c
194 liblxc_la_CFLAGS = -fPIC -DPIC $(AM_CFLAGS) -pthread
196 liblxc_la_LDFLAGS = \
199 -Wl,-soname,liblxc.so.$(firstword $(subst ., ,@LXC_ABI@)) \
200 -version-info @LXC_ABI_MAJOR@
202 liblxc_la_LIBADD = $(CAP_LIBS) $(APPARMOR_LIBS) $(SELINUX_LIBS) $(SECCOMP_LIBS)
205 liblxc_la_LIBADD += $(CGMANAGER_LIBS) $(DBUS_LIBS) $(NIH_LIBS) $(NIH_DBUS_LIBS)
206 liblxc_la_CFLAGS += $(CGMANAGER_CFLAGS) $(DBUS_CFLAGS) $(NIH_CFLAGS) $(NIH_DBUS_CFLAGS)
209 bin_SCRIPTS = tools/lxc-checkconfig
216 bin_SCRIPTS += tools/lxc-start-ephemeral
246 bin_PROGRAMS += lxc-clone
249 sbin_PROGRAMS = init.lxc
250 pkglibexec_PROGRAMS = \
256 AM_LDFLAGS += -Wl,-rpath -Wl,$(libdir)
258 LDADD=liblxc.la @CAP_LIBS@ @APPARMOR_LIBS@ @SELINUX_LIBS@ @SECCOMP_LIBS@
260 lxc_attach_SOURCES = tools/lxc_attach.c
261 lxc_autostart_SOURCES = tools/lxc_autostart.c
262 lxc_cgroup_SOURCES = tools/lxc_cgroup.c
263 lxc_config_SOURCES = tools/lxc_config.c
264 lxc_console_SOURCES = tools/lxc_console.c
265 lxc_destroy_SOURCES = tools/lxc_destroy.c
266 lxc_device_SOURCES = tools/lxc_device.c
267 lxc_execute_SOURCES = tools/lxc_execute.c
268 lxc_freeze_SOURCES = tools/lxc_freeze.c
269 lxc_info_SOURCES = tools/lxc_info.c
270 init_lxc_SOURCES = tools/lxc_init.c
271 lxc_monitor_SOURCES = tools/lxc_monitor.c
272 lxc_ls_SOURCES = tools/lxc_ls.c
273 lxc_copy_SOURCES = tools/lxc_copy.c
274 lxc_start_SOURCES = tools/lxc_start.c
275 lxc_stop_SOURCES = tools/lxc_stop.c
276 lxc_top_SOURCES = tools/lxc_top.c
277 lxc_unfreeze_SOURCES = tools/lxc_unfreeze.c
278 lxc_unshare_SOURCES = tools/lxc_unshare.c
279 lxc_wait_SOURCES = tools/lxc_wait.c
280 lxc_create_SOURCES = tools/lxc_create.c
281 lxc_snapshot_SOURCES = tools/lxc_snapshot.c
282 lxc_usernsexec_SOURCES = tools/lxc_usernsexec.c
283 lxc_checkpoint_SOURCES = tools/lxc_checkpoint.c
284 lxc_user_nic_SOURCES = lxc_user_nic.c network.c network.h
285 lxc_monitord_SOURCES = lxc_monitord.c
288 lxc_clone_SOURCES = tools/lxc_clone.c
292 lxc_copy_SOURCES += ../include/getsubopt.c ../include/getsubopt.h
295 if HAVE_STATIC_LIBCAP
296 sbin_PROGRAMS += init.lxc.static
298 init_lxc_static_SOURCES = tools/lxc_init.c error.c log.c initutils.c caps.c
302 init_lxc_static_SOURCES += ../include/getline.c
306 init_lxc_static_LDFLAGS = -all-static
307 init_lxc_static_LDADD = @CAP_LIBS@
308 init_lxc_static_CFLAGS = $(AM_CFLAGS) -DNO_LXC_CONF
311 install-exec-local: install-libLTLIBRARIES
312 mkdir -p $(DESTDIR)$(datadir)/lxc
313 install -c -m 644 lxc.functions $(DESTDIR)$(datadir)/lxc
314 mv $(shell readlink -f $(DESTDIR)$(libdir)/liblxc.so) $(DESTDIR)$(libdir)/liblxc.so.@LXC_ABI@
315 rm -f $(DESTDIR)$(libdir)/liblxc.so $(DESTDIR)$(libdir)/liblxc.so.1
316 cd $(DESTDIR)$(libdir); \
317 ln -sf liblxc.so.@LXC_ABI@ liblxc.so.$(firstword $(subst ., ,@LXC_ABI@)); \
318 ln -sf liblxc.so.$(firstword $(subst ., ,@LXC_ABI@)) liblxc.so
321 chmod u+s $(DESTDIR)$(libexecdir)/lxc/lxc-user-nic
324 $(RM) $(DESTDIR)$(libdir)/liblxc.so*