Makefile.am 14.8 KB
Newer Older
1
###############################################################################
2 3 4
# Automake targets and declarations
###############################################################################

5
AUTOMAKE_OPTIONS = subdir-objects
6
SUBDIRS = . test
7

8
NULL =
9
EXTRA_DIST = \
10
	libvlc.pc.in \
Rémi Denis-Courmont's avatar
Rémi Denis-Courmont committed
11
	vlc-plugin.pc.in \
12
	libvlc.sym \
13
	libvlccore.sym \
14
	revision.txt \
15
	../include/vlc/libvlc_version.h.in
16

17 18
BUILT_SOURCES = \
	$(nodist_pkginclude_HEADERS) \
19
	$(nodist_pluginsinclude_HEADERS)
Christophe Mutricy's avatar
Christophe Mutricy committed
20
CLEANFILES = $(BUILT_SOURCES)
21

22
SUFFIXES = .pc.in .pc .rc.in .rc
23

24 25 26 27
###############################################################################
# Headers
###############################################################################

28
pluginsincludedir = $(pkgincludedir)/plugins
29

30
pkginclude_HEADERS = \
31
	../include/vlc/vlc.h \
32
	../include/vlc/deprecated.h \
33
	../include/vlc/libvlc.h \
34
	../include/vlc/libvlc_events.h \
35 36 37 38 39 40 41
	../include/vlc/libvlc_media.h \
	../include/vlc/libvlc_media_discoverer.h \
	../include/vlc/libvlc_media_library.h \
	../include/vlc/libvlc_media_list.h \
	../include/vlc/libvlc_media_list_player.h \
	../include/vlc/libvlc_media_player.h \
	../include/vlc/libvlc_structures.h \
42
	../include/vlc/libvlc_vlm.h \
43
	$(NULL)
44
nodist_pkginclude_HEADERS = ../include/vlc/libvlc_version.h
45

46
pluginsinclude_HEADERS = \
47 48
	../include/vlc_access.h \
	../include/vlc_acl.h \
49
	../include/vlc_aout.h \
Rafaël Carré's avatar
Rafaël Carré committed
50
	../include/vlc_aout_intf.h \
51
	../include/vlc_aout_mixer.h \
52
	../include/vlc_arrays.h \
Pierre Ynard's avatar
Pierre Ynard committed
53
	../include/vlc_art_finder.h \
54
	../include/vlc_atomic.h \
55
	../include/vlc_avcodec.h \
56 57 58 59 60
	../include/vlc_bits.h \
	../include/vlc_block.h \
	../include/vlc_block_helper.h \
	../include/vlc_charset.h \
	../include/vlc_codec.h \
61 62
	../include/vlc_common.h \
	../include/vlc_config.h \
63
	../include/vlc_config_cat.h \
64
	../include/vlc_configuration.h \
65
	../include/vlc_cpu.h \
66
	../include/vlc_dialog.h \
67
	../include/vlc_demux.h \
68
	../include/vlc_epg.h \
69
	../include/vlc_es.h \
70 71
	../include/vlc_es_out.h \
	../include/vlc_events.h \
72
	../include/vlc_filter.h \
73
	../include/vlc_fourcc.h \
74
	../include/vlc_fs.h \
75
	../include/vlc_gcrypt.h \
76
	../include/vlc_opengl.h \
77
	../include/vlc_http.h \
78
	../include/vlc_httpd.h \
79
	../include/vlc_image.h \
80
	../include/vlc_inhibit.h \
81
	../include/vlc_input.h \
82
	../include/vlc_input_item.h \
Rémi Denis-Courmont's avatar
Rémi Denis-Courmont committed
83
	../include/vlc_main.h \
84
	../include/vlc_md5.h \
85
	../include/vlc_messages.h \
86
	../include/vlc_meta.h \
jetru's avatar
jetru committed
87
	../include/vlc_media_library.h \
88
	../include/vlc_modules.h \
Pierre Ynard's avatar
Pierre Ynard committed
89
	../include/vlc_mouse.h \
90 91
	../include/vlc_mtime.h \
	../include/vlc_objects.h \
92
	../include/vlc_picture.h \
93 94
	../include/vlc_picture_fifo.h \
	../include/vlc_picture_pool.h \
95
	../include/vlc_playlist.h \
96
	../include/vlc_plugin.h \
97
	../include/vlc_probe.h \
98 99
	../include/vlc_rand.h \
	../include/vlc_services_discovery.h \
