Makefile.am 9.59 KB
Newer Older
1
2
3
SUBDIRS =						\
	plugins

4
AM_CPPFLAGS =						\
5
	$(APPSTREAM_CFLAGS)				\
6
7
	$(GLIB_CFLAGS)					\
	$(GTK_CFLAGS)					\
8
	$(SOUP_CFLAGS)					\
9
	$(PACKAGEKIT_CFLAGS)				\
10
	$(GNOME_DESKTOP_CFLAGS)				\
11
	$(POLKIT_CFLAGS)				\
12
	$(FWUPD_CFLAGS)					\
Richard Hughes's avatar
Richard Hughes committed
13
	$(LIBSECRET_CFLAGS)				\
14
	-DG_LOG_DOMAIN=\"Gs\"				\
15
	-DI_KNOW_THE_PACKAGEKIT_GLIB2_API_IS_SUBJECT_TO_CHANGE	\
Richard Hughes's avatar
Richard Hughes committed
16
	-DGS_MODULESETDIR=\"$(datadir)/gnome-software/modulesets.d\" \
Richard Hughes's avatar
Richard Hughes committed
17
	-DLIBDIR=\"$(libdir)\"				\
18
19
20
21
	-DBINDIR=\"$(bindir)\"				\
	-DDATADIR=\"$(datadir)\"			\
	-DVERSION="\"$(VERSION)\""			\
	-DLOCALEDIR=\""$(localedir)"\"			\
22
	-DTESTDATADIR=\""$(top_srcdir)/data"\"		\
23
24
25
26
27
	-DGS_DATA=\"$(pkgdatadir)\"

@INTLTOOL_DESKTOP_RULE@
desktopdir = $(datadir)/applications
desktop_in_files =					\
28
	gnome-software-local-file.desktop.in		\
29
	org.gnome.Software.desktop.in
30
31
32
desktop_DATA = $(desktop_in_files:.desktop.in=.desktop)

UI_FILES =						\
Matthias Clasen's avatar
Matthias Clasen committed
33
	gnome-software.ui				\
Kalev Lember's avatar
Kalev Lember committed
34
	gs-app-addon-row.ui				\
35
	gs-app-folder-dialog.ui				\
Kalev Lember's avatar
Kalev Lember committed
36
	gs-app-row.ui					\
37
	gs-app-tile.ui					\
Richard Hughes's avatar
Richard Hughes committed
38
	gs-auth-dialog.ui				\
39
40
	gs-category-tile.ui				\
	gs-feature-tile.ui				\
Kalev Lember's avatar
Kalev Lember committed
41
	gs-first-run-dialog.ui				\
42
	gs-history-dialog.ui				\
43
44
	gs-menus.ui					\
	gs-popular-tile.ui				\
45
46
	gs-review-dialog.ui				\
	gs-review-histogram.ui				\
47
	gs-review-row.ui				\
48
	gs-screenshot-image.ui				\
49
	gs-shell-category.ui				\
50
	gs-shell-details.ui				\
51
	gs-shell-extras.ui				\
52
	gs-shell-installed.ui				\
53
	gs-shell-moderate.ui				\
54
	gs-shell-overview.ui				\
55
	gs-shell-search.ui				\
56
	gs-shell-updates.ui				\
57
	gs-sources-dialog-row.ui			\
58
	gs-sources-dialog.ui				\
59
	gs-star-widget.ui				\
60
	gs-update-dialog.ui				\
61
	gs-upgrade-banner.ui
Richard Hughes's avatar
Richard Hughes committed
62

63
dbusservicedir = $(datadir)/dbus-1/services
64
65
66
dbusservice_DATA =					\
	org.gnome.Software.service

67
if HAVE_PACKAGEKIT
68
dbusservice_DATA += 					\
69
70
	org.freedesktop.PackageKit.service

71
72
org.freedesktop.PackageKit.service: org.freedesktop.PackageKit.service.in Makefile
	$(AM_V_GEN) sed -e "s|\@bindir\@|$(bindir)|" $<> $@
73
endif
74

75
76
77
org.gnome.Software.service: org.gnome.Software.service.in Makefile
	$(AM_V_GEN) sed -e "s|\@bindir\@|$(bindir)|" $<> $@

Matthias Clasen's avatar
Matthias Clasen committed
78
searchproviderdir = $(datadir)/gnome-shell/search-providers
79
searchprovider_DATA = org.gnome.Software-search-provider.ini
Matthias Clasen's avatar
Matthias Clasen committed
80

Matthias Clasen's avatar
Matthias Clasen committed
81
82
83
autostartdir = $(sysconfdir)/xdg/autostart
autostart_DATA = gnome-software-service.desktop

