2 # This file is part of DisOrder.
3 # Copyright (C) 2004-2008 Richard Kettlewell
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.
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.
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
21 noinst_LIBRARIES=libdisorder.a
22 include_HEADERS=disorder.h
27 TRACKDB=trackdb-stub.c
30 libdisorder_a_SOURCES=charset.c charset.h \
34 authhash.c authhash.h \
41 client-common.c client-common.h \
42 configuration.c configuration.h \
44 dateparse.c dateparse.h xgetdate.c \
48 eventdist.c eventdist.h \
50 eventlog.c eventlog.h \
51 filepart.c filepart.h \
55 hostname.c hostname.h \
57 inputline.c inputline.h \
59 log.c log.h log-impl.h \
61 macros.c macros-builtin.c macros.h \
62 mem.c mem.h mem-impl.h \
64 mixer.c mixer.h mixer-oss.c mixer-alsa.c \
66 asprintf.c fprintf.c snprintf.c \
70 rights.c queue-rights.c rights.h \
72 selection.c selection.h \
73 sendmail.c sendmail.h \
76 speaker-protocol.c speaker-protocol.h \
78 syscalls.c syscalls.h \
82 $(TRACKDB) trackdb.h trackdb-int.h \
83 trackname.c trackorder.c trackname.h \
96 version-string: ../config.status ${top_srcdir}/scripts/make-version-string
97 CC="${CC}" ${top_srcdir}/scripts/make-version-string > $@.new
98 @if cmp $@.new $@; then \
99 echo rm -f $@.new; rm -f $@.new; else \
100 echo mv $@.new $@; mv $@.new $@; fi
102 versionstring.h: version-string ${top_srcdir}/scripts/text2c
103 ${top_srcdir}/scripts/text2c -extern disorder_version_string \
104 version-string > $@.new
105 @if cmp $@.new $@; then \
106 echo rm -f $@.new; rm -f $@.new; else \
107 echo mv $@.new $@; mv $@.new $@; fi
109 definitions.h: Makefile
111 echo "#define PKGLIBDIR \"${pkglibdir}\"" > $@.new
112 echo "#define PKGCONFDIR \"${sysconfdir}/\"PACKAGE" >> $@.new
113 echo "#define PKGSTATEDIR \"${localstatedir}/\"PACKAGE" >> $@.new
114 echo "#define PKGDATADIR \"${pkgdatadir}/\"" >> $@.new
115 echo "#define SBINDIR \"${sbindir}/\"" >> $@.new
116 echo "#define BINDIR \"${bindir}/\"" >> $@.new
117 echo "#define FINKBINDIR \"${finkbindir}/\"" >> $@.new
118 echo "#define SENDMAIL \"${SENDMAIL}\"" >> $@.new
119 @if cmp $@.new $@; then \
120 echo rm -f $@.new; rm -f $@.new; else \
121 echo mv $@.new $@; mv $@.new $@; fi
122 defs.o: definitions.h versionstring.h
123 defs.lo: definitions.h versionstring.h
126 cd ${srcdir} && ${top_srcdir}/scripts/make-unidata
129 $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) -c $< > $@.new
132 CLEANFILES=definitions.h definitions.h.new version-string versionstring.h \
135 EXTRA_DIST=trackdb.c trackdb-stub.c