jetru's avatar
jetru committed
100
	../include/vlc_sql.h \
101
	../include/vlc_sout.h \
102
	../include/vlc_spu.h \
103 104
	../include/vlc_stream.h \
	../include/vlc_strings.h \
105
	../include/vlc_subpicture.h \
106
	../include/vlc_text_style.h \
107
	../include/vlc_threads.h \
108
	../include/vlc_url.h \
109 110
	../include/vlc_variables.h \
	../include/vlc_vlm.h \
111
	../include/vlc_video_splitter.h \
112
	../include/vlc_vout.h \
113
	../include/vlc_vout_display.h \
114
	../include/vlc_vout_osd.h \
115
	../include/vlc_vout_window.h \
116
	../include/vlc_xml.h \
117
	../include/vlc_xlib.h \
118
	$(NULL)
119
nodist_pluginsinclude_HEADERS = ../include/vlc_about.h
120

121
noinst_HEADERS = \
122
	../include/vlc_codec_synchro.h \
123
	../include/vlc_codecs.h \
Pierre Ynard's avatar
Pierre Ynard committed
124
	../include/vlc_extensions.h \
Rémi Denis-Courmont's avatar
Rémi Denis-Courmont committed
125
	../include/vlc_fixups.h \
126
	../include/vlc_interface.h \
127
	../include/vlc_intf_strings.h \
128
	../include/vlc_iso_lang.h \
129
	../include/vlc_keys.h \
Pierre Ynard's avatar
Pierre Ynard committed
130
	../include/vlc_memory.h \
131
	../include/vlc_network.h \
132
	../include/vlc_osd.h \
Rémi Denis-Courmont's avatar
Tabs  
Rémi Denis-Courmont committed
133
	../include/vlc_pgpkey.h \
134
	../include/vlc_tls.h \
135 136
	../include/vlc_update.h \
	../include/vlc_vod.h \
Pierre Ynard's avatar
Pierre Ynard committed
137
	../include/vlc_vout_wrapper.h \
Pierre Ynard's avatar
Pierre Ynard committed
138
	../include/vlc_windows_interfaces.h \
139 140
	$(NULL)

141
../include/vlc/libvlc_version.h: ../include/vlc/libvlc_version.h.in $(top_builddir)/config.status
142 143
	$(AM_V_GEN)cd "$(top_builddir)" && \
	$(SHELL) ./config.status --file="src/$@"
144

145
../include/vlc_about.h: Makefile.am $(top_srcdir)/COPYING $(top_srcdir)/THANKS $(top_srcdir)/AUTHORS
146 147 148 149 150 151 152
	$(AM_V_at)rm -f -- "$@.tmp"
	$(AM_V_at)mkdir -p -- ../include
	$(AM_V_GEN)(echo "/* Automatically generated file - DO NOT EDIT */" && \
	echo "static const char psz_license[] =" && \
	sed 's/"/\\"/g;s/^.*$$/\"&\\n\"/' "$(top_srcdir)/COPYING" && \
	echo ";" && \
	echo "static const char psz_thanks[] =" && \
JP Dinger's avatar
JP Dinger committed
153
	sed '/\$$Id:/d;s/"/\\"/g;s/<.*.> //;s/^.*$$/\"&\\n\"/' \
154 155 156
		"$(top_srcdir)/THANKS" && \
	echo ";" && \
	echo "static const char psz_authors[] =" && \
157
	sed '/\$$Id:/d;s/"/\\"/g;s/<.*.> //;s/^.*$$/\"&\\n\"/' \
158 159 160
		"$(top_srcdir)/AUTHORS" && \
	echo ";") >> "$@.tmp"
	$(AM_V_at)mv -f -- "$@.tmp" "$@"
161

162 163 164 165 166
###############################################################################
# pkg-config integration
###############################################################################

pkgconfigdir = $(libdir)/pkgconfig
167
pkgconfig_DATA = libvlc.pc vlc-plugin.pc
168 169
CLEANFILES += $(pkgconfig_DATA)

170
.pc.in.pc: $(top_builddir)/config.status
171
	$(AM_V_GEN)cd "$(top_builddir)" && \
172 173
	$(SHELL) ./config.status --file="src/$@"

174 175 176 177 178 179 180 181 182 183 184 185 186
##############################################################################
# Windows resource files
##############################################################################

if HAVE_WIN32
noinst_DATA = libvlc_win32_rc.rc
endif
EXTRA_DIST += libvlc_win32_rc.rc.in

