1 ###############################################################################
2 # Automake targets and declarations
3 ###############################################################################
5 AUTOMAKE_OPTIONS = subdir-objects
8 EXTRA_DIST = extras/COPYING modules/builtin.h.in libvlc.sym
10 BUILT_SOURCES = modules/builtin.h misc/revision.c ../include/vlc_about.h
11 CLEANFILES = $(BUILT_SOURCES)
13 ###############################################################################
15 ###############################################################################
17 pkgincludedir = $(includedir)/vlc
19 dist_pkginclude_HEADERS = \
20 ../include/vlc/vlc.h \
21 ../include/vlc/libvlc.h \
22 ../include/vlc/libvlc_structures.h \
23 ../include/vlc/mediacontrol.h \
24 ../include/vlc/mediacontrol_structures.h \
27 noinst_HEADERS = $(HEADERS_include)
30 ../include/iso_lang.h \
33 ../include/vlc_access.h \
34 ../include/vlc_acl.h \
35 ../include/vlc_aout.h \
36 ../include/vlc_arrays.h \
37 ../include/vlc_bits.h \
38 ../include/vlc_block.h \
39 ../include/vlc_block_helper.h \
40 ../include/vlc_charset.h \
41 ../include/vlc_codec.h \
42 ../include/vlc_codec_synchro.h \
43 ../include/vlc_codecs.h \
44 ../include/vlc_common.h \
45 ../include/vlc_config.h \
46 ../include/vlc_config_cat.h \
47 ../include/vlc_configuration.h \
48 ../include/vlc_demux.h \
49 ../include/vlc_devices.h \
50 ../include/vlc_epg.h \
52 ../include/vlc_es_out.h \
53 ../include/vlc_events.h \
54 ../include/vlc_filter.h \
55 ../include/vlc_fixups.h \
56 ../include/vlc_httpd.h \
57 ../include/vlc_image.h \
58 ../include/vlc_input.h \
59 ../include/vlc_interface.h \
60 ../include/vlc_intf_strings.h \
61 ../include/vlc_keys.h \
62 ../include/vlc_md5.h \
63 ../include/vlc_messages.h \
64 ../include/vlc_meta.h \
65 ../include/vlc_modules.h \
66 ../include/vlc_modules_macros.h \
67 ../include/vlc_mtime.h \
68 ../include/vlc_network.h \
69 ../include/vlc_objects.h \
70 ../include/vlc_os_specific.h \
71 ../include/vlc_osd.h \
72 ../include/vlc_pgpkey.h \
73 ../include/vlc_playlist.h \
74 ../include/vlc_plugin.h \
75 ../include/vlc_rand.h \
76 ../include/vlc_services_discovery.h \
77 ../include/vlc_sout.h \
78 ../include/vlc_stream.h \
79 ../include/vlc_streaming.h \
80 ../include/vlc_strings.h \
81 ../include/vlc_threads.h \
82 ../include/vlc_threads_funcs.h \
83 ../include/vlc_tls.h \
84 ../include/vlc_update.h \
85 ../include/vlc_url.h \
86 ../include/vlc_variables.h \
87 ../include/vlc_vlm.h \
88 ../include/vlc_vod.h \
89 ../include/vlc_vout.h \
90 ../include/vlc_xml.h \
93 modules/builtin.h: modules/builtin.h.in ../vlc-config Makefile.am
95 cat "$(srcdir)/modules/builtin.h.in" > "$@.tmp"
97 plugins="$$($(VLC_CONFIG) --list plugin)" ; \
98 test -n "$${plugins}" && \
99 for p in $${plugins}; do \
100 echo "int vlc_entry__$$p (module_t *);" ; \
103 echo "#define ALLOCATE_ALL_BUILTINS() \\" >> "$@.tmp"
104 echo " do \\" >> "$@.tmp"
105 echo " { \\" >> "$@.tmp"
107 plugins="$$($(VLC_CONFIG) --list plugin)" ; \
108 test -n "$${plugins}" && \
109 for p in $${plugins}; do \
110 echo " ALLOCATE_BUILTIN($$p); \\" ; \
113 echo ' } while( 0 );' >> "$@.tmp"
114 mv -f -- "$@.tmp" "$@"
116 modules/modules.c: modules/builtin.h
118 ../include/vlc_about.h: Makefile.am $(top_srcdir)/COPYING $(top_srcdir)/THANKS $(top_srcdir)/AUTHORS
120 mkdir -p -- ../include
121 echo "/* Automatically generated file - DO NOT EDIT */" > "$@.tmp"
122 echo "static const char psz_license[] =" >> "$@.tmp"
123 cat $(top_srcdir)/COPYING | sed s/'"'/'\\"'/g | $(AWK) '{ print "\""$$0"\\n\"" }' >> "$@.tmp"
125 echo "static const char psz_thanks[] =" >> "$@.tmp"
126 grep -v '$$Id:' $(top_srcdir)/THANKS | sed s/'"'/'\\"'/g | $(AWK) '{ print "\""$$0"\\n\"" }'|sed s/"<.*.> "// >> "$@.tmp"
128 echo "static const char psz_authors[] =" >> "$@.tmp"
129 grep N: $(top_srcdir)/AUTHORS | cut -d" " -f 2- | sed s/'"'/'\\"'/g | $(AWK) '{ print "\""$$0"\\n\"" }' >> "$@.tmp"
131 mv -f -- "$@.tmp" "$@"
132 ###############################################################################
134 ###############################################################################
137 $(top_builddir)/compile
139 lib_LTLIBRARIES = libvlc.la libvlc-control.la
141 AM_LDFLAGS = -no-undefined -no-install
143 AM_LDFLAGS += -avoid-version
146 libvlc_la_SOURCES = $(SOURCES_libvlc)
147 nodist_libvlc_la_SOURCES = misc/revision.c
148 libvlc_la_CFLAGS = `$(VLC_CONFIG) --cflags libvlc` \
149 -DDATA_PATH=\"$(pkgdatadir)\"
150 libvlc_la_CXXFLAGS = `$(VLC_CONFIG) --cxxflags libvlc`
151 libvlc_la_OBJCFLAGS = `$(VLC_CONFIG) --objcflags libvlc`
152 libvlc_la_LDFLAGS = `$(VLC_CONFIG) --ldflags libvlc` $(AM_LDFLAGS) \
154 if HAVE_COMPILER_EXPORT
155 libvlc_la_LDFLAGS += -export-dynamic
157 libvlc_la_LDFLAGS += -export-symbols $(srcdir)/libvlc.sym
159 libvlc_la_LIBADD = `$(VLC_CONFIG) -libs libvlc` $(AM_LIBADD) $(LTLIBINTL)
161 libvlc_la_DEPENDENCIES = libvlc.sym
163 libvlc_control_la_SOURCES = $(SOURCES_libvlc_control)
164 libvlc_control_la_LIBADD = libvlc.la
165 libvlc_control_la_CFLAGS = `$(VLC_CONFIG) --cflags libvlc`
166 libvlc_control_la_LDFLAGS = $(AM_LDFLAGS) -version-info 1:0:0
167 if HAVE_COMPILER_EXPORT
168 libvlc_control_la_LDFLAGS += -export-dynamic
170 libvlc_control_la_LDFLAGS += -export-symbols-regex '^_?(libvlc|mediacontrol)_.*'
173 EXTRA_libvlc_la_SOURCES = \
174 $(SOURCES_libvlc_beos) \
175 $(SOURCES_libvlc_darwin) \
176 $(SOURCES_libvlc_win32) \
177 $(SOURCES_libvlc_dirent) \
178 $(SOURCES_libvlc_getopt) \
181 libvlc_la_SOURCES += $(SOURCES_libvlc_beos)
184 libvlc_la_SOURCES += $(SOURCES_libvlc_darwin)
187 libvlc_la_SOURCES += $(SOURCES_libvlc_win32)
190 libvlc_la_SOURCES += $(SOURCES_libvlc_win32)
193 libvlc_la_SOURCES += $(SOURCES_libvlc_dirent)
196 libvlc_la_SOURCES += $(SOURCES_libvlc_getopt)
199 SOURCES_libvlc_beos = \
200 misc/beos_specific.cpp \
203 SOURCES_libvlc_darwin = \
204 misc/darwin_specific.c \
207 SOURCES_libvlc_win32 = \
208 misc/win32_specific.c \
211 SOURCES_libvlc_dirent = \
215 SOURCES_libvlc_getopt = \
221 SOURCES_libvlc_common = \
226 interface/interface.h \
227 interface/interface.c \
228 interface/intf_eject.c \
229 interface/interaction.c \
230 playlist/playlist_internal.h \
235 playlist/loadsave.c \
239 playlist/services_discovery.c \
245 input/decoder_synchro.c \
250 input/input_internal.h \
251 input/vlm_internal.h \
256 video_output/video_output.c \
257 video_output/vout_pictures.c \
258 video_output/vout_pictures.h \
259 video_output/video_text.c \
260 video_output/video_widgets.c \
261 video_output/vout_subpictures.c \
262 video_output/vout_intf.c \
263 audio_output/aout_internal.h \
264 audio_output/common.c \
266 audio_output/filters.c \
267 audio_output/input.c \
268 audio_output/mixer.c \
269 audio_output/output.c \
270 audio_output/intf.c \
271 stream_output/stream_output.c \
272 stream_output/stream_output.h \
273 stream_output/announce.c \
274 stream_output/profiles.c \
275 stream_output/sap.c \
276 stream_output/sdp.c \
281 network/getaddrinfo.c \
308 config/configuration.h \
329 $(SOURCES_libvlc_common) \
330 $(OPT_SOURCES_libvlc_beos) \
331 $(OPT_SOURCES_libvlc_darwin) \
332 $(OPT_SOURCES_libvlc_win32) \
333 $(OPT_SOURCES_libvlc_dirent) \
334 $(OPT_SOURCES_libvlc_getopt) \
337 SOURCES_libvlc_control = \
338 control/libvlc_internal.h \
345 control/dynamic_media_list.c \
347 control/flat_media_list_view.c \
348 control/hierarchical_media_list_view.c \
349 control/hierarchical_node_media_list_view.c \
350 control/media_descriptor.c \
351 control/media_instance.c \
352 control/media_list.c \
353 control/media_list_path.h \
354 control/media_list_player.c \
355 control/media_list_view.c \
356 control/media_library.c \
357 control/mediacontrol_internal.h \
358 control/mediacontrol_core.c \
359 control/mediacontrol_util.c \
360 control/mediacontrol_audio_video.c \
361 control/media_discoverer.c \
364 ###############################################################################
366 ###############################################################################
370 echo "/* AUTOGENERATED FILE - DO NOT EDIT */" > $@.tmp
371 REVISION="$$(LANG=C svnversion "$(top_srcdir)" 2>/dev/null || echo exported)" ; \
372 echo "const char psz_vlc_changeset[] = \"$$REVISION\";" >> $@.tmp
375 ###############################################################################
376 # Unit/regression test
377 ###############################################################################
386 dist_check_SCRIPTS = check_symbols
387 TESTS = $(check_PROGRAMS) $(dist_check_SCRIPTS)
389 CFLAGS_tests = `$(VLC_CONFIG) --cflags libvlc`
391 test_i18n_atof_SOURCES = test/i18n_atof.c text/charset.c
392 test_i18n_atof_LDADD = libvlc.la
393 test_i18n_atof_CFLAGS = $(CFLAGS_tests)
395 test_url_SOURCES = test/url.c
396 test_url_LDADD = libvlc.la
397 test_url_CFLAGS = $(CFLAGS_tests)
399 test_utf8_SOURCES = test/utf8.c
400 test_utf8_LDADD = libvlc.la
401 test_utf8_CFLAGS = $(CFLAGS_tests)
403 test_headers_SOURCES = test/headers.c
404 test_headers_CFLAGS = $(CFLAGS_tests)
406 test_control_SOURCES = control/testapi.c
407 test_control_LDADD = libvlc-control.la
408 test_control_CFLAGS = $(CFLAGS_tests)
411 for h in `echo $(dist_pkginclude_HEADERS) $(pkginclude_HEADERS) | sed -e s,\.\./include/,,g`; \
413 echo grep - "#include <$$h>" $(srcdir)/test/headers.c ; \
414 if ! grep -- "#include <$$h>" $(srcdir)/test/headers.c ; \
416 echo "Header $$h not included in test/headers.c!"; \
422 @echo "Generated source cannot be phony. Go away." >&2