84
85
gnome-software-service.desktop: gnome-software-service.desktop.in Makefile
	$(AM_V_GEN) sed -e "s|\@bindir\@|$(bindir)|" $<> $@
Matthias Clasen's avatar
Matthias Clasen committed
86

87
88
89
90
91
noinst_PROGRAMS =					\
	gnome-software-cmd

gnome_software_cmd_SOURCES =				\
	gs-app.c					\
Richard Hughes's avatar
Richard Hughes committed
92
	gs-auth.c					\
93
	gs-review.c					\
94
95
	gs-cmd.c					\
	gs-utils.c					\
96
	gs-os-release.c					\
97
98
99
	gs-plugin-loader.c				\
	gs-plugin-loader-sync.c				\
	gs-category.c					\
100
	gs-plugin.c
101
102

gnome_software_cmd_LDADD =				\
103
	$(APPSTREAM_LIBS)				\
104
	$(POLKIT_LIBS)					\
105
	$(SOUP_LIBS)					\
Richard Hughes's avatar
Richard Hughes committed
106
	$(LIBSECRET_LIBS)				\
107
	$(GLIB_LIBS)					\
108
	$(GTK_LIBS)
109
110

gnome_software_cmd_CFLAGS =				\
111
	$(WARN_CFLAGS)
112

113
114
115
116
bin_PROGRAMS =						\
	gnome-software

gnome_software_SOURCES =				\
117
118
	gs-utils.c					\
	gs-utils.h					\
119
120
	gs-app.c					\
	gs-app.h					\
Richard Hughes's avatar
Richard Hughes committed
121
122
123
124
	gs-auth.c					\
	gs-auth.h					\
	gs-auth-dialog.c				\
	gs-auth-dialog.h				\
125
126
	gs-category.c					\
	gs-category.h					\
Kalev Lember's avatar
Kalev Lember committed
127
128
	gs-app-addon-row.c				\
	gs-app-addon-row.h				\
Kalev Lember's avatar
Kalev Lember committed
129
130
	gs-app-row.c					\
	gs-app-row.h					\
131
132
	gs-star-widget.c				\
	gs-star-widget.h				\
133
134
	gs-popular-tile.c				\
	gs-popular-tile.h				\
135
136
	gs-feature-tile.c				\
	gs-feature-tile.h				\
137
138
	gs-category-tile.c				\
	gs-category-tile.h				\
139
140
	gs-app-tile.c					\
	gs-app-tile.h					\
141
142
	gs-app-folder-dialog.c				\
	gs-app-folder-dialog.h				\
Kalev Lember's avatar
Kalev Lember committed
143
144
	gs-first-run-dialog.c				\
	gs-first-run-dialog.h				\
145
146
	gs-history-dialog.c				\
	gs-history-dialog.h				\
147
148
	gs-fixed-size-bin.h				\
	gs-fixed-size-bin.c				\
Rafał Lużyński's avatar
Rafał Lużyński committed
149
150
	gs-hiding-box.h					\
	gs-hiding-box.c					\
151
152
	gs-language.c					\
	gs-language.h					\
153
154
	gs-os-release.c					\
	gs-os-release.h					\
155
156
	gs-page.c					\
	gs-page.h					\
157
	gs-plugin.c					\
Richard Hughes's avatar
Richard Hughes committed
158
	gs-plugin.h					\
159
160
	gs-progress-button.c				\
	gs-progress-button.h				\
161
162
	gs-review.c					\
	gs-review.h					\
163
164
165
166
167
168
	gs-review-bar.c					\
	gs-review-bar.h					\
	gs-review-dialog.c				\
	gs-review-dialog.h				\
	gs-review-histogram.c				\
	gs-review-histogram.h				\
169
170
	gs-review-row.c					\
	gs-review-row.h					\
171
172
	gs-screenshot-image.c				\
	gs-screenshot-image.h				\
173
174
	gs-shell.c					\
	gs-shell.h					\
175
176
	gs-shell-details.c				\
	gs-shell-details.h				\
177
178
	gs-shell-category.c				\
	gs-shell-category.h				\
179
180
	gs-shell-extras.c				\
	gs-shell-extras.h				\
181
182
	gs-shell-installed.c				\
	gs-shell-installed.h				\
183
184
	gs-shell-moderate.c				\
	gs-shell-moderate.h				\
185
186
	gs-shell-overview.c				\
	gs-shell-overview.h				\
187
188
	gs-shell-updates.c				\
	gs-shell-updates.h				\
189
190
	gs-shell-search.c				\
	gs-shell-search.h				\
191
192
	gs-sources-dialog.c				\
	gs-sources-dialog.h				\