.rc.in.rc: $(top_builddir)/config.status
	cd "$(top_builddir)" && \
	$(SHELL) ./config.status --file="src/$@"

187 188 189 190
###############################################################################
# Building libvlc
###############################################################################

191
lib_LTLIBRARIES = libvlccore.la libvlc.la
Rémi Denis-Courmont's avatar
Rémi Denis-Courmont committed
192

193
AM_LDFLAGS = -no-undefined
Rémi Denis-Courmont's avatar
Rémi Denis-Courmont committed
194
if HAVE_WIN32
195
AM_LDFLAGS += -avoid-version
Rémi Denis-Courmont's avatar
Rémi Denis-Courmont committed
196
endif
197 198 199
if HAVE_WINCE
AM_LDFLAGS += -avoid-version
endif
200

201
libvlccore_la_SOURCES = $(SOURCES_libvlc)
202
libvlccore_la_CFLAGS = $(CFLAGS_libvlccore) \
203
	-DMODULE_STRING=\"main\" \
204
	-DLOCALEDIR=\"$(localedir)\" \
Rémi Denis-Courmont's avatar
Rémi Denis-Courmont committed
205
	-DSYSCONFDIR=\"$(sysconfdir)\" \
206
	-DDATA_PATH=\"$(vlcdatadir)\" \
Rémi Denis-Courmont's avatar
Rémi Denis-Courmont committed
207
	-DPKGLIBDIR=\"$(vlclibdir)\"
208
libvlccore_la_LDFLAGS = $(LDFLAGS_libvlccore) $(AM_LDFLAGS) \
209
	-no-undefined \
210
	-export-symbols $(srcdir)/libvlccore.sym \
Rémi Denis-Courmont's avatar
Rémi Denis-Courmont committed
211
	-version-info 5:0:0
212
libvlccore_la_LIBADD = $(LIBS_libvlccore) $(AM_LIBADD) \
213
	$(LTLIBINTL) ../compat/libcompat.la
214
libvlccore_la_DEPENDENCIES = libvlccore.sym
215
if HAVE_WIN32
216 217
libvlccore_la_DEPENDENCIES += libvlc_win32_rc.$(OBJEXT)
libvlccore_la_LDFLAGS += -Wl,libvlc_win32_rc.$(OBJEXT)
218
endif
219

220
libvlc_win32_rc.$(OBJEXT): libvlc_win32_rc.rc
221 222
	$(WINDRES) --include-dir $(top_srcdir)/share -i $< -o $@

223
libvlc_la_SOURCES = $(SOURCES_libvlc_control)
224
libvlc_la_LIBADD = $(LIBS_libvlc) \
225
	libvlccore.la ../compat/libcompat.la
226
libvlc_la_CPPFLAGS = -DMODULE_STRING=\"libvlc\"
227 228
libvlc_la_CFLAGS = $(CFLAGS_libvlc)
libvlc_la_LDFLAGS = $(AM_LDFLAGS) $(LDFLAGS_libvlc) \
229
	-version-info 6:0:1 \
230
	-export-symbols $(srcdir)/libvlc.sym
Rémi Denis-Courmont's avatar
Rémi Denis-Courmont committed
231
libvlc_la_DEPENDENCIES = libvlc.sym libvlccore.la
232
if HAVE_WIN32
233 234
libvlc_la_DEPENDENCIES += libvlc_win32_rc.$(OBJEXT)
libvlc_la_LDFLAGS += -Wl,libvlc_win32_rc.$(OBJEXT)
235 236
endif

237

238
EXTRA_libvlccore_la_SOURCES = \
Rémi Denis-Courmont's avatar
Rémi Denis-Courmont committed
239
	$(SOURCES_libvlc_darwin) \
240
	$(SOURCES_libvlc_linux) \
Rémi Denis-Courmont's avatar
Rémi Denis-Courmont committed
241
	$(SOURCES_libvlc_win32) \
242
	$(SOURCES_libvlc_other) \
243
	$(SOURCES_libvlc_httpd) \
244
	$(SOURCES_libvlc_sout) \
245
	$(SOURCES_libvlc_vlm) \
Rémi Denis-Courmont's avatar
Rémi Denis-Courmont committed
246
	$(NULL)
