summaryrefslogtreecommitdiff
path: root/p11-kit/tests/Makefile.am
blob: 5e90150e0f93767d14509e10aacd4faf3ecda1d1 (plain)
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

include $(top_srcdir)/build/Makefile.tests

COMMON = $(top_srcdir)/common

AM_CPPFLAGS = \
	-I$(top_srcdir) \
	-I$(srcdir)/.. \
	-I$(COMMON) \
	$(TEST_CFLAGS)

LDADD = \
	$(top_builddir)/p11-kit/libp11-kit-testable.la \
	$(top_builddir)/common/libp11-test.la \
	$(top_builddir)/common/libp11-common.la \
	$(CUTEST_LIBS) \
	$(LTLIBINTL)

CHECK_PROGS = \
	test-progname \
	test-util \
	test-conf \
	test-uri \
	test-pin \
	test-init \
	test-modules \
	test-deprecated \
	test-proxy \
	test-iter \
	$(NULL)

if WITH_FFI

CHECK_PROGS += \
	test-virtual \
	test-managed \
	test-log \
	$(NULL)

endif

noinst_PROGRAMS = \
	print-messages \
	frob-setuid \
	$(CHECK_PROGS)

TESTS = $(CHECK_PROGS)

noinst_LTLIBRARIES = \
	mock-one.la \
	mock-two.la \
	mock-three.la \
	mock-four.la

mock_one_la_SOURCES = \
	mock-module-ep.c

mock_one_la_CFLAGS = \
	$(AM_CFLAGS)

mock_one_la_LIBADD = \
	$(top_builddir)/common/libp11-test.la \
	$(top_builddir)/common/libp11-common.la \
	$(NULL)

mock_one_la_LDFLAGS = \
	-module -avoid-version -rpath /nowhere \
	-no-undefined -export-symbols-regex 'C_GetFunctionList'

mock_two_la_SOURCES = $(mock_one_la_SOURCES)
mock_two_la_CFLAGS = $(mock_one_la_CFLAGS)
mock_two_la_LDFLAGS = $(mock_one_la_LDFLAGS)
mock_two_la_LIBADD = $(mock_one_la_LIBADD)

mock_three_la_SOURCES = $(mock_one_la_SOURCES)
mock_three_la_CFLAGS = $(mock_one_la_CFLAGS)
mock_three_la_LDFLAGS = $(mock_one_la_LDFLAGS)
mock_three_la_LIBADD = $(mock_one_la_LIBADD)

mock_four_la_SOURCES = $(mock_one_la_SOURCES)
mock_four_la_LDFLAGS = $(mock_one_la_LDFLAGS)
mock_four_la_LIBADD = $(mock_one_la_LIBADD)

EXTRA_DIST = \
	files \
	test-mock.c \
	$(NULL)