193
194
	gs-sources-dialog-row.c				\
	gs-sources-dialog-row.h				\
195
196
	gs-update-dialog.c				\
	gs-update-dialog.h				\
197
198
	gs-update-list.c				\
	gs-update-list.h				\
Matthias Clasen's avatar
Matthias Clasen committed
199
200
	gs-update-monitor.c				\
	gs-update-monitor.h				\
Kalev Lember's avatar
Kalev Lember committed
201
202
	gs-upgrade-banner.c				\
	gs-upgrade-banner.h				\
203
204
	gs-vendor.c					\
	gs-vendor.h					\
Richard Hughes's avatar
Richard Hughes committed
205
206
	gs-plugin-loader.c				\
	gs-plugin-loader.h				\
207
208
	gs-plugin-loader-sync.c				\
	gs-plugin-loader-sync.h				\
Matthias Clasen's avatar
Matthias Clasen committed
209
210
	gs-shell-search-provider.c			\
	gs-shell-search-provider.h			\
211
212
	gs-application.c				\
	gs-application.h				\
Matthias Clasen's avatar
Matthias Clasen committed
213
	gs-folders.c					\
214
	gs-folders.h					\
215
216
	gs-main.c

217
218
219
220
221
222
nodist_gnome_software_SOURCES =				\
	gs-resources.c					\
	gs-resources.h					\
	gs-shell-search-provider-generated.c		\
	gs-shell-search-provider-generated.h

223
224
225
226
if HAVE_PACKAGEKIT
gnome_software_SOURCES +=				\
	gs-dbus-helper.c				\
	gs-dbus-helper.h
227
228
229
230

nodist_gnome_software_SOURCES +=			\
	$(packagekit_built_sources)			\
	$(packagekit_modify2_built_sources)
231
232
endif

233
gnome_software_LDADD =					\
234
	$(APPSTREAM_LIBS)				\
235
236
	$(GLIB_LIBS)					\
	$(GTK_LIBS)					\
237
	$(SOUP_LIBS)					\
Richard Hughes's avatar
Richard Hughes committed
238
	$(LIBSECRET_LIBS)				\
239
	$(PACKAGEKIT_LIBS)				\
240
	$(GNOME_DESKTOP_LIBS)				\
241
	$(POLKIT_LIBS)					\
242
243
	-lm

244
gnome_software_CFLAGS =					\
245
	-DLIBEXECDIR=\"$(libexecdir)\"			\
246
	$(WARN_CFLAGS)
247

248
249
250
251
252
253
254
255
packagekit_built_sources = gs-packagekit-generated.c gs-packagekit-generated.h
$(packagekit_built_sources): Makefile.am org.freedesktop.PackageKit.xml
	$(AM_V_GEN) gdbus-codegen				\
		--interface-prefix org.freedesktop.		\
		--c-namespace Gs				\
		--generate-c-code gs-packagekit-generated	\
		$(srcdir)/org.freedesktop.PackageKit.xml

256
257
258
259
260
261
262
263
packagekit_modify2_built_sources = gs-packagekit-modify2-generated.c gs-packagekit-modify2-generated.h
$(packagekit_modify2_built_sources): Makefile.am org.freedesktop.PackageKit.Modify2.xml
	$(AM_V_GEN) gdbus-codegen					\
		--interface-prefix org.freedesktop.			\
		--c-namespace Gs					\
		--generate-c-code gs-packagekit-modify2-generated	\
		$(srcdir)/org.freedesktop.PackageKit.Modify2.xml

Matthias Clasen's avatar
Matthias Clasen committed
264
265
266
267
268
269
270
gs-shell-search-provider-generated.h gs-shell-search-provider-generated.c: Makefile.am $(srcdir)/shell-search-provider-dbus-interfaces.xml
	$(AM_V_GEN) gdbus-codegen \
	 	--interface-prefix org.gnome. \
		--c-namespace Gs \
		--generate-c-code gs-shell-search-provider-generated \
		$(srcdir)/shell-search-provider-dbus-interfaces.xml

271
272
273
274
275
gs-resources.c: gnome-software.gresource.xml $(shell $(GLIB_COMPILE_RESOURCES) --sourcedir=$(srcdir) --generate-dependencies $(srcdir)/gnome-software.gresource.xml)
	$(AM_V_GEN) $(GLIB_COMPILE_RESOURCES) --sourcedir=$(srcdir) --target=$@ --generate-source --c-name gs $(srcdir)/gnome-software.gresource.xml