247
if HAVE_DARWIN
248
libvlccore_la_SOURCES += $(SOURCES_libvlc_darwin)
249 250
else
if HAVE_LINUX
251
libvlccore_la_SOURCES += $(SOURCES_libvlc_linux)
252
else
253
if HAVE_WIN32
254
libvlccore_la_SOURCES += $(SOURCES_libvlc_win32)
255
else
256
if HAVE_WINCE
257
libvlccore_la_SOURCES += $(SOURCES_libvlc_win32)
258
else
259
if HAVE_SYMBIAN
260
#libvlccore_la_SOURCES += $(SOURCES_libvlc_symbian)
261
else
262
libvlccore_la_SOURCES += $(SOURCES_libvlc_other)
263
endif
264 265 266
endif
endif
endif
267
endif
268 269 270
if BUILD_HTTPD
libvlccore_la_SOURCES += $(SOURCES_libvlc_httpd)
endif
271
if ENABLE_SOUT
272
libvlccore_la_SOURCES += $(SOURCES_libvlc_sout)
273 274 275
if ENABLE_VLM
libvlccore_la_SOURCES += $(SOURCES_libvlc_vlm)
endif
276
endif
277

278
SOURCES_libvlc_darwin = \
Pierre Ynard's avatar
Pierre Ynard committed
279
	posix/darwin_dirs.c \
280
	misc/atomic.c \
281
	posix/filesystem.c \
282
	posix/plugin.c \
283
	network/poll.c \
284 285
	posix/thread.c \
	posix/darwin_specific.c \
286 287
	$(NULL)

288
SOURCES_libvlc_linux = \
289
	posix/dirs.c \
290
	misc/atomic.c \
291
	posix/filesystem.c \
292
	posix/plugin.c \
293
	network/poll.c \
294 295
	posix/thread.c \
	posix/linux_specific.c \
296 297
	$(NULL)

298
SOURCES_libvlc_win32 = \
299
	win32/dirs.c \
300
	win32/atomic.c \
301
	win32/filesystem.c \
302
	win32/plugin.c \
303
	win32/poll.c \
304
	win32/thread.c \
305
	win32/specific.c \
306
	win32/winsock.c \
307 308
	$(NULL)

309 310
SOURCES_libvlc_symbian = \
	symbian/path.cpp \
311 312
	symbian/dirs.c \
	misc/atomic.c \
313
	win32/plugin.c \
314 315
	$(NULL)

316
SOURCES_libvlc_other = \
317
	posix/dirs.c \
318
	misc/atomic.c \
319
	posix/filesystem.c \
320
	network/poll.c \
321 322 323
	posix/thread.c \
	posix/specific.c \
	$(NULL)
324

325 326 327
SOURCES_libvlc_common = \
	libvlc.c \
	libvlc.h \
328
	libvlc-module.c \
329
	missing.c \
330
	revision.c \
331
	version.c \
332
	interface/dialog.c \
333 334
	interface/interface.c \
	interface/intf_eject.c \
335
	playlist/playlist_internal.h \
336
	playlist/art.c \
Christophe Mutricy's avatar
Christophe Mutricy committed
337
	playlist/art.h \
338 339 340
	playlist/thread.c \
	playlist/control.c \
	playlist/engine.c \
341
	playlist/fetcher.c \
Christophe Mutricy's avatar
Christophe Mutricy committed
342
	playlist/fetcher.h \
343 344
	playlist/sort.c \
	playlist/loadsave.c \
345
	playlist/preparser.c \
Christophe Mutricy's avatar
Christophe Mutricy committed
346
	playlist/preparser.h \
347
	playlist/tree.c \
348
	playlist/item.c \
349
	playlist/search.c \
350
	playlist/services_discovery.c \
351
	input/item.c \
352 353 354 355
	input/access.c \
	input/clock.c \
	input/control.c \
	input/decoder.c \
356
	input/decoder_synchro.c \
357 358
	input/demux.c \
	input/es_out.c \
359
	input/es_out_timeshift.c \
360
	input/event.c \
361
	input/input.c \
Christophe Mutricy's avatar
Christophe Mutricy committed
362
	input/info.h \
363
	input/meta.c \
364
	input/access.h \
365 366
	input/clock.h \
	input/decoder.h \
367
	input/demux.h \
368
	input/es_out.h \
369
	input/es_out_timeshift.h \
370
	input/event.h \
371
	input/item.h \
372
	input/stream.h \
373
	input/input_internal.h \
374
	input/input_interface.h \
375
	input/vlm_internal.h \
Laurent Aimar's avatar
Laurent Aimar committed
376
	input/vlm_event.h \
377 378
	input/resource.h \
	input/resource.c \
