1 ACLOCAL_AMFLAGS = -I m4
2 AUTOMAKE_OPTIONS = foreign 1.10 dist-bzip2 subdir-objects
4 AM_CPPFLAGS = -I$(srcdir)/src $(GLIB_CFLAGS)
6 AM_CPPFLAGS += -DSYSTEM_CONFIG_FILE_LOCATION='"$(sysconfdir)/mpd.conf"'
10 src_mpd_CFLAGS = $(AM_CFLAGS) $(MPD_CFLAGS)
11 src_mpd_CPPFLAGS = $(AM_CPPFLAGS) \
21 src_mpd_LDADD = $(MPD_LIBS) \
41 src/output_internal.h \
47 src/output_control.h \
50 src/output_command.h \
51 src/filter_internal.h \
54 src/filter_registry.h \
55 src/filter/autoconvert_filter_plugin.h \
56 src/filter/chain_filter_plugin.h \
57 src/filter/convert_filter_plugin.h \
58 src/filter/replay_gain_filter_plugin.h \
59 src/filter/volume_filter_plugin.h \
66 src/decoder_thread.h \
67 src/decoder_control.h \
68 src/decoder_plugin.h \
69 src/decoder_command.h \
70 src/decoder_buffer.h \
72 src/decoder_plugin.h \
73 src/decoder_internal.h \
75 src/directory_save.h \
76 src/directory_print.h \
78 src/encoder_plugin.h \
86 src/update_internal.h \
87 src/inotify_source.h \
89 src/inotify_update.h \
94 src/decoder/flac_compat.h \
95 src/decoder/flac_metadata.h \
96 src/decoder/flac_pcm.h \
97 src/decoder/_flac_common.h \
98 src/decoder/_ogg_common.h \
101 src/input_registry.h \
103 src/input/file_input_plugin.h \
104 src/input/curl_input_plugin.h \
105 src/input/rewind_input_plugin.h \
106 src/input/mms_input_plugin.h \
108 src/text_input_stream.h \
112 src/client_internal.h \
119 src/mixer_control.h \
124 src/mixer/software_mixer_plugin.h \
125 src/mixer/pulse_mixer_plugin.h \
127 src/AudioCompress/config.h \
128 src/AudioCompress/compress.h \
134 src/output/httpd_client.h \
135 src/output/httpd_internal.h \
136 src/output/pulse_output_plugin.h \
147 src/pcm_resample_internal.h \
152 src/player_thread.h \
153 src/player_control.h \
155 src/playlist_internal.h \
156 src/playlist_print.h \
157 src/playlist_save.h \
158 src/playlist_state.h \
159 src/playlist_plugin.h \
160 src/playlist_list.h \
161 src/playlist_mapper.h \
162 src/playlist_song.h \
163 src/playlist_queue.h \
164 src/playlist/extm3u_playlist_plugin.h \
165 src/playlist/m3u_playlist_plugin.h \
166 src/playlist/pls_playlist_plugin.h \
167 src/playlist/xspf_playlist_plugin.h \
168 src/playlist/asx_playlist_plugin.h \
169 src/playlist/lastfm_playlist_plugin.h \
170 src/playlist/cue_playlist_plugin.h \
171 src/playlist/flac_playlist_plugin.h \
178 src/replay_gain_config.h \
179 src/replay_gain_info.h \
190 src/sticker_print.h \
203 src/zeroconf.h src/zeroconf-internal.h \
205 src/stored_playlist.h \
208 src/archive_internal.h \
210 src/archive_plugin.h \
211 src/archive/bz2_archive_plugin.h \
212 src/archive/iso9660_archive_plugin.h \
213 src/archive/zzip_archive_plugin.h \
214 src/input/archive_input_plugin.h \
225 $(OUTPUT_API_SRC) $(OUTPUT_SRC) \
226 $(MIXER_API_SRC) $(MIXER_SRC) \
239 src/decoder_thread.c \
240 src/decoder_control.c \
242 src/decoder_internal.c \
243 src/decoder_print.c \
245 src/directory_save.c \
246 src/directory_print.c \
252 src/filter_config.c \
253 src/filter_plugin.c \
254 src/filter_registry.c \
258 src/update_remove.c \
261 src/client_expire.c \
262 src/client_global.c \
266 src/client_process.c \
275 src/AudioCompress/compress.c \
290 src/pcm_resample_fallback.c \
293 src/player_thread.c \
294 src/player_control.c \
296 src/playlist_global.c \
297 src/playlist_control.c \
298 src/playlist_edit.c \
299 src/playlist_print.c \
300 src/playlist_save.c \
301 src/playlist_mapper.c \
302 src/playlist_song.c \
303 src/playlist_state.c \
304 src/playlist_queue.c \
308 src/replay_gain_config.c \
309 src/replay_gain_info.c \
325 src/text_input_stream.c \
331 src/stored_playlist.c \
336 src/inotify_source.c \
337 src/inotify_queue.c \
344 src/sticker_print.c \
353 if HAVE_LIBSAMPLERATE
354 src_mpd_SOURCES += src/pcm_resample_libsamplerate.c
370 ARCHIVE_SRC += src/archive/bz2_archive_plugin.c
374 ARCHIVE_SRC += src/archive/zzip_archive_plugin.c
378 ARCHIVE_SRC += src/archive/iso9660_archive_plugin.c
385 src/archive_plugin.c \
386 src/input/archive_input_plugin.c
401 TAG_SRC += src/tag_id3.c \
402 src/riff.c src/aiff.c
408 $(VORBIS_CFLAGS) $(TREMOR_CFLAGS) \
409 $(patsubst -I%/FLAC,-I%,$(FLAC_CFLAGS)) \
411 $(AUDIOFILE_CFLAGS) \
412 $(LIBMIKMOD_CFLAGS) \
416 $(FLUIDSYNTH_CFLAGS) \
425 $(VORBIS_LIBS) $(TREMOR_LIBS) \
428 $(AUDIOFILE_LIBS) $(LIBMIKMOD_LIBS) \
442 src/decoder_buffer.c \
443 src/decoder_plugin.c \
447 DECODER_SRC += src/decoder/mad_decoder_plugin.c
451 DECODER_SRC += src/decoder/mpg123_decoder_plugin.c
455 DECODER_SRC += src/decoder/mpcdec_decoder_plugin.c
459 DECODER_SRC += src/decoder/wavpack_decoder_plugin.c
463 DECODER_SRC += src/decoder/faad_decoder_plugin.c
467 DECODER_SRC += src/decoder/mp4ff_decoder_plugin.c
471 DECODER_SRC += src/decoder/_ogg_common.c
476 src/decoder/flac_metadata.c \
477 src/decoder/flac_pcm.c \
478 src/decoder/_flac_common.c
481 if ENABLE_VORBIS_DECODER
482 DECODER_SRC += src/decoder/vorbis_decoder_plugin.c
486 DECODER_SRC += src/decoder/flac_decoder_plugin.c
490 DECODER_SRC += src/decoder/oggflac_decoder_plugin.c
494 DECODER_SRC += src/decoder/audiofile_decoder_plugin.c
497 if ENABLE_MIKMOD_DECODER
498 DECODER_SRC += src/decoder/mikmod_decoder_plugin.c
502 DECODER_SRC += src/decoder/modplug_decoder_plugin.c
506 DECODER_SRC += src/decoder/sidplay_decoder_plugin.cxx
510 DECODER_SRC += src/decoder/fluidsynth_decoder_plugin.c
514 DECODER_SRC += src/decoder/wildmidi_decoder_plugin.c
518 DECODER_SRC += src/decoder/ffmpeg_decoder_plugin.c
522 DECODER_SRC += src/decoder/sndfile_decoder_plugin.c
526 DECODER_SRC += src/decoder/gme_decoder_plugin.c
534 $(patsubst -I%/FLAC,-I%,$(FLAC_CFLAGS)) \
546 ENCODER_SRC += src/encoder_list.c
547 ENCODER_SRC += src/encoder/null_encoder.c
549 if ENABLE_WAVE_ENCODER
550 ENCODER_SRC += src/encoder/wave_encoder.c
553 if ENABLE_VORBIS_ENCODER
554 ENCODER_SRC += src/encoder/vorbis_encoder.c
557 if ENABLE_LAME_ENCODER
558 ENCODER_SRC += src/encoder/lame_encoder.c
561 if ENABLE_TWOLAME_ENCODER
562 ENCODER_SRC += src/encoder/twolame_encoder.c
565 if ENABLE_FLAC_ENCODER
566 ENCODER_SRC += src/encoder/flac_encoder.c
572 src_mpd_SOURCES += src/zeroconf.c
575 src_mpd_SOURCES += src/zeroconf-avahi.c
579 src_mpd_SOURCES += src/zeroconf-bonjour.c
584 DECODER_SRC += src/cue/cue_tag.c
601 src/input_registry.c \
603 src/input/rewind_input_plugin.c \
604 src/input/file_input_plugin.c
607 INPUT_SRC += src/input/curl_input_plugin.c \
612 INPUT_SRC += src/input/mms_input_plugin.c
635 src/output_thread.c \
636 src/output_control.c \
639 src/output_command.c \
643 src/output/null_plugin.c
646 src/mixer_control.c \
652 src/mixer/software_mixer_plugin.c
655 OUTPUT_SRC += src/output/alsa_plugin.c
656 MIXER_SRC += src/mixer/alsa_mixer_plugin.c
660 OUTPUT_SRC += src/output/ao_plugin.c
664 OUTPUT_SRC += src/output/fifo_output_plugin.c
667 if ENABLE_PIPE_OUTPUT
668 OUTPUT_SRC += src/output/pipe_output_plugin.c
672 OUTPUT_SRC += src/output/jack_output_plugin.c
676 OUTPUT_SRC += src/output/mvp_plugin.c
680 OUTPUT_SRC += src/output/oss_plugin.c
681 MIXER_SRC += src/mixer/oss_mixer_plugin.c
685 OUTPUT_SRC += src/output/openal_plugin.c
689 OUTPUT_SRC += src/output/osx_plugin.c
693 OUTPUT_SRC += src/output/pulse_output_plugin.c
694 MIXER_SRC += src/mixer/pulse_mixer_plugin.c
698 OUTPUT_SRC += src/output/shout_plugin.c
701 if ENABLE_RECORDER_OUTPUT
702 OUTPUT_SRC += src/output/recorder_output_plugin.c
705 if ENABLE_HTTPD_OUTPUT
708 src/output/httpd_client.c \
709 src/output/httpd_output_plugin.c
712 if ENABLE_SOLARIS_OUTPUT
713 OUTPUT_SRC += src/output/solaris_output_plugin.c
722 src/playlist/extm3u_playlist_plugin.c \
723 src/playlist/m3u_playlist_plugin.c \
724 src/playlist/pls_playlist_plugin.c \
725 src/playlist/xspf_playlist_plugin.c \
726 src/playlist/asx_playlist_plugin.c \
730 PLAYLIST_SRC += src/playlist/lastfm_playlist_plugin.c
734 PLAYLIST_SRC += src/playlist/cue_playlist_plugin.c
738 PLAYLIST_SRC += src/playlist/flac_playlist_plugin.c
747 src/filter/null_filter_plugin.c \
748 src/filter/chain_filter_plugin.c \
749 src/filter/autoconvert_filter_plugin.c \
750 src/filter/convert_filter_plugin.c \
751 src/filter/route_filter_plugin.c \
752 src/filter/normalize_filter_plugin.c \
753 src/filter/replay_gain_filter_plugin.c \
754 src/filter/volume_filter_plugin.c
758 # Sparse code analysis
760 # sparse is a semantic parser
761 # URL: git://www.kernel.org/pub/scm/devel/sparse/sparse.git
766 SPARSE_CPPFLAGS = $(DEFAULT_INCLUDES) \
767 -I$(shell $(CC) -print-file-name=include) \
768 -I$(shell $(CC) -print-file-name=include-fixed)
769 SPARSE_CPPFLAGS += -D__SCHAR_MAX__=127 -D__SHRT_MAX__=32767 \
770 -D__INT_MAX__=2147483647 -D__LONG_MAX__=2147483647
772 $(SPARSE) -I. $(src_mpd_CFLAGS) $(src_mpd_CPPFLAGS) $(SPARSE_FLAGS) $(SPARSE_CPPFLAGS) $(filter-out %.cxx,$(src_mpd_SOURCES))
798 test_read_conf_CPPFLAGS = $(AM_CPPFLAGS) \
800 test_read_conf_LDADD = $(MPD_LIBS) \
802 test_read_conf_SOURCES = test/read_conf.c \
803 src/conf.c src/tokenizer.c src/utils.c
805 test_run_input_CPPFLAGS = $(AM_CPPFLAGS) \
808 test_run_input_LDADD = $(MPD_LIBS) \
812 test_run_input_SOURCES = test/run_input.c \
813 src/conf.c src/tokenizer.c src/utils.c \
814 src/tag.c src/tag_pool.c src/tag_save.c \
819 test_dump_playlist_CPPFLAGS = $(AM_CPPFLAGS) \
821 $(patsubst -I%/FLAC,-I%,$(FLAC_CFLAGS)) \
824 test_dump_playlist_LDADD = $(MPD_LIBS) \
830 test_dump_playlist_SOURCES = test/dump_playlist.c \
831 src/conf.c src/tokenizer.c src/utils.c \
833 src/song.c src/tag.c src/tag_pool.c src/tag_save.c \
834 src/text_input_stream.c src/fifo_buffer.c \
841 test_dump_playlist_SOURCES += src/cue/cue_tag.c
845 test_dump_playlist_SOURCES += \
846 src/replay_gain_info.c \
847 src/decoder/flac_metadata.c
850 test_run_decoder_CPPFLAGS = $(AM_CPPFLAGS) \
853 $(INPUT_CFLAGS) $(DECODER_CFLAGS)
854 test_run_decoder_LDADD = $(MPD_LIBS) \
857 $(INPUT_LIBS) $(DECODER_LIBS) \
859 test_run_decoder_SOURCES = test/run_decoder.c \
860 src/conf.c src/tokenizer.c src/utils.c src/log.c \
861 src/tag.c src/tag_pool.c \
862 src/replay_gain_info.c \
873 test_read_tags_CPPFLAGS = $(AM_CPPFLAGS) \
876 $(INPUT_CFLAGS) $(DECODER_CFLAGS)
877 test_read_tags_LDADD = $(MPD_LIBS) \
880 $(INPUT_LIBS) $(DECODER_LIBS) \
882 test_read_tags_SOURCES = test/read_tags.c \
883 src/conf.c src/tokenizer.c src/utils.c src/log.c \
884 src/tag.c src/tag_pool.c \
885 src/replay_gain_info.c \
895 test_run_filter_CPPFLAGS = $(AM_CPPFLAGS)
896 test_run_filter_LDADD = $(MPD_LIBS) \
899 test_run_filter_SOURCES = test/run_filter.c \
900 src/filter_plugin.c \
901 src/filter_registry.c \
902 src/conf.c src/tokenizer.c src/utils.c \
903 src/pcm_volume.c src/pcm_convert.c src/pcm_byteswap.c \
904 src/pcm_format.c src/pcm_channels.c src/pcm_dither.c \
906 src/pcm_resample.c src/pcm_resample_fallback.c \
910 src/replay_gain_config.c \
911 src/replay_gain_info.c \
912 src/AudioCompress/compress.c \
915 if HAVE_LIBSAMPLERATE
916 test_run_filter_SOURCES += src/pcm_resample_libsamplerate.c
920 noinst_PROGRAMS += test/run_encoder
921 test_run_encoder_SOURCES = test/run_encoder.c \
922 src/conf.c src/tokenizer.c \
924 src/tag.c src/tag_pool.c \
929 test_run_encoder_LDADD = $(MPD_LIBS) \
934 test_software_volume_SOURCES = test/software_volume.c \
938 test_software_volume_LDADD = \
941 test_run_normalize_SOURCES = test/run_normalize.c \
944 src/AudioCompress/compress.c
945 test_run_normalize_LDADD = \
948 test_run_convert_SOURCES = test/run_convert.c \
959 src/pcm_resample_fallback.c \
961 test_run_convert_CPPFLAGS = $(AM_CPPFLAGS) $(SAMPLERATE_CFLAGS)
962 test_run_convert_LDADD = \
966 if HAVE_LIBSAMPLERATE
967 test_run_convert_SOURCES += src/pcm_resample_libsamplerate.c
970 test_run_output_CPPFLAGS = $(AM_CPPFLAGS) \
973 test_run_output_LDADD = $(MPD_LIBS) \
977 test_run_output_SOURCES = test/run_output.c \
978 src/conf.c src/tokenizer.c src/utils.c src/log.c \
983 src/tag.c src/tag_pool.c \
987 src/output_init.c src/output_list.c \
990 src/mixer_control.c \
993 src/filter_plugin.c src/filter/chain_filter_plugin.c \
994 src/filter_config.c \
995 src/filter/autoconvert_filter_plugin.c \
996 src/filter/convert_filter_plugin.c \
997 src/filter/replay_gain_filter_plugin.c \
998 src/filter/normalize_filter_plugin.c \
999 src/filter/volume_filter_plugin.c \
1001 src/AudioCompress/compress.c \
1002 src/replay_gain_info.c \
1003 src/replay_gain_config.c \
1007 test_read_mixer_CPPFLAGS = $(AM_CPPFLAGS) \
1009 test_read_mixer_LDADD = $(MPD_LIBS) \
1012 test_read_mixer_SOURCES = test/read_mixer.c \
1013 src/conf.c src/tokenizer.c src/utils.c src/log.c \
1014 src/mixer_control.c src/mixer_api.c \
1015 src/filter_plugin.c \
1016 src/filter/volume_filter_plugin.c \
1020 if ENABLE_BZIP2_TEST
1021 TESTS += test/test_archive_bzip2.sh
1025 TESTS += test/test_archive_zzip.sh
1028 if ENABLE_ISO9660_TEST
1029 TESTS += test/test_archive_iso9660.sh
1039 man_MANS = doc/mpd.1 doc/mpd.conf.5
1040 doc_DATA = AUTHORS COPYING NEWS README UPGRADING doc/mpdconf.example
1042 DOCBOOK_FILES = doc/protocol.xml doc/user.xml doc/developer.xml
1044 if ENABLE_DOCUMENTATION
1045 protocoldir = $(docdir)/protocol
1046 protocol_DATA = $(wildcard doc/protocol/*.html)
1048 userdir = $(docdir)/user
1049 user_DATA = $(wildcard doc/user/*.html)
1051 developerdir = $(docdir)/developer
1052 developer_DATA = $(wildcard doc/developer/*.html)
1056 DOCBOOK_HTML = $(patsubst %.xml,%/index.html,$(DOCBOOK_FILES))
1058 $(DOCBOOK_HTML): %/index.html: %.xml
1059 $(XMLTO) -o $(@D) --stringparam chunker.output.encoding=utf-8 html $<
1067 doc/api/html/index.html: doc/doxygen.conf
1071 all-local: $(DOCBOOK_HTML) doc/api/html/index.html
1074 rm -rf $(patsubst %.xml,%,$(DOCBOOK_FILES))
1077 install-data-local: doc/api/html/index.html
1078 $(mkinstalldirs) $(DESTDIR)$(docdir)/api/html
1079 $(INSTALL_DATA) -c -m 644 doc/api/html/*.html doc/api/html/*.css \
1080 doc/api/html/*.png doc/api/html/*.gif \
1081 $(DESTDIR)$(docdir)/api/html
1083 upload: $(DOCBOOK_HTML) doc/api/html/index.html
1084 rsync -vpruz --delete doc/ cirrus@www.musicpd.org:/var/www/musicpd.org/www/doc/ \
1085 --chmod=Dug+rwx,Do+rx,Fug+rw,Fo+r \
1086 --include=protocol --include=protocol/** \
1087 --include=user --include=user/** \
1088 --include=developer --include=developer/** \
1089 --include=api --include=api/** \
1099 EXTRA_DIST = $(doc_DATA) autogen.sh \
1100 $(wildcard scripts/*.sh) \
1101 $(man_MANS) $(DOCBOOK_FILES) doc/mpdconf.example doc/doxygen.conf