gs-resources.h: gnome-software.gresource.xml $(shell $(GLIB_COMPILE_RESOURCES) --sourcedir=$(srcdir) --generate-dependencies $(srcdir)/gnome-software.gresource.xml)
	$(AM_V_GEN) $(GLIB_COMPILE_RESOURCES) --sourcedir=$(srcdir) --target=$@ --generate-header --c-name gs $(srcdir)/gnome-software.gresource.xml
276
277

BUILT_SOURCES =						\
278
	$(packagekit_built_sources)			\
279
	$(packagekit_modify2_built_sources)		\
Matthias Clasen's avatar
Matthias Clasen committed
280
281
	gs-shell-search-provider-generated.c		\
	gs-shell-search-provider-generated.h		\
282
283
284
	gs-resources.c					\
	gs-resources.h

Richard Hughes's avatar
Richard Hughes committed
285
286
287
288
289
290
291
292
293
294
295
TESTS_ENVIRONMENT =						\
	libtool --mode=execute valgrind				\
	--quiet							\
	--leak-check=full					\
	--show-possibly-lost=no

check_PROGRAMS =						\
	gs-self-test

gs_self_test_SOURCES =						\
	gs-app.c						\
Richard Hughes's avatar
Richard Hughes committed
296
	gs-auth.c						\
297
	gs-category.c						\
298
	gs-os-release.c						\
299
	gs-plugin-loader-sync.c					\
Richard Hughes's avatar
Richard Hughes committed
300
301
	gs-plugin-loader.c					\
	gs-plugin.c						\
302
	gs-review.c						\
Richard Hughes's avatar
Richard Hughes committed
303
	gs-utils.c						\
Richard Hughes's avatar
Richard Hughes committed
304
305
306
	gs-self-test.c

gs_self_test_LDADD =						\
307
	$(APPSTREAM_LIBS)					\
308
	$(POLKIT_LIBS)						\
Richard Hughes's avatar
Richard Hughes committed
309
	$(SOUP_LIBS)						\
Richard Hughes's avatar
Richard Hughes committed
310
	$(LIBSECRET_LIBS)					\
Richard Hughes's avatar
Richard Hughes committed
311
312
313
	$(GLIB_LIBS)						\
	$(GTK_LIBS)

314
gs_self_test_CFLAGS = $(WARN_CFLAGS)
Richard Hughes's avatar
Richard Hughes committed
315
316
317

TESTS = gs-self-test

318
EXTRA_DIST =						\
Matthias Clasen's avatar
Matthias Clasen committed
319
	shell-search-provider-dbus-interfaces.xml	\
320
	org.freedesktop.PackageKit.xml			\
321
	org.freedesktop.PackageKit.Modify2.xml		\
322
	gnome-software.gresource.xml			\
Richard Hughes's avatar
Richard Hughes committed
323
	gnome-software.xml				\
324
	gtk-style.css					\
Matthias Clasen's avatar
Matthias Clasen committed
325
	gtk-style-hc.css				\
326
	$(desktop_in_files)				\
327
	org.freedesktop.PackageKit.service.in		\
328
329
	org.gnome.Software.service.in			\
	gnome-software-service.desktop.in		\
Richard Hughes's avatar
Richard Hughes committed
330
	$(searchprovider_DATA)				\
331
332
	$(UI_FILES)

333
334
335
336
man_MANS =
if ENABLE_MAN
man_MANS += gnome-software.1
endif
337

Matthias Clasen's avatar
Matthias Clasen committed
338
339
340
341
342
343
344
345
346
347
XSLTPROC_FLAGS = \
	--nonet \
	--stringparam man.output.quietly 1 \
	--stringparam funcsynopsis.style ansi \
	--stringparam man.th.extra1.suppress 1 \
	--stringparam man.authors.section.enabled 0 \
	--stringparam man.copyright.section.enabled 0

gnome-software.1: gnome-software.xml
	$(AM_V_GEN) $(XSLTPROC) $(XSLTPROC_FLAGS) http://docbook.sourceforge.net/release/xsl/current/manpages/docbook.xsl $<
348

349
350
clean-local:
	rm -f *~
351
352
	rm -f *.1
	rm -f manpage.*
353

354
355
356
357
CLEANFILES =						\
	$(BUILT_SOURCES)				\
	gnome-software.1				\
	manpage.*
358
359
360
361
362
363

MAINTAINERCLEANFILES =					\
	*~						\
	Makefile.in

DISTCLEANFILES =					\
364
	gnome-software-local-file.desktop		\
Richard Hughes's avatar
Richard Hughes committed
365
366
	gnome-software-service.desktop			\
	org.gnome.Software.desktop			\
367
	org.freedesktop.PackageKit.service		\
Richard Hughes's avatar
Richard Hughes committed
368
	org.gnome.Software.service
369
370

-include $(top_srcdir)/git.mk