379
	input/stream.c \
380
	input/stream_demux.c \
381
	input/stream_filter.c \
382
	input/stream_memory.c \
383 384
	input/subtitles.c \
	input/var.c \
ivoire's avatar
ivoire committed
385
	video_output/chrono.h \
386 387
	video_output/control.c \
	video_output/control.h \
388 389
	video_output/display.c \
	video_output/display.h \
Pierre Ynard's avatar
Pierre Ynard committed
390
	video_output/event.h \
391 392
	video_output/inhibit.c \
	video_output/inhibit.h \
393 394
	video_output/interlacing.c \
	video_output/interlacing.h \
395 396
	video_output/snapshot.c \
	video_output/snapshot.h \
397
	video_output/statistic.h \
398 399
	video_output/postprocessing.c \
	video_output/postprocessing.h \
400 401
	video_output/video_output.c \
	video_output/video_text.c \
402
	video_output/video_epg.c \
403 404
	video_output/video_widgets.c \
	video_output/vout_subpictures.c \
405
	video_output/window.c \
406
	video_output/opengl.c \
407
	video_output/vout_intf.c \
Laurent Aimar's avatar
Laurent Aimar committed
408
	video_output/vout_internal.h \
409
	video_output/vout_control.h \
410
	video_output/vout_wrapper.c \
zorglub's avatar
zorglub committed
411
	audio_output/aout_internal.h \
412 413 414
	audio_output/common.c \
	audio_output/dec.c \
	audio_output/filters.c \
415
	audio_output/input.c \
416 417 418 419 420 421 422 423 424 425
	audio_output/mixer.c \
	audio_output/output.c \
	audio_output/intf.c \
	osd/osd.c \
	osd/osd_text.c \
	network/acl.c \
	network/getaddrinfo.c \
	network/io.c \
	network/tcp.c \
	network/udp.c \
Rémi Denis-Courmont's avatar
Rémi Denis-Courmont committed
426
	network/rootbind.c \
427
	network/tls.c \
428 429 430
	text/charset.c \
	text/strings.c \
	text/unicode.c \
431
	text/filesystem.c \
432 433
	text/iso_lang.c \
	text/iso-639_def.h \
434
	misc/md5.c \
435
	misc/probe.c \
436
	misc/rand.c \
437 438
	misc/mtime.c \
	misc/block.c \
439
	misc/fourcc.c \
440
	misc/es_format.c \
441
	misc/picture.c \
442 443
	misc/picture_fifo.c \
	misc/picture_pool.c \
444 445
	modules/modules.h \
	modules/modules.c \
446
	modules/bank.c \
447
	modules/cache.c \
448
	modules/entry.c \
449
	modules/textdomain.c \
450 451 452
	misc/threads.c \
	misc/stats.c \
	misc/cpu.c \
453
	misc/epg.c \
454
	misc/exit.c \
455
	config/configuration.h \
456 457 458
	config/core.c \
	config/chain.c \
	config/file.c \
459
        config/help.c \
460
	config/intf.c \
461
	config/keys.c \
462
	config/cmdline.c \
463
	config/dirs.c \
464 465
	config/getopt.c \
	config/vlc_getopt.h \
466
	misc/events.c \
467 468 469
	misc/image.c \
	misc/messages.c \
	misc/objects.c \
zorglub's avatar
zorglub committed
470
	misc/variables.h \
471 472
	misc/variables.c \
	misc/error.c \
Rafaël Carré's avatar
Typo  
Rafaël Carré committed
473
	misc/update.h \
474
	misc/update.c \
475
	misc/update_crypto.c \
476
	misc/xml.c \
jetru's avatar
jetru committed
477
	misc/media_library.c \
478
	extras/libc.c \
479
	extras/tdestroy.c \
Laurent Aimar's avatar
Laurent Aimar committed
480
	misc/filter.c \
481
	misc/filter_chain.c \
482
	misc/http_auth.c \
jetru's avatar
jetru committed
483
	misc/sql.c \
484
	misc/text_style.c \
485 486
	misc/subpicture.c \
	misc/subpicture.h \
487 488
	$(NULL)

489 490 491 492
SOURCES_libvlc_httpd = \
	network/httpd.c \
	$(NULL)

493 494 495 496 497 498 499 500
SOURCES_libvlc_sout = \
	stream_output/stream_output.c \
	stream_output/stream_output.h \
	stream_output/announce.c \
	stream_output/sap.c \
	stream_output/sdp.c \
	$(NULL)

