chiark / gitweb /
Assume initial digits in a track name are a sort key even without the
[disorder] / server / Makefile.am
... / ...
CommitLineData
1#
2# This file is part of DisOrder.
3# Copyright (C) 2004-2008 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 2 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, but
11# WITHOUT ANY WARRANTY; without even the implied warranty of
12# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13# 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, write to the Free Software
17# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
18# USA
19#
20
21sbin_PROGRAMS=disorderd disorder-deadlock disorder-rescan disorder-dump \
22 disorder-speaker disorder-decode disorder-normalize \
23 disorder-stats disorder-dbupgrade disorder-choose
24noinst_PROGRAMS=trackname
25
26AM_CPPFLAGS=-I${top_srcdir}/lib -I../lib
27
28disorderd_SOURCES=disorderd.c api.c api-server.c daemonize.c play.c \
29 server.c server-queue.c queue-ops.c state.c plugin.c \
30 schedule.c exports.c ../lib/memgc.c disorder-server.h
31disorderd_LDADD=$(LIBOBJS) ../lib/libdisorder.a \
32 $(LIBPCRE) $(LIBDB) $(LIBAO) $(LIBGC) $(LIBGCRYPT) $(LIBICONV) \
33 $(LIBASOUND) $(COREAUDIO)
34disorderd_LDFLAGS=-export-dynamic
35disorderd_DEPENDENCIES=../lib/libdisorder.a
36
37disorder_deadlock_SOURCES=deadlock.c disorder-server.h
38disorder_deadlock_LDADD=$(LIBOBJS) ../lib/libdisorder.a \
39 $(LIBDB) $(LIBPCRE) $(LIBICONV) $(LIBGCRYPT)
40disorder_deadlock_DEPENDENCIES=../lib/libdisorder.a
41
42disorder_speaker_SOURCES=speaker.c speaker.h \
43 speaker-command.c \
44 speaker-network.c \
45 speaker-coreaudio.c \
46 speaker-oss.c \
47 speaker-alsa.c
48disorder_speaker_LDADD=$(LIBOBJS) ../lib/libdisorder.a \
49 $(LIBASOUND) $(LIBPCRE) $(LIBICONV) $(LIBGCRYPT) $(COREAUDIO)
50disorder_speaker_DEPENDENCIES=../lib/libdisorder.a
51
52disorder_decode_SOURCES=decode.c disorder-server.h
53disorder_decode_LDADD=$(LIBOBJS) ../lib/libdisorder.a \
54 $(LIBMAD) $(LIBVORBISFILE) $(LIBFLAC)
55disorder_decode_DEPENDENCIES=../lib/libdisorder.a
56
57disorder_normalize_SOURCES=normalize.c disorder-server.h
58disorder_normalize_LDADD=$(LIBOBJS) ../lib/libdisorder.a \
59 $(LIBPCRE) $(LIBICONV) $(LIBGCRYPT)
60disorder_normalize_DEPENDENCIES=../lib/libdisorder.a
61
62disorder_rescan_SOURCES=rescan.c plugin.c api.c api-server.c exports.c \
63 ../lib/memgc.c disorder-server.h
64disorder_rescan_LDADD=$(LIBOBJS) ../lib/libdisorder.a \
65 $(LIBDB) $(LIBGC) $(LIBPCRE) $(LIBICONV) $(LIBGCRYPT)
66disorder_rescan_LDFLAGS=-export-dynamic
67disorder_rescan_DEPENDENCIES=../lib/libdisorder.a
68
69disorder_choose_SOURCES=choose.c server-queue.c ../lib/memgc.c \
70 disorder-server.h
71disorder_choose_LDADD=$(LIBOBJS) ../lib/libdisorder.a \
72 $(LIBDB) $(LIBGC) $(LIBPCRE) $(LIBGCRYPT)
73disorder_choose_LDFLAGS=-export-dynamic
74disorder_choose_DEPENDENCIES=../lib/libdisorder.a
75
76disorder_stats_SOURCES=stats.c disorder-server.h
77disorder_stats_LDADD=$(LIBOBJS) ../lib/libdisorder.a \
78 $(LIBDB) $(LIBPCRE) $(LIBICONV) $(LIBGCRYPT)
79disorder_stats_DEPENDENCIES=../lib/libdisorder.a
80
81disorder_dump_SOURCES=dump.c disorder-server.h ../lib/memgc.c
82disorder_dump_LDADD=$(LIBOBJS) ../lib/libdisorder.a \
83 $(LIBPCRE) $(LIBDB) $(LIBICONV) $(LIBGC) $(LIBGCRYPT)
84disorder_dump_DEPENDENCIES=$(LIBOBJS) ../lib/libdisorder.a
85
86disorder_dbupgrade_SOURCES=dbupgrade.c ../lib/memgc.c disorder-server.h
87disorder_dbupgrade_LDADD=$(LIBOBJS) ../lib/libdisorder.a \
88 $(LIBDB) $(LIBGC) $(LIBPCRE) $(LIBICONV) $(LIBGCRYPT)
89disorder_dbupgrade_DEPENDENCIES=../lib/libdisorder.a
90
91trackname_SOURCES=trackname.c disorder-server.h
92trackname_LDADD=../lib/libdisorder.a $(LIBPCRE) $(LIBICONV) $(LIBGCRYPT)
93trackname_DEPENDENCIES=../lib/libdisorder.a
94
95install-exec-hook:
96 $(LIBTOOL) --mode=finish $(DESTDIR)$(libdir)
97
98check: check-help check-decode
99
100# check everything has working --help and --version
101check-help: all
102 ./disorderd --help > /dev/null
103 ./disorderd --version > /dev/null
104 ./disorder-dump --help > /dev/null
105 ./disorder-dump --version > /dev/null
106 ./disorder-deadlock --help > /dev/null
107 ./disorder-deadlock --version > /dev/null
108 ./trackname --help > /dev/null
109 ./trackname --version > /dev/null
110 ./disorder-speaker --help > /dev/null
111 ./disorder-speaker --version > /dev/null
112 ./disorder-decode --help > /dev/null
113 ./disorder-decode --version > /dev/null
114 ./disorder-normalize --help > /dev/null
115 ./disorder-normalize --version > /dev/null
116 ./disorder-stats --help > /dev/null
117 ./disorder-stats --version > /dev/null
118 ./disorder-dbupgrade --help > /dev/null
119 ./disorder-dbupgrade --version > /dev/null
120 ./disorder-rescan --help > /dev/null
121 ./disorder-rescan --version > /dev/null
122 ./disorder-choose --help > /dev/null
123 ./disorder-choose --version > /dev/null
124
125# My sox doesn't know MP3 or FLAC unfortunately
126check-decode: disorder-decode disorder-normalize
127 echo "speaker_backend network" > config
128 echo "broadcast 127.255.255.255 discard" > config
129 ./disorder-decode ${top_srcdir}/sounds/scratch.ogg | \
130 ./disorder-normalize --config config > decoded.raw
131 oggdec -b 16 -e 1 -R -s 1 -o oggdec.raw ${top_srcdir}/sounds/scratch.ogg
132 cmp decoded.raw oggdec.raw
133 sox ${top_srcdir}/sounds/scratch.ogg scratch.wav
134 ./disorder-decode scratch.wav | \
135 ./disorder-normalize --config config > decoded.raw
136 ls -l *.raw
137 cmp decoded.raw oggdec.raw
138 rm -f scratch.wav config decoded.raw oggdec.raw
139
140EXTRA_DIST=README.dbversions