| 1 | # |
| 2 | # This file is part of DisOrder. |
| 3 | # Copyright (C) 2004-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 | noinst_LIBRARIES=libdisorder.a |
| 20 | include_HEADERS=disorder.h |
| 21 | |
| 22 | if SERVER |
| 23 | TRACKDB=trackdb.c trackdb-playlists.c |
| 24 | else |
| 25 | TRACKDB=trackdb-stub.c |
| 26 | endif |
| 27 | |
| 28 | libdisorder_a_SOURCES=charset.c charset.h \ |
| 29 | addr.c addr.h \ |
| 30 | arcfour.c arcfour.h \ |
| 31 | authhash.c authhash.h \ |
| 32 | basen.c basen.h \ |
| 33 | base64.c base64.h \ |
| 34 | bits.c bits.h \ |
| 35 | byte-order.h \ |
| 36 | cache.c cache.h \ |
| 37 | cgi.c cgi.h \ |
| 38 | client.c client.h \ |
| 39 | client-common.c client-common.h \ |
| 40 | configuration.c configuration.h \ |
| 41 | cookies.c cookies.h \ |
| 42 | coreaudio.c coreaudio.h \ |
| 43 | dateparse.c dateparse.h xgetdate.c \ |
| 44 | defs.c defs.h \ |
| 45 | eclient.c eclient.h \ |
| 46 | email.c \ |
| 47 | eventdist.c eventdist.h \ |
| 48 | event.c event.h \ |
| 49 | eventlog.c eventlog.h \ |
| 50 | filepart.c filepart.h \ |
| 51 | hash.c hash.h \ |
| 52 | heap.h \ |
| 53 | hex.c hex.h \ |
| 54 | hostname.c hostname.h \ |
| 55 | ifreq.c ifreq.h \ |
| 56 | inputline.c inputline.h \ |
| 57 | kvp.c kvp.h \ |
| 58 | log.c log.h \ |
| 59 | logfd.c logfd.h \ |
| 60 | macros.c macros-builtin.c macros.h \ |
| 61 | mem.c mem.h \ |
| 62 | mime.h mime.c \ |
| 63 | printf.c printf.h \ |
| 64 | asprintf.c fprintf.c snprintf.c \ |
| 65 | queue.c queue.h \ |
| 66 | random.c random.h \ |
| 67 | regsub.c regsub.h \ |
| 68 | resample.c resample.h \ |
| 69 | rights.c queue-rights.c rights.h \ |
| 70 | rtp.h \ |
| 71 | selection.c selection.h \ |
| 72 | sendmail.c sendmail.h \ |
| 73 | signame.c signame.h \ |
| 74 | sink.c sink.h \ |
| 75 | speaker-protocol.c speaker-protocol.h \ |
| 76 | split.c split.h \ |
| 77 | strptime.c strptime.h \ |
| 78 | syscalls.c syscalls.h \ |
| 79 | common.h \ |
| 80 | table.c table.h \ |
| 81 | timeval.h \ |
| 82 | $(TRACKDB) trackdb.h trackdb-int.h \ |
| 83 | trackname.c trackorder.c trackname.h \ |
| 84 | tracksort.c \ |
| 85 | uaudio.c uaudio-thread.c uaudio.h uaudio-apis.c \ |
| 86 | uaudio-oss.c uaudio-alsa.c \ |
| 87 | uaudio-coreaudio.c \ |
| 88 | uaudio-rtp.c uaudio-command.c uaudio-schedule.c \ |
| 89 | url.h url.c \ |
| 90 | user.h user.c \ |
| 91 | unicode.h unicode.c \ |
| 92 | unidata.h unidata.c \ |
| 93 | vacopy.h \ |
| 94 | validity.c validity.h \ |
| 95 | vector.c vector.h \ |
| 96 | version.c version.h \ |
| 97 | wav.h wav.c \ |
| 98 | wstat.c wstat.h \ |
| 99 | disorder.h |
| 100 | |
| 101 | version-string: ../config.status ${top_srcdir}/scripts/make-version-string |
| 102 | CC="${CC}" ${top_srcdir}/scripts/make-version-string > $@.new |
| 103 | @if cmp $@.new $@; then \ |
| 104 | echo rm -f $@.new; rm -f $@.new; else \ |
| 105 | echo mv $@.new $@; mv $@.new $@; fi |
| 106 | |
| 107 | versionstring.h: version-string ${top_srcdir}/scripts/text2c |
| 108 | ${top_srcdir}/scripts/text2c -extern disorder_version_string \ |
| 109 | version-string > $@.new |
| 110 | @if cmp $@.new $@; then \ |
| 111 | echo rm -f $@.new; rm -f $@.new; else \ |
| 112 | echo mv $@.new $@; mv $@.new $@; fi |
| 113 | |
| 114 | definitions.h: Makefile |
| 115 | rm -f $@.new |
| 116 | echo "/** @file lib/definitions.h" >> $@.new |
| 117 | echo " * @brief Definitions exported from makefile" >> $@.new |
| 118 | echo " *" >> $@.new |
| 119 | echo " * DO NOT EDIT." >> $@.new |
| 120 | echo " */" >> $@.new |
| 121 | echo "#define PKGLIBDIR \"${pkglibdir}\"" >> $@.new |
| 122 | echo "#define PKGCONFDIR \"${sysconfdir}/\"PACKAGE" >> $@.new |
| 123 | echo "#define PKGSTATEDIR \"${localstatedir}/\"PACKAGE" >> $@.new |
| 124 | echo "#define PKGDATADIR \"${pkgdatadir}/\"" >> $@.new |
| 125 | echo "#define DOCHTMLDIR \"${dochtmldir}\"" >> $@.new |
| 126 | echo "#define SBINDIR \"${sbindir}/\"" >> $@.new |
| 127 | echo "#define BINDIR \"${bindir}/\"" >> $@.new |
| 128 | echo "#define FINKBINDIR \"${finkbindir}/\"" >> $@.new |
| 129 | echo "#define SENDMAIL \"${SENDMAIL}\"" >> $@.new |
| 130 | @if cmp $@.new $@; then \ |
| 131 | echo rm -f $@.new; rm -f $@.new; else \ |
| 132 | echo mv $@.new $@; mv $@.new $@; fi |
| 133 | defs.o: definitions.h versionstring.h |
| 134 | defs.lo: definitions.h versionstring.h |
| 135 | |
| 136 | rebuild-unicode: |
| 137 | cd ${srcdir} && ${top_srcdir}/scripts/make-unidata |
| 138 | |
| 139 | %.i: %.c |
| 140 | $(CPP) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) -c $< > $@.new |
| 141 | mv $@.new $@ |
| 142 | |
| 143 | CLEANFILES=definitions.h definitions.h.new version-string versionstring.h \ |
| 144 | *.gcda *.gcov *.gcno *.c.html index.html |
| 145 | |
| 146 | EXTRA_DIST=trackdb.c trackdb-stub.c |