501 502
SOURCES_libvlc_vlm = \
	input/vlm.c \
Laurent Aimar's avatar
Laurent Aimar committed
503
	input/vlm_event.c \
504 505 506
	input/vlmshell.c \
	$(NULL)

507 508 509 510
SOURCES_libvlc = \
	$(SOURCES_libvlc_common) \
	$(NULL)

511
SOURCES_libvlc_control = \
512
	revision.c \
zorglub's avatar
zorglub committed
513
	control/libvlc_internal.h \
514
	control/event_internal.h \
515 516 517
	control/media_internal.h \
	control/media_list_internal.h \
	control/media_player_internal.h \
518
	control/core.c \
519
	control/error.c \
520 521 522 523 524
	control/log.c \
	control/playlist.c \
	control/vlm.c \
	control/video.c \
	control/audio.c \
littlejohn's avatar
littlejohn committed
525
	control/event.c \
526
	control/event_async.c \
527 528
	control/media.c \
	control/media_player.c \
529
	control/media_list.c \
530
	control/media_list_path.h \
531
	control/media_list_player.c \
532
	control/media_library.c \
533
	control/media_discoverer.c
534

535 536 537 538
###############################################################################
# libvlc pulse
###############################################################################

Rémi Denis-Courmont's avatar
Rémi Denis-Courmont committed
539
if HAVE_PULSE
540
pkglib_LTLIBRARIES = libvlcpulse.la
Rémi Denis-Courmont's avatar
Rémi Denis-Courmont committed
541
endif
542 543 544 545 546 547

libvlcpulse_la_SOURCES = pulse/mainloop.c ../include/vlc_pulse.h
libvlcpulse_la_CPPFLAGS = $(PULSE_CFLAGS)
libvlcpulse_la_LIBADD = $(PULSE_LIBS) libvlccore.la
libvlcpulse_la_LDFLAGS = -export-symbols-regex ^vlc_pa_ -no-undefined

Rémi Denis-Courmont's avatar
Rémi Denis-Courmont committed
548 549 550 551 552 553
###############################################################################
# GIT revision
###############################################################################

BUILT_SOURCES += stamp-revision

554 555 556 557
$(srcdir)/revision.c: $(srcdir)/revision.txt
	$(AM_V_at)rm -f -- $@
	$(AM_V_GEN)echo "const char psz_vlc_changeset[] = \"$$(cat $<)\";" \
		> $@
Rémi Denis-Courmont's avatar
Rémi Denis-Courmont committed
558

559
$(srcdir)/revision.txt:
560
	$(AM_V_at)$(MAKE) stamp-revision
561
	$(AM_V_GEN)touch $@
Rémi Denis-Courmont's avatar
Rémi Denis-Courmont committed
562 563

stamp-revision:
564
	$(AM_V_at)rm -f -- revision.tmp
565 566 567 568 569 570
	$(AM_V_GEN)if ! git \
			--git-dir="$(top_srcdir)/.git/" describe \
			--tags --long --match '?.*.*' --always; then \
		cat $(srcdir)/revision.txt ; \
	fi > revision.tmp
	$(AM_V_at)if diff revision.tmp $(srcdir)/revision.txt >/dev/null 2>&1; then \
571 572
		rm -f -- revision.tmp; \
	else \
573 574 575
		mv -f -- revision.tmp $(srcdir)/revision.txt; \
	fi
#2>&1
Rémi Denis-Courmont's avatar
Rémi Denis-Courmont committed
576

577 578 579
###############################################################################
# Unit/regression test
###############################################################################
580

581
dist_check_SCRIPTS = check_headers
582

583
check-local:
584
	for h in `echo $(pkginclude_HEADERS) | sed -e s,\.\./include/,,g`; \
585 586 587 588 589 590 591 592
	do \
		echo grep - "#include <$$h>" $(srcdir)/test/headers.c ; \
		if ! grep -- "#include <$$h>" $(srcdir)/test/headers.c ; \
		then \
			echo "Header $$h not included in test/headers.c!"; \
			exit 1; \
		fi ; \
	done
593
	$(srcdir)/check_headers $(pkginclude_HEADERS)
Rémi Denis-Courmont's avatar
Rémi Denis-Courmont committed
594
	$(srcdir)/check_headers $(pluginsinclude_HEADERS)
595

596
FORCE:
597 598 599 600
	@echo "Generated source cannot be phony. Go away." >&2
	@exit 1

.PHONY: FORCE