]>
Commit | Line | Data |
---|---|---|
0ad19a3f | 1 | pkginclude_HEADERS = \ |
e788178a | 2 | arguments.h \ |
1bc5cc8c | 3 | start.h \ |
d45fdd27 | 4 | console.h \ |
85a31821 | 5 | error.h \ |
eae6543d | 6 | monitor.h \ |
61ba7fe6 DL |
7 | utils.h \ |
8 | namespace.h \ | |
b3357a6f | 9 | caps.h \ |
0ad19a3f | 10 | lxc.h \ |
170d528e | 11 | cgroup.h \ |
13954cce | 12 | conf.h \ |
951cc719 | 13 | list.h \ |
731cc33f | 14 | log.h \ |
e0732705 | 15 | state.h \ |
72d0e1cb SG |
16 | attach.h \ |
17 | lxccontainer.h \ | |
b6b918a1 SG |
18 | lxclock.h \ |
19 | version.h | |
61ba7fe6 | 20 | |
e827ff7e SG |
21 | if IS_BIONIC |
22 | pkginclude_HEADERS += \ | |
edaf8b1b SG |
23 | ../include/openpty.h \ |
24 | ../include/lxcmntent.h | |
e827ff7e SG |
25 | endif |
26 | ||
1ba0013f SG |
27 | if !HAVE_GETLINE |
28 | if HAVE_FGETLN | |
29 | pkginclude_HEADERS += ../include/getline.h | |
30 | endif | |
31 | endif | |
32 | ||
5b46e19c CLG |
33 | sodir=$(libdir) |
34 | # use PROGRAMS to avoid complains from automake | |
35 | so_PROGRAMS = liblxc.so | |
0ad19a3f | 36 | |
5b46e19c | 37 | liblxc_so_SOURCES = \ |
cda02a28 | 38 | arguments.c arguments.h \ |
724e753c | 39 | commands.c commands.h \ |
563f2f2c | 40 | start.c start.h \ |
0ad19a3f | 41 | stop.c \ |
0ae4f887 | 42 | execute.c \ |
0ad19a3f | 43 | monitor.c monitor.h \ |
b0a33c1e | 44 | console.c \ |
0ad19a3f | 45 | freezer.c \ |
925aaa31 | 46 | checkpoint.c \ |
47 | restart.c \ | |
58412580 | 48 | error.h error.c \ |
b2718c72 | 49 | parse.c parse.h \ |
576f946d | 50 | cgroup.c cgroup.h \ |
0ad19a3f | 51 | lxc.h \ |
e3642c43 | 52 | utils.c utils.h \ |
3c22086f | 53 | sync.c sync.h \ |
5bb3ba8a | 54 | namespace.h namespace.c \ |
13954cce | 55 | conf.c conf.h \ |
df83bf6f | 56 | confile.c confile.h \ |
951cc719 | 57 | list.h \ |
35d2c3e7 | 58 | state.c state.h \ |
731cc33f | 59 | log.c log.h \ |
e0732705 | 60 | attach.c attach.h \ |
0ad19a3f | 61 | \ |
62 | network.c network.h \ | |
63 | nl.c nl.h \ | |
64 | rtnl.c rtnl.h \ | |
13832f48 | 65 | genl.c genl.h \ |
66 | \ | |
b3357a6f | 67 | caps.c caps.h \ |
c8dee0f1 | 68 | lxcseccomp.h \ |
b0a33c1e | 69 | mainloop.c mainloop.h \ |
563f2f2c DL |
70 | af_unix.c af_unix.h \ |
71 | \ | |
565c2d76 | 72 | lxcutmp.c lxcutmp.h \ |
72d0e1cb SG |
73 | apparmor.c apparmor.h \ |
74 | lxclock.h lxclock.c \ | |
b6b918a1 SG |
75 | lxccontainer.c lxccontainer.h \ |
76 | version.c version.h | |
0ad19a3f | 77 | |
e827ff7e SG |
78 | if IS_BIONIC |
79 | liblxc_so_SOURCES += \ | |
edaf8b1b SG |
80 | ../include/openpty.c ../include/openpty.h \ |
81 | ../include/lxcmntent.c ../include/lxcmntent.h | |
e827ff7e SG |
82 | endif |
83 | ||
1ba0013f SG |
84 | if !HAVE_GETLINE |
85 | if HAVE_FGETLN | |
86 | liblxc_so_SOURCES += ../include/getline.c ../include/getline.h | |
87 | endif | |
88 | endif | |
89 | ||
9c7c9037 | 90 | AM_CFLAGS=-I$(top_srcdir)/src \ |
1c41ddcb GK |
91 | -DLXCROOTFSMOUNT=\"$(LXCROOTFSMOUNT)\" \ |
92 | -DLXCPATH=\"$(LXCPATH)\" \ | |
2a59a681 | 93 | -DLXC_GLOBAL_CONF=\"$(LXC_GLOBAL_CONF)\" \ |
72d0e1cb | 94 | -DLXCINITDIR=\"$(LXCINITDIR)\" \ |
5e1e7aaf SH |
95 | -DLXCTEMPLATEDIR=\"$(LXCTEMPLATEDIR)\" \ |
96 | -DLOGPATH=\"$(LOGPATH)\" | |
b9f94fc1 | 97 | |
e075f5d9 SH |
98 | if ENABLE_APPARMOR |
99 | AM_CFLAGS += -DHAVE_APPARMOR | |
100 | endif | |
101 | ||
5e1e7aaf SH |
102 | if USE_CONFIGPATH_LOGS |
103 | AM_CFLAGS += -DUSE_CONFIGPATH_LOGS | |
104 | endif | |
105 | ||
8f2c3a70 SH |
106 | if ENABLE_SECCOMP |
107 | AM_CFLAGS += -DHAVE_SECCOMP | |
c8dee0f1 | 108 | liblxc_so_SOURCES += seccomp.c |
8f2c3a70 SH |
109 | endif |
110 | ||
b9f94fc1 | 111 | liblxc_so_CFLAGS = -fPIC -DPIC $(AM_CFLAGS) |
5b46e19c CLG |
112 | |
113 | liblxc_so_LDFLAGS = \ | |
114 | -shared \ | |
115 | -Wl,-soname,liblxc.so.$(firstword $(subst ., ,$(VERSION))) | |
116 | ||
20d2e91b SG |
117 | liblxc_so_LDADD = $(CAP_LIBS) $(APPARMOR_LIBS) $(SECCOMP_LIBS) |
118 | ||
5e97c3fc | 119 | bin_SCRIPTS = \ |
22e761af | 120 | lxc-ps \ |
0387b7a0 | 121 | lxc-netstat \ |
237315ff | 122 | lxc-checkconfig \ |
ab2d32f8 DL |
123 | lxc-version \ |
124 | lxc-create \ | |
be8b5972 | 125 | lxc-clone \ |
72be4f89 | 126 | lxc-shutdown \ |
ab2d32f8 | 127 | lxc-destroy |
5e97c3fc | 128 | |
c13c0e08 SG |
129 | EXTRA_DIST = \ |
130 | lxc-device \ | |
131 | lxc-ls \ | |
132 | lxc-top | |
133 | ||
d7415aea | 134 | if ENABLE_PYTHON |
69c478da | 135 | bin_SCRIPTS += lxc-device |
4e7186c5 | 136 | bin_SCRIPTS += lxc-ls |
d7415aea | 137 | bin_SCRIPTS += lxc-start-ephemeral |
6a85cf91 SG |
138 | else |
139 | bin_SCRIPTS += legacy/lxc-ls | |
d7415aea SG |
140 | endif |
141 | ||
f080ffd7 | 142 | if ENABLE_LUA |
f080ffd7 DE |
143 | bin_SCRIPTS += lxc-top |
144 | endif | |
145 | ||
5e97c3fc | 146 | bin_PROGRAMS = \ |
81c75799 | 147 | lxc-attach \ |
13832f48 | 148 | lxc-unshare \ |
5e97c3fc | 149 | lxc-stop \ |
150 | lxc-start \ | |
151 | lxc-execute \ | |
152 | lxc-monitor \ | |
b3ec9713 | 153 | lxc-wait \ |
5e97c3fc | 154 | lxc-console \ |
5e97c3fc | 155 | lxc-freeze \ |
0ad19a3f | 156 | lxc-info \ |
576f946d | 157 | lxc-cgroup \ |
187d3a35 | 158 | lxc-unfreeze \ |
925aaa31 | 159 | lxc-checkpoint \ |
e4b3fe58 | 160 | lxc-restart \ |
161 | lxc-kill | |
5e97c3fc | 162 | |
ce6ce9d6 | 163 | pkglibexec_PROGRAMS = \ |
a25ba7aa GT |
164 | lxc-init |
165 | ||
2a59a681 SH |
166 | #pkglibexec_SCRIPTS = \ |
167 | # lxc.functions | |
168 | ||
1c41ddcb GK |
169 | AM_LDFLAGS = -Wl,-E |
170 | if ENABLE_RPATH | |
171 | AM_LDFLAGS += -Wl,-rpath -Wl,$(libdir) | |
172 | endif | |
20d2e91b SG |
173 | LDADD=liblxc.so @CAP_LIBS@ @APPARMOR_LIBS@ @SECCOMP_LIBS@ |
174 | ||
81c75799 | 175 | lxc_attach_SOURCES = lxc_attach.c |
b9f94fc1 DL |
176 | lxc_cgroup_SOURCES = lxc_cgroup.c |
177 | lxc_checkpoint_SOURCES = lxc_checkpoint.c | |
178 | lxc_console_SOURCES = lxc_console.c | |
df83bf6f | 179 | lxc_execute_SOURCES = lxc_execute.c |
5e97c3fc | 180 | lxc_freeze_SOURCES = lxc_freeze.c |
b9f94fc1 DL |
181 | lxc_info_SOURCES = lxc_info.c |
182 | lxc_init_SOURCES = lxc_init.c | |
183 | lxc_monitor_SOURCES = lxc_monitor.c | |
925aaa31 | 184 | lxc_restart_SOURCES = lxc_restart.c |
b9f94fc1 DL |
185 | lxc_start_SOURCES = lxc_start.c |
186 | lxc_stop_SOURCES = lxc_stop.c | |
187 | lxc_unfreeze_SOURCES = lxc_unfreeze.c | |
188 | lxc_unshare_SOURCES = lxc_unshare.c | |
189 | lxc_wait_SOURCES = lxc_wait.c | |
e4b3fe58 | 190 | lxc_kill_SOURCES = lxc_kill.c |
5b46e19c CLG |
191 | |
192 | install-exec-local: install-soPROGRAMS | |
2a59a681 SH |
193 | mkdir -p $(DESTDIR)$(datadir)/lxc |
194 | install -c -m 644 lxc.functions $(DESTDIR)$(datadir)/lxc | |
5b46e19c CLG |
195 | mv $(DESTDIR)$(libdir)/liblxc.so $(DESTDIR)$(libdir)/liblxc.so.$(VERSION) |
196 | /sbin/ldconfig -l $(DESTDIR)$(libdir)/liblxc.so.$(VERSION) | |
197 | cd $(DESTDIR)$(libdir); \ | |
7af3759f | 198 | ln -sf liblxc.so.$(VERSION) liblxc.so.$(firstword $(subst ., ,$(VERSION))); \ |
5b46e19c CLG |
199 | ln -sf liblxc.so.$(firstword $(subst ., ,$(VERSION))) liblxc.so |
200 | ||
201 | uninstall-local: | |
202 | $(RM) $(DESTDIR)$(libdir)/liblxc.so* |