comparison src/audacious/Makefile @ 3535:9ddf21ab5c84 trunk

Transit to Mk2.
author William Pitcock <nenolod@atheme.org>
date Mon, 17 Sep 2007 13:10:19 -0500
parents 87003549ac36
children 66c6a8a79034
comparison
equal deleted inserted replaced
3534:10990786a090 3535:9ddf21ab5c84
1 include ../../mk/rules.mk 1 include ../../extra.mk
2 include ../../mk/init.mk
3 include ../../mk/objective.mk
4 2
5 SUBDIRS = $(INTL_OBJECTIVE) glade images ui 3 SUBDIRS = $(INTL_OBJECTIVE) glade images ui
6 4
7 OBJECTIVE_BINS = audacious 5 PROG = audacious
8 6
9 LDFLAGS += $(AUDLDFLAGS) 7 LDFLAGS += $(AUDLDFLAGS)
10 8
11 LDADD = \ 9 INCLUDES = \
12 $(LIBINTL) \
13 $(samplerate_LIBS) \
14 $(CHARDET_LIBS) \
15 $(GTK_LIBS) \
16 $(DBUS_LIBS) \
17 $(MOWGLI_LIBS) \
18 $(LIBMCS_LIBS) \
19 $(LIBGLADE_LIBS) \
20 $(REGEX_LIBS)
21
22 CFLAGS += \
23 $(MOWGLI_CFLAGS) \
24 $(GTK_CFLAGS) \
25 $(LIBGLADE_CFLAGS) \
26 $(BEEP_DEFINES) \
27 $(ARCH_DEFINES) \
28 $(DBUS_CFLAGS) \
29 $(samplerate_CFLAGS) \
30 $(REGEX_CFLAGS) \
31 $(LIBMCS_CFLAGS) \
32 -D_AUDACIOUS_CORE \
33 -I.. -I../.. \
34 -I./intl
35
36 HEADERS = \
37 auddrct.h \ 10 auddrct.h \
38 configdb.h \ 11 configdb.h \
39 custom_uri.h \ 12 custom_uri.h \
40 dbus.h \ 13 dbus.h \
41 discovery.h \ 14 discovery.h \
65 vfs.h \ 38 vfs.h \
66 vfs_buffer.h \ 39 vfs_buffer.h \
67 vfs_buffered_file.h \ 40 vfs_buffered_file.h \
68 xconvert.h 41 xconvert.h
69 42
70 SOURCES = \ 43 SRCS = \
71 auddrct.c \ 44 auddrct.c \
72 build_stamp.c \ 45 build_stamp.c \
73 configdb.c \ 46 configdb.c \
74 custom_uri.c \ 47 custom_uri.c \
75 discovery.c \ 48 discovery.c \
145 vfs_common.c \ 118 vfs_common.c \
146 visualization.c \ 119 visualization.c \
147 sync-menu.c \ 120 sync-menu.c \
148 xconvert.c 121 xconvert.c
149 122
123 ifdef USE_DBUS
124 SRCS += dbus.c
125 endif
126
150 LIBDEP = ../libguess/libguess.a 127 LIBDEP = ../libguess/libguess.a
151 128
152 ifdef USE_DBUS 129 include ../../buildsys.mk
153 SOURCES += dbus.c
154 CFLAGS += -I../libaudclient
155 DBUS_BINDINGS = dbus-server-bindings.h dbus-client-bindings.h
156 OBJECTIVE_LIBS_NOINST += $(DBUS_BINDINGS)
157 LIBDEP += ../libaudclient/libaudclient$(SHARED_SUFFIX)
158 LDADD += -L../libaudclient -laudclient
159 endif
160 130
161 LIBADD += $(LDADD) 131 LIBADD += $(LDADD)
162 132
163 depend-prehook: $(DBUS_BINDINGS) 133 depend-hook: $(DBUS_BINDINGS)
134
135 CPPFLAGS += -DHAVE_CONFIG_H \
136 $(MOWGLI_CFLAGS) \
137 $(GTK_CFLAGS) \
138 $(LIBGLADE_CFLAGS) \
139 $(BEEP_DEFINES) \
140 $(ARCH_DEFINES) \
141 $(DBUS_CFLAGS) \
142 $(samplerate_CFLAGS) \
143 $(REGEX_CFLAGS) \
144 $(LIBMCS_CFLAGS) \
145 -D_AUDACIOUS_CORE \
146 -I.. -I../.. \
147 -I./intl
148
149 LIBS += \
150 $(LIBINTL) \
151 $(samplerate_LIBS) \
152 ../libguess/libguess.a \
153 $(GTK_LIBS) \
154 $(DBUS_LIBS) \
155 $(MOWGLI_LIBS) \
156 $(LIBMCS_LIBS) \
157 $(LIBGLADE_LIBS) \
158 $(REGEX_LIBS)
159
160 ifdef USE_DBUS
161 CPPFLAGS += -I../libaudclient
162 DBUS_BINDINGS = dbus-server-bindings.h dbus-client-bindings.h
163 LIBS += -L../libaudclient -laudclient
164 endif
164 165
165 build_stamp.c: 166 build_stamp.c:
166 if [ -d ../../.hg ]; then \ 167 if [ -d ../../.hg ]; then \
167 revh=`hg tip --template 'const char *svn_stamp = "#rev#:#node|short#";\n' 2>/dev/null`; \ 168 revh=`hg tip --template 'const char *svn_stamp = "#rev#:#node|short#";\n' 2>/dev/null`; \
168 [ -z "$$revh" ] || echo "$$revh" > build_stamp.c; \ 169 [ -z "$$revh" ] || echo "$$revh" > build_stamp.c; \
169 printf "%10s %-20s\n" STAMP "build_stamp.c"; \
170 fi 170 fi
171 171
172 clean-prehook: 172 clean-hook:
173 if [ -d ../../.hg ]; then \ 173 if [ -d ../../.hg ]; then \
174 rm -f build_stamp.c; \ 174 rm -f build_stamp.c; \
175 fi 175 fi
176 176
177 DBUS_BINDINGS_SOURCES = \ 177 DBUS_BINDINGS_SOURCES = \
178 objects.xml \ 178 objects.xml \
179 mpris_root.xml \ 179 mpris_root.xml \
180 mpris_tracklist.xml \ 180 mpris_tracklist.xml \
181 mpris_player.xml 181 mpris_player.xml
182 182
183 OBJECTS = ${SOURCES:.c=.o}
184
185 desktop_DATA = audacious.desktop 183 desktop_DATA = audacious.desktop
186 desktopdir = $(datadir)/applications 184 desktopdir = $(datadir)/applications
187
188 build-prehook: $(PCH)
189
190 audacious: $(OBJECTS) $(LIBDEP)
191 $(CXX) $(LDFLAGS) $(OBJECTS) $(LDADD) -o $@
192 @printf "%10s %-20s\n" LINK $@
193 185
194 dbus-server-bindings.h: $(DBUS_BINDINGS_SOURCES) 186 dbus-server-bindings.h: $(DBUS_BINDINGS_SOURCES)
195 $(DBUS_BINDING_TOOL) --mode=glib-server --prefix=audacious_rc objects.xml > $@ 187 $(DBUS_BINDING_TOOL) --mode=glib-server --prefix=audacious_rc objects.xml > $@
196 $(DBUS_BINDING_TOOL) --mode=glib-server --prefix=mpris_root mpris_root.xml >> $@ 188 $(DBUS_BINDING_TOOL) --mode=glib-server --prefix=mpris_root mpris_root.xml >> $@
197 $(DBUS_BINDING_TOOL) --mode=glib-server --prefix=mpris_tracklist mpris_tracklist.xml >> $@ 189 $(DBUS_BINDING_TOOL) --mode=glib-server --prefix=mpris_tracklist mpris_tracklist.xml >> $@