]> git.proxmox.com Git - mirror_lxcfs.git/blob - Makefile.am
configure.ac: release 2.0.0.beta1
[mirror_lxcfs.git] / Makefile.am
1 ACLOCAL_AMFLAGS = -I m4
2
3 SUBDIRS = tests share
4 DIST_SUBDIRS = tests share
5
6 AM_CFLAGS = -Wall -ggdb -D_GNU_SOURCE -DSBINDIR=\"$(SBINDIR)\" -pthread
7 AM_CFLAGS += $(FUSE_CFLAGS)
8 AM_CFLAGS += -DLIBDIR=\"$(LIBDIR)\"
9 AM_LDFLAGS = $(FUSE_LIBS) -pthread
10 #AM_CFLAGS += -DDEBUG
11
12 AM_CFLAGS += -DRUNTIME_PATH=\"$(RUNTIME_PATH)\"
13
14 liblxcfs_la_SOURCES = bindings.c cpuset.c bindings.h
15 liblxcfs_la_CFLAGS = $(AM_CFLAGS)
16 liblxcfs_la_LDFLAGS = $(AM_CFLAGS) -shared
17
18 liblxcfstest_la_SOURCES = bindings.c cpuset.c bindings.h
19 liblxcfstest_la_CFLAGS = $(AM_CFLAGS) -DRELOADTEST
20 liblxcfstest_la_LDFLAGS = $(AM_CFLAGS) -shared
21
22 noinst_HEADERS = bindings.h
23
24 sodir=$(libdir)
25 lib_LTLIBRARIES = liblxcfs.la
26 EXTRA_LTLIBRARIES = liblxcfstest.la
27
28 lxcfs_SOURCES = lxcfs.c
29 lxcfs_LDADD = liblxcfs.la -ldl
30 lxcfs_CFLAGS = $(AM_CFLAGS)
31 lxcfs_LDFLAGS = $(AM_LDFLAGS)
32 bin_PROGRAMS = lxcfs
33
34 EXTRA_DIST = \
35 lxcfs.man.add
36
37 if HAVE_HELP2MAN
38 man_MANS = lxcfs.1
39
40 lxcfs.1: lxcfs lxcfs.man.add
41 $(HELP2MAN) -n "Set up cgroup fs for containers" --no-discard-stderr -s 1 -I lxcfs.man.add -N ./lxcfs > lxcfs.1
42 endif
43
44 TEST_READ: tests/test-read.c
45 $(CC) -o tests/test-read tests/test-read.c
46 TEST_CPUSET: tests/cpusetrange.c cpuset.c
47 $(CC) -o tests/cpusetrange tests/cpusetrange.c cpuset.c
48 TEST_SYSCALLS: tests/test_syscalls.c
49 $(CC) -o tests/test_syscalls tests/test_syscalls.c
50
51 pam_LTLIBRARIES = pam_cgfs.la
52 pam_cgfs_la_SOURCES = pam/pam_cgfs.c
53 pam_cgfs_la_CFLAGS = $(AM_CFLAGS)
54 pam_cgfs_la_LIBADD = $(AM_LIBS) $(PAM_LIBS) -L$(top_srcdir)
55 pam_cgfs_la_LDFLAGS = $(AM_LDFLAGS) -module -avoid-version -shared
56 #pam_cgfs_la_CFLAGS += -DDEBUG
57
58 install-data-hook: install-pamLTLIBRARIES
59 rm -f "$(DESTDIR)$(pamdir)/pam_cgfs.la"
60 rm -f "$(DESTDIR)$(pamdir)/pam_cgfs.a"
61 uninstall-local:
62 rm -f "$(DESTDIR)$(pamdir)/pam_cgfs.so"
63
64
65 tests: TEST_READ TEST_CPUSET TEST_SYSCALLS
66
67 distclean:
68 rm -rf .deps/ \
69 INSTALL \
70 Makefile \
71 Makefile.in \
72 aclocal.m4 \
73 autom4te.cache/ \
74 compile \
75 config.guess \
76 config.h \
77 config.h.in \
78 config.log \
79 config.status \
80 config.sub \
81 configure \
82 depcomp \
83 install-sh \
84 libtool \
85 ltmain.sh \
86 lxcfs \
87 lxcfs.1 \
88 lxcfs.o \
89 m4/ \
90 missing \
91 stamp-h1 \
92 tests/test_syscalls \
93 *.lo *.la