Makefile.am 5.23 KB
Newer Older
Matthias Clasen's avatar
Matthias Clasen committed
1
include $(top_srcdir)/glib-tap.mk
2

3
4
5
6
if USE_SYSTEM_PCRE
pcre_lib = $(PCRE_LIBS)
pcre_inc = $(PCRE_CFLAGS)
else
7
pcre_lib = $(top_builddir)/glib/pcre/libpcre.la
8
pcre_inc = -DPCRE_STATIC
9
10
endif

11
12
13
LDADD = $(top_builddir)/glib/libglib-2.0.la -lm
AM_CPPFLAGS = -g $(glib_INCLUDES) $(GLIB_DEBUG_FLAGS)
DEFS = -DG_LOG_DOMAIN=\"GLib\" -DEXEEXT=\"$(EXEEXT)\"
14
15
16
17
AM_CFLAGS = $(GLIB_WARN_CFLAGS) $(pcre_inc)

# The regex test uses pcre_version()
regex_LDADD = $(LDADD) $(pcre_lib)
18

19
20
21
22
23
# These tests corrupt the gcov bookkeeping, so we
# skip them. See bug 682133
spawn_singlethread_LDFLAGS = $(patsubst -lgcov,,$(LDFLAGS))
spawn_multithreaded_LDFLAGS = $(patsubst -lgcov,,$(LDFLAGS))

24
# -----------------------------------------------------------------------------
25

26
27
28
29
30
31
dist_test_data = \
	keyfiletest.ini			\
	pages.ini			\
	keyfile.c			\
	empty				\
	4096-random-bytes		\
32
33
	$(NULL)

34
35
dist_test_extra_scripts = \
	echo-script			\
36
	echo-script.bat			\
37
38
	$(NULL)

39
40
test_extra_programs = \
	test-spawn-echo			\
41
42
	$(NULL)

43
test_programs = \
44
45
46
47
48
49
50
	array-test			\
	asyncqueue			\
	base64				\
	bitlock				\
	bookmarkfile			\
	bytes				\
	cache				\
51
	charset				\
52
53
54
55
56
57
58
59
60
61
62
	checksum			\
	collate				\
	cond				\
	convert				\
	dataset				\
	date				\
	dir				\
	environment			\
	error				\
	fileutils			\
	gdatetime			\
63
	guuid				\
64
65
66
67
68
69
70
71
72
73
	gvariant			\
	hash				\
	hmac				\
	hook				\
	hostutils			\
	keyfile				\
	list				\
	logging				\
	mainloop			\
	mappedfile			\
74
	markup				\
75
76
77
78
79
80
81
82
83
84
	markup-parse			\
	markup-collect			\
	markup-escape			\
	markup-subparser		\
	mem-overflow			\
	mutex				\
	node				\
	once				\
	option-context			\
	option-argv0			\
85
86
	overflow			\
	overflow-fallback		\
87
88
89
90
91
	pattern				\
	private				\
	protocol			\
	queue				\
	rand				\
Emmanuele Bassi's avatar
Emmanuele Bassi committed
92
	rcbox				\
93
	rec-mutex			\
94
	refstring			\
95
96
97
	regex				\
	rwlock				\
	scannerapi			\
98
	search-utils			\
99
100
101
102
103
104
105
106
107
	sequence			\
	shell				\
	slice				\
	slist				\
	sort				\
	spawn-multithreaded		\
	spawn-singlethread		\
	strfuncs			\
	string				\
108
	testing				\
109
110
111
	test-printf			\
	thread				\
	timeout				\
112
	timer				\
113
114
115
116
117
118
119
120
121
122
	tree				\
	utf8-performance		\
	utf8-pointer			\
	utf8-validate			\
	utf8-misc			\
	utils				\
	unicode				\
	uri				\
	1bit-mutex			\
	642026				\
123
	$(NULL)
124

125
126
uninstalled_test_programs = \
	$(NULL)
127

128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
dist_test_data += \
	bookmarks/fail-01.xbel \
	bookmarks/fail-02.xbel \
	bookmarks/fail-03.xbel \
	bookmarks/fail-04.xbel \
	bookmarks/fail-05.xbel \
	bookmarks/fail-06.xbel \
	bookmarks/fail-07.xbel \
	bookmarks/fail-08.xbel \
	bookmarks/fail-09.xbel \
	bookmarks/fail-10.xbel \
	bookmarks/fail-11.xbel \
	bookmarks/fail-12.xbel \
	bookmarks/fail-13.xbel \
	bookmarks/fail-14.xbel \
	bookmarks/fail-15.xbel \
	bookmarks/fail-16.xbel \
	bookmarks/fail-17.xbel \
	bookmarks/valid-01.xbel \
	bookmarks/valid-02.xbel \
	bookmarks/valid-03.xbel \
	$(NULL)
