| 1 | # |
| 2 | # This file is part of DisOrder. |
| 3 | # Copyright (C) 2006-2009 Richard Kettlewell |
| 4 | # |
| 5 | # This program is free software: you can redistribute it and/or modify |
| 6 | # it under the terms of the GNU General Public License as published by |
| 7 | # the Free Software Foundation, either version 3 of the License, or |
| 8 | # (at your option) any later version. |
| 9 | # |
| 10 | # This program is distributed in the hope that it will be useful, |
| 11 | # but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 12 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 13 | # GNU General Public License for more details. |
| 14 | # |
| 15 | # You should have received a copy of the GNU General Public License |
| 16 | # along with this program. If not, see <http://www.gnu.org/licenses/>. |
| 17 | # |
| 18 | |
| 19 | bin_PROGRAMS=disorder disorderfm disorder-playrtp |
| 20 | noinst_PROGRAMS=filename-bytes rtpmon resample |
| 21 | noinst_SCRIPTS=dump2wav |
| 22 | |
| 23 | AM_CPPFLAGS=-I${top_srcdir}/lib -I../lib |
| 24 | |
| 25 | disorder_SOURCES=disorder.c authorize.c authorize.h \ |
| 26 | ../lib/memgc.c |
| 27 | disorder_LDADD=$(LIBOBJS) ../lib/libdisorder.a \ |
| 28 | $(LIBGC) $(LIBGCRYPT) $(LIBPCRE) $(LIBICONV) $(LIBPTHREAD) |
| 29 | disorder_DEPENDENCIES=$(LIBOBJS) ../lib/libdisorder.a |
| 30 | |
| 31 | disorderfm_SOURCES=disorderfm.c \ |
| 32 | ../lib/memgc.c |
| 33 | disorderfm_LDADD=$(LIBOBJS) ../lib/libdisorder.a $(LIBGC) $(LIBICONV) |
| 34 | disorderfm_DEPENDENCIES=$(LIBOBJS) ../lib/libdisorder.a |
| 35 | |
| 36 | disorder_playrtp_SOURCES=playrtp.c playrtp.h playrtp-mem.c |
| 37 | disorder_playrtp_CFLAGS=$(PULSEAUDIO_CFLAGS) $(PULSEAUDIO_SIMPLE_CFLAGS) |
| 38 | disorder_playrtp_LDADD=$(LIBOBJS) ../lib/libdisorder.a \ |
| 39 | $(LIBASOUND) $(LIBPCRE) $(LIBICONV) $(LIBGCRYPT) $(COREAUDIO) \ |
| 40 | $(LIBPTHREAD) $(PULSEAUDIO_SIMPLE_LIBS) $(PULSEAUDIO_LIBS) -lm |
| 41 | disorder_playrtp_DEPENDENCIES=$(LIBOBJS) ../lib/libdisorder.a |
| 42 | |
| 43 | rtpmon_SOURCES=rtpmon.c |
| 44 | rtpmon_LDADD=$(LIBOBJS) ../lib/libdisorder.a |
| 45 | |
| 46 | filename_bytes_SOURCES=filename-bytes.c |
| 47 | |
| 48 | resample_SOURCES=resample.c |
| 49 | resample_LDADD=$(LIBOBJS) ../lib/libdisorder.a $(LIBSAMPLERATE) |
| 50 | |
| 51 | check: check-help check-completions |
| 52 | |
| 53 | # check everything has working --help and --version |
| 54 | check-help: all |
| 55 | ./disorder --version > /dev/null |
| 56 | ./disorder --help > /dev/null |
| 57 | ./disorder --help-commands > /dev/null |
| 58 | ./disorderfm --version > /dev/null |
| 59 | ./disorderfm --help > /dev/null |
| 60 | ./disorder-playrtp --version > /dev/null |
| 61 | ./disorder-playrtp --help > /dev/null |
| 62 | |
| 63 | # check that the command completions are up to date |
| 64 | check-completions: disorder |
| 65 | ./disorder --help-commands \ |
| 66 | | awk '/^ [a-z]/ { print $$1 }' \ |
| 67 | | sort > ,commands |
| 68 | ( set -e;completions() { \ |
| 69 | for x; do \ |
| 70 | case $$x in\ |
| 71 | quack ) ;;\ |
| 72 | [a-z]* ) echo $$x; ;;\ |
| 73 | esac;\ |
| 74 | done;\ |
| 75 | }; \ |
| 76 | complete() { if [ "$$7" = disorder ]; then completions $$6; fi }; \ |
| 77 | . ${top_srcdir}/scripts/completion.bash )\ |
| 78 | | sort > ,completions |
| 79 | diff -u ,commands ,completions |
| 80 | |
| 81 | CLEANFILES=,commands ,completions \ |
| 82 | *.gcda *.gcov *.gcno *.c.html index.html |
| 83 | |
| 84 | EXTRA_DIST=dump2wav |