File: Makefile.am

package info (click to toggle)
setools 3.3.7-3
  • links: PTS, VCS
  • area: main
  • in suites: wheezy
  • size: 9,840 kB
  • sloc: ansic: 82,247; tcl: 13,145; cpp: 4,885; makefile: 1,603; yacc: 779; lex: 296; python: 57; sh: 50
file content (89 lines) | stat: -rw-r--r-- 2,419 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
sepol_srcdir = @sepol_srcdir@

lib_LIBRARIES = libqpol.a
qpolso_DATA = libqpol.so.@libqpol_version@
qpolsodir = $(libdir)

tmp_sepol = ./tmp_sepol

AM_YFLAGS = -d
BUILT_SOURCES = policy_parse.h

# search in sepol_srcdir/include before system's sepol directory
AM_CFLAGS = @DEBUGCFLAGS@ @WARNCFLAGS@ @PROFILECFLAGS@ \
	-I$(srcdir)/../include -I$(sepol_srcdir)/../include @SELINUX_CFLAGS@ -fPIC
AM_LDFLAGS = @DEBUGLDFLAGS@ @WARNLDFLAGS@ @PROFILELDFLAGS@

libqpol_a_SOURCES = \
	avrule_query.c \
	bool_query.c \
	class_perm_query.c \
	cond_query.c \
	constraint_query.c \
	context_query.c \
	expand.c \
	expand.h \
	fs_use_query.c \
	genfscon_query.c \
	isid_query.c \
	iterator.c \
	iterator_internal.h \
	mls_query.c \
	mlsrule_query.c \
	module.c \
	module_compiler.c module_compiler.h \
	netifcon_query.c \
	nodecon_query.c \
	permissive_query.c \
	polcap_query.c \
	policy.c \
	policy_define.c policy_define.h \
	policy_extend.c \
	policy_parse.h \
	portcon_query.c \
	qpol_internal.h \
	queue.c queue.h \
	rbacrule_query.c \
	role_query.c \
	syn_rule_internal.h \
	syn_rule_query.c \
	terule_query.c \
	type_query.c \
	user_query.c \
	util.c \
	policy_parse.y policy_scan.l
libqpol_a_DEPENDENCIES = $(tmp_sepol)
libqpol_a_LIBADD = $(tmp_sepol)/*.o

libqpol_so_OBJS = $(patsubst %.c,%.o,$(filter %.c,$(libqpol_a_SOURCES))) policy_parse.o policy_scan.o
LIBQPOL_SONAME = @libqpol_soname@

dist_noinst_DATA = libqpol.map

$(tmp_sepol): $(sepol_srcdir)/libsepol.a
	mkdir -p $@
	rm -f $@/*
	cp $< $@
	(cd $@; ar x libsepol.a)

$(qpolso_DATA): $(tmp_sepol) $(libqpol_so_OBJS) libqpol.map
	$(CC) -shared -o $@ $(libqpol_so_OBJS) $(AM_LDFLAGS) $(LDFLAGS) -Wl,-soname,$(LIBQPOL_SONAME),--version-script=$(srcdir)/libqpol.map,-z,defs -Wl,--whole-archive $(sepol_srcdir)/libsepol.a -Wl,--no-whole-archive @SELINUX_LIB_FLAG@ -lselinux -lsepol -lbz2
	$(LN_S) -f $@ @libqpol_soname@
	$(LN_S) -f $@ libqpol.so

libqpol.so: $(qpolso_DATA)

install-data-hook:
	cd $(DESTDIR)$(qpolsodir) && $(LN_S) -f $(qpolso_DATA) @libqpol_soname@
	cd $(DESTDIR)$(qpolsodir) && $(LN_S) -f $(qpolso_DATA) libqpol.so

CLEANFILES = policy_parse.h policy_scan.c policy_parse.c

clean-local:
	-rm -rf $(tmp_sepol)

mostlyclean-local:
	-rm -rf *.gcno *.gcda *.gprof *.gcov libqpol.so @libqpol_soname@ $(qpolso_DATA)

uninstall-local:
	-rm -rf $(DESTDIR)$(qpolsodir)/$(qpolso_DATA) $(DESTDIR)$(qpolsodir)/@libqpol_soname@ $(DESTDIR)$(qpolsodir)/libqpol.so