150

151
152
153
154
155
156
157
158
159
160
markup_tests = \
	fail-1 fail-2 fail-3 fail-4 fail-5 \
	fail-6 fail-7 fail-8 fail-9 fail-10 \
	fail-11 fail-12 fail-13 fail-14 fail-15 \
	fail-16 fail-17 fail-18 fail-19 fail-20 \
	fail-21 fail-22 fail-23 fail-24 fail-25 \
	fail-26 fail-27 fail-28 fail-29 fail-30 \
	fail-31 fail-32 fail-33 fail-34 fail-35 \
	fail-36 fail-37 fail-38 fail-39 fail-40 \
	fail-41 fail-42 fail-43 fail-44 fail-45 \
161
	fail-46 fail-47 fail-48 fail-49 fail-50 \
162
163
164
	valid-1 valid-2 valid-3 valid-4 valid-5 \
	valid-6 valid-7 valid-8 valid-9 valid-10 \
	valid-11 valid-12 valid-13 valid-14 valid-15 \
165
166
167
168
169
	valid-16 \
	$(NULL)

cdata_markup_tests = \
	valid-8 valid-16 \
170
	$(NULL)
171

172
dist_test_data += $(all_markup_data)
173
174
175
all_markup_data = \
	$(addprefix markups/,$(markup_tests:=.gmarkup) $(markup_tests:=.expected)) \
	$(addprefix markups/,$(cdata_markup_tests.=.cdata-as-text))
176

177
# -----------------------------------------------------------------------------
178

179
test_programs += atomic
180
atomic_CFLAGS  = $(AM_CFLAGS)
181
182
183
if HAVE_GCC
atomic_CFLAGS += -Wstrict-aliasing=2
endif
184

185
overflow_fallback_SOURCES = overflow.c
186
# FIXME: FLAGS?
187
188
overflow_fallback_FALGS = $(AM_CFLAGS) -D_GLIB_TEST_OVERFLOW_FALLBACK

189
test_programs += 642026-ec
190
642026_ec_SOURCES = 642026.c
191
642026_ec_CFLAGS = -DG_ERRORCHECK_MUTEXES
192

193
uninstalled_test_programs += 1bit-emufutex
194
1bit_emufutex_SOURCES  = 1bit-mutex.c
195
1bit_emufutex_CFLAGS = $(AM_CFLAGS) -DTEST_EMULATED_FUTEX
196

197
uninstalled_test_programs += gwakeup
198
199
gwakeup_SOURCES = gwakeuptest.c ../../glib/gwakeup.c

200
# -----------------------------------------------------------------------------
201
202

if OS_UNIX
203
204
205
206
test_programs += \
	unix				\
	include				\
	$(NULL)
207

Matthias Clasen's avatar
Matthias Clasen committed
208
# some testing of gtester functionality
209
XMLLINT = xmllint
Matthias Clasen's avatar
Matthias Clasen committed
210
GTESTER = $(top_builddir)/glib/gtester
211

212
213
214
gtester-xmllint-check: # check testreport xml with xmllint if present
	${GTESTER} -k --quiet -o tmpsample.xml --test-arg=--gtester-selftest ${GTESTER}
	${XMLLINT} --version 2>/dev/null; test "$$?" != 0 || ${XMLLINT} --noout tmpsample.xml
215

216
CLEANFILES += tmpsample.xml
217

218
check-am: gtester-xmllint-check
Matthias Clasen's avatar
2.15.1    
Matthias Clasen committed
219

220
private_LDFLAGS = @G_THREAD_LIBS@
221
thread_LDFLAGS = @G_THREAD_LIBS@
222
223
endif

Colin Walters's avatar
Colin Walters committed
224
225
226
227
228
229
if HAVE_GCC
test_programs += \
	autoptr				\
	$(NULL)
endif

230
231
232
233
if OS_WIN32
test_programs += gpoll
endif

234
# -----------------------------------------------------------------------------
235

236
237
238
239
if HAVE_EVENTFD
uninstalled_test_programs += gwakeup-fallback
gwakeup_fallback_SOURCES = gwakeuptest.c ../../glib/gwakeup.c
gwakeup_fallback_CFLAGS = $(AM_CFLAGS) -DTEST_EVENTFD_FALLBACK
240
241
endif

242
# -----------------------------------------------------------------------------
243

244
EXTRA_DIST += bookmarks.xbel