~timchen119/ubuntu/trusty/gnome-bluetooth/lp1035431

1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
1
# -*- mode: makefile -*-
2
3
####################################
4
# Everything below here is generic #
5
####################################
6
7
if GTK_DOC_USE_LIBTOOL
1.1.24 by Chris Coulson
Import upstream version 3.1.4
8
GTKDOC_CC = $(LIBTOOL) --tag=CC --mode=compile $(CC) $(INCLUDES) $(GTKDOC_DEPS_CFLAGS) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
9
GTKDOC_LD = $(LIBTOOL) --tag=CC --mode=link $(CC) $(GTKDOC_DEPS_LIBS) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS)
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
10
GTKDOC_RUN = $(LIBTOOL) --mode=execute
11
else
1.1.24 by Chris Coulson
Import upstream version 3.1.4
12
GTKDOC_CC = $(CC) $(INCLUDES) $(GTKDOC_DEPS_CFLAGS) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
13
GTKDOC_LD = $(CC) $(GTKDOC_DEPS_LIBS) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS)
1.1.16 by Robert Ancell
Import upstream version 2.31.6
14
GTKDOC_RUN =
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
15
endif
16
17
# We set GPATH here; this gives us semantics for GNU make
18
# which are more like other make's VPATH, when it comes to
19
# whether a source that is a target of one rule is then
20
# searched for in VPATH/GPATH.
21
#
22
GPATH = $(srcdir)
23
24
TARGET_DIR=$(HTML_DIR)/$(DOC_MODULE)
25
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
26
SETUP_FILES = \
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
27
	$(content_files)		\
28
	$(DOC_MAIN_SGML_FILE)		\
29
	$(DOC_MODULE)-sections.txt	\
30
	$(DOC_MODULE)-overrides.txt
31
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
32
EXTRA_DIST = 				\
1.1.24 by Chris Coulson
Import upstream version 3.1.4
33
	$(HTML_IMAGES)			\
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
34
	$(SETUP_FILES)
35
36
DOC_STAMPS=setup-build.stamp scan-build.stamp tmpl-build.stamp sgml-build.stamp \
37
	html-build.stamp pdf-build.stamp \
1.1.24 by Chris Coulson
Import upstream version 3.1.4
38
	tmpl.stamp sgml.stamp html.stamp pdf.stamp
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
39
40
SCANOBJ_FILES = 		 \
41
	$(DOC_MODULE).args 	 \
42
	$(DOC_MODULE).hierarchy  \
43
	$(DOC_MODULE).interfaces \
44
	$(DOC_MODULE).prerequisites \
45
	$(DOC_MODULE).signals
46
47
REPORT_FILES = \
48
	$(DOC_MODULE)-undocumented.txt \
49
	$(DOC_MODULE)-undeclared.txt \
50
	$(DOC_MODULE)-unused.txt
51
52
CLEANFILES = $(SCANOBJ_FILES) $(REPORT_FILES) $(DOC_STAMPS)
53
54
if ENABLE_GTK_DOC
1.1.16 by Robert Ancell
Import upstream version 2.31.6
55
if GTK_DOC_BUILD_HTML
56
HTML_BUILD_STAMP=html-build.stamp
57
else
58
HTML_BUILD_STAMP=
59
endif
60
if GTK_DOC_BUILD_PDF
61
PDF_BUILD_STAMP=pdf-build.stamp
62
else
63
PDF_BUILD_STAMP=
64
endif
65
66
all-local: $(HTML_BUILD_STAMP) $(PDF_BUILD_STAMP)
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
67
else
68
all-local:
69
endif
70
1.1.16 by Robert Ancell
Import upstream version 2.31.6
71
docs: $(HTML_BUILD_STAMP) $(PDF_BUILD_STAMP)
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
72
73
$(REPORT_FILES): sgml-build.stamp
74
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
75
#### setup ####
76
1.1.38 by Robert Ancell
Import upstream version 3.8.2.1
77
GTK_DOC_V_SETUP=$(GTK_DOC_V_SETUP_$(V))
78
GTK_DOC_V_SETUP_=$(GTK_DOC_V_SETUP_$(AM_DEFAULT_VERBOSITY))
79
GTK_DOC_V_SETUP_0=@echo "  DOC   Preparing build";
80
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
81
setup-build.stamp:
1.1.38 by Robert Ancell
Import upstream version 3.8.2.1
82
	-$(GTK_DOC_V_SETUP)if test "$(abs_srcdir)" != "$(abs_builddir)" ; then \
1.1.24 by Chris Coulson
Import upstream version 3.1.4
83
	    files=`echo $(SETUP_FILES) $(expand_content_files) $(DOC_MODULE).types`; \
84
	    if test "x$$files" != "x" ; then \
85
	        for file in $$files ; do \
86
	            test -f $(abs_srcdir)/$$file && \
1.1.38 by Robert Ancell
Import upstream version 3.8.2.1
87
	                cp -pu $(abs_srcdir)/$$file $(abs_builddir)/$$file || true; \
1.1.24 by Chris Coulson
Import upstream version 3.1.4
88
	        done; \
89
	    fi; \
1.4.3 by Michael Biebl
Import upstream version 3.2.0
90
	    test -d $(abs_srcdir)/tmpl && \
91
	        { cp -rp $(abs_srcdir)/tmpl $(abs_builddir)/; \
92
	        chmod -R u+w $(abs_builddir)/tmpl; } \
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
93
	fi
1.1.38 by Robert Ancell
Import upstream version 3.8.2.1
94
	$(AM_V_at)touch setup-build.stamp
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
95
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
96
#### scan ####
97
1.1.38 by Robert Ancell
Import upstream version 3.8.2.1
98
GTK_DOC_V_SCAN=$(GTK_DOC_V_SCAN_$(V))
99
GTK_DOC_V_SCAN_=$(GTK_DOC_V_SCAN_$(AM_DEFAULT_VERBOSITY))
100
GTK_DOC_V_SCAN_0=@echo "  DOC   Scanning header files";
101
102
GTK_DOC_V_INTROSPECT=$(GTK_DOC_V_INTROSPECT_$(V))
103
GTK_DOC_V_INTROSPECT_=$(GTK_DOC_V_INTROSPECT_$(AM_DEFAULT_VERBOSITY))
104
GTK_DOC_V_INTROSPECT_0=@echo "  DOC   Introspecting gobjects";
105
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
106
scan-build.stamp: $(HFILE_GLOB) $(CFILE_GLOB)
1.1.38 by Robert Ancell
Import upstream version 3.8.2.1
107
	$(GTK_DOC_V_SCAN)_source_dir='' ; \
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
108
	for i in $(DOC_SOURCE_DIR) ; do \
1.1.18 by Michael Terry
Import upstream version 2.32.0
109
	    _source_dir="$${_source_dir} --source-dir=$$i" ; \
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
110
	done ; \
111
	gtkdoc-scan --module=$(DOC_MODULE) --ignore-headers="$(IGNORE_HFILES)" $${_source_dir} $(SCAN_OPTIONS) $(EXTRA_HFILES)
1.1.38 by Robert Ancell
Import upstream version 3.8.2.1
112
	$(GTK_DOC_V_INTROSPECT)if grep -l '^..*$$' $(DOC_MODULE).types > /dev/null 2>&1 ; then \
1.1.24 by Chris Coulson
Import upstream version 3.1.4
113
	    scanobj_options=""; \
114
	    gtkdoc-scangobj 2>&1 --help | grep  >/dev/null "\-\-verbose"; \
115
	    if test "$(?)" = "0"; then \
116
	        if test "x$(V)" = "x1"; then \
117
	            scanobj_options="--verbose"; \
118
	        fi; \
119
	    fi; \
120
	    CC="$(GTKDOC_CC)" LD="$(GTKDOC_LD)" RUN="$(GTKDOC_RUN)" CFLAGS="$(GTKDOC_CFLAGS) $(CFLAGS)" LDFLAGS="$(GTKDOC_LIBS) $(LDFLAGS)" \
121
	    gtkdoc-scangobj $(SCANGOBJ_OPTIONS) $$scanobj_options --module=$(DOC_MODULE); \
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
122
	else \
123
	    for i in $(SCANOBJ_FILES) ; do \
1.1.24 by Chris Coulson
Import upstream version 3.1.4
124
	        test -f $$i || touch $$i ; \
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
125
	    done \
126
	fi
1.1.38 by Robert Ancell
Import upstream version 3.8.2.1
127
	$(AM_V_at)touch scan-build.stamp
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
128
129
$(DOC_MODULE)-decl.txt $(SCANOBJ_FILES) $(DOC_MODULE)-sections.txt $(DOC_MODULE)-overrides.txt: scan-build.stamp
130
	@true
131
132
#### templates ####
133
1.1.38 by Robert Ancell
Import upstream version 3.8.2.1
134
GTK_DOC_V_TMPL=$(GTK_DOC_V_TMPL_$(V))
135
GTK_DOC_V_TMPL_=$(GTK_DOC_V_TMPL_$(AM_DEFAULT_VERBOSITY))
136
GTK_DOC_V_TMPL_0=@echo "  DOC   Rebuilding template files";
137
1.1.24 by Chris Coulson
Import upstream version 3.1.4
138
tmpl-build.stamp: setup-build.stamp $(DOC_MODULE)-decl.txt $(SCANOBJ_FILES) $(DOC_MODULE)-sections.txt $(DOC_MODULE)-overrides.txt
1.1.38 by Robert Ancell
Import upstream version 3.8.2.1
139
	$(GTK_DOC_V_TMPL)gtkdoc-mktmpl --module=$(DOC_MODULE) $(MKTMPL_OPTIONS)
140
	$(AM_V_at)if test "$(abs_srcdir)" != "$(abs_builddir)" ; then \
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
141
	  if test -w $(abs_srcdir) ; then \
142
	    cp -rp $(abs_builddir)/tmpl $(abs_srcdir)/; \
143
	  fi \
144
	fi
1.1.38 by Robert Ancell
Import upstream version 3.8.2.1
145
	$(AM_V_at)touch tmpl-build.stamp
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
146
147
tmpl.stamp: tmpl-build.stamp
148
	@true
149
1.1.16 by Robert Ancell
Import upstream version 2.31.6
150
$(srcdir)/tmpl/*.sgml:
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
151
	@true
152
153
#### xml ####
154
1.1.38 by Robert Ancell
Import upstream version 3.8.2.1
155
GTK_DOC_V_XML=$(GTK_DOC_V_XML_$(V))
156
GTK_DOC_V_XML_=$(GTK_DOC_V_XML_$(AM_DEFAULT_VERBOSITY))
157
GTK_DOC_V_XML_0=@echo "  DOC   Building XML";
158
1.1.16 by Robert Ancell
Import upstream version 2.31.6
159
sgml-build.stamp: tmpl.stamp $(DOC_MODULE)-sections.txt $(srcdir)/tmpl/*.sgml $(expand_content_files)
1.1.38 by Robert Ancell
Import upstream version 3.8.2.1
160
	$(GTK_DOC_V_XML)-chmod -R u+w $(srcdir) && _source_dir='' ; \
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
161
	for i in $(DOC_SOURCE_DIR) ; do \
1.1.18 by Michael Terry
Import upstream version 2.32.0
162
	    _source_dir="$${_source_dir} --source-dir=$$i" ; \
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
163
	done ; \
164
	gtkdoc-mkdb --module=$(DOC_MODULE) --output-format=xml --expand-content-files="$(expand_content_files)" --main-sgml-file=$(DOC_MAIN_SGML_FILE) $${_source_dir} $(MKDB_OPTIONS)
1.1.38 by Robert Ancell
Import upstream version 3.8.2.1
165
	$(AM_V_at)touch sgml-build.stamp
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
166
167
sgml.stamp: sgml-build.stamp
168
	@true
169
170
#### html ####
171
1.1.38 by Robert Ancell
Import upstream version 3.8.2.1
172
GTK_DOC_V_HTML=$(GTK_DOC_V_HTML_$(V))
173
GTK_DOC_V_HTML_=$(GTK_DOC_V_HTML_$(AM_DEFAULT_VERBOSITY))
174
GTK_DOC_V_HTML_0=@echo "  DOC   Building HTML";
175
176
GTK_DOC_V_XREF=$(GTK_DOC_V_XREF_$(V))
177
GTK_DOC_V_XREF_=$(GTK_DOC_V_XREF_$(AM_DEFAULT_VERBOSITY))
178
GTK_DOC_V_XREF_0=@echo "  DOC   Fixing cross-references";
179
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
180
html-build.stamp: sgml.stamp $(DOC_MAIN_SGML_FILE) $(content_files)
1.1.38 by Robert Ancell
Import upstream version 3.8.2.1
181
	$(GTK_DOC_V_HTML)rm -rf html && mkdir html && \
182
	mkhtml_options=""; \
1.1.24 by Chris Coulson
Import upstream version 3.1.4
183
	gtkdoc-mkhtml 2>&1 --help | grep  >/dev/null "\-\-verbose"; \
184
	if test "$(?)" = "0"; then \
185
	  if test "x$(V)" = "x1"; then \
186
	    mkhtml_options="$$mkhtml_options --verbose"; \
187
	  fi; \
188
	fi; \
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
189
	gtkdoc-mkhtml 2>&1 --help | grep  >/dev/null "\-\-path"; \
190
	if test "$(?)" = "0"; then \
1.1.24 by Chris Coulson
Import upstream version 3.1.4
191
	  mkhtml_options="$$mkhtml_options --path=\"$(abs_srcdir)\""; \
1.1.16 by Robert Ancell
Import upstream version 2.31.6
192
	fi; \
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
193
	cd html && gtkdoc-mkhtml $$mkhtml_options $(MKHTML_OPTIONS) $(DOC_MODULE) ../$(DOC_MAIN_SGML_FILE)
194
	-@test "x$(HTML_IMAGES)" = "x" || \
195
	for file in $(HTML_IMAGES) ; do \
196
	  if test -f $(abs_srcdir)/$$file ; then \
197
	    cp $(abs_srcdir)/$$file $(abs_builddir)/html; \
198
	  fi; \
199
	  if test -f $(abs_builddir)/$$file ; then \
200
	    cp $(abs_builddir)/$$file $(abs_builddir)/html; \
201
	  fi; \
202
	done;
1.1.38 by Robert Ancell
Import upstream version 3.8.2.1
203
	$(GTK_DOC_V_XREF)gtkdoc-fixxref --module=$(DOC_MODULE) --module-dir=html --html-dir=$(HTML_DIR) $(FIXXREF_OPTIONS)
204
	$(AM_V_at)touch html-build.stamp
1.1.16 by Robert Ancell
Import upstream version 2.31.6
205
206
#### pdf ####
207
1.1.38 by Robert Ancell
Import upstream version 3.8.2.1
208
GTK_DOC_V_PDF=$(GTK_DOC_V_PDF_$(V))
209
GTK_DOC_V_PDF_=$(GTK_DOC_V_PDF_$(AM_DEFAULT_VERBOSITY))
210
GTK_DOC_V_PDF_0=@echo "  DOC   Building PDF";
211
1.1.16 by Robert Ancell
Import upstream version 2.31.6
212
pdf-build.stamp: sgml.stamp $(DOC_MAIN_SGML_FILE) $(content_files)
1.1.38 by Robert Ancell
Import upstream version 3.8.2.1
213
	$(GTK_DOC_V_PDF)rm -f $(DOC_MODULE).pdf && \
214
	mkpdf_options=""; \
1.1.24 by Chris Coulson
Import upstream version 3.1.4
215
	gtkdoc-mkpdf 2>&1 --help | grep  >/dev/null "\-\-verbose"; \
216
	if test "$(?)" = "0"; then \
217
	  if test "x$(V)" = "x1"; then \
218
	    mkpdf_options="$$mkpdf_options --verbose"; \
219
	  fi; \
220
	fi; \
1.1.16 by Robert Ancell
Import upstream version 2.31.6
221
	if test "x$(HTML_IMAGES)" != "x"; then \
222
	  for img in $(HTML_IMAGES); do \
223
	    part=`dirname $$img`; \
1.1.24 by Chris Coulson
Import upstream version 3.1.4
224
	    echo $$mkpdf_options | grep >/dev/null "\-\-imgdir=$$part "; \
1.1.16 by Robert Ancell
Import upstream version 2.31.6
225
	    if test $$? != 0; then \
1.1.24 by Chris Coulson
Import upstream version 3.1.4
226
	      mkpdf_options="$$mkpdf_options --imgdir=$$part"; \
1.1.16 by Robert Ancell
Import upstream version 2.31.6
227
	    fi; \
228
	  done; \
229
	fi; \
1.1.24 by Chris Coulson
Import upstream version 3.1.4
230
	gtkdoc-mkpdf --path="$(abs_srcdir)" $$mkpdf_options $(DOC_MODULE) $(DOC_MAIN_SGML_FILE) $(MKPDF_OPTIONS)
1.1.38 by Robert Ancell
Import upstream version 3.8.2.1
231
	$(AM_V_at)touch pdf-build.stamp
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
232
233
##############
234
235
clean-local:
1.1.24 by Chris Coulson
Import upstream version 3.1.4
236
	@rm -f *~ *.bak
237
	@rm -rf .libs
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
238
239
distclean-local:
1.1.24 by Chris Coulson
Import upstream version 3.1.4
240
	@rm -rf xml html $(REPORT_FILES) $(DOC_MODULE).pdf \
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
241
	    $(DOC_MODULE)-decl-list.txt $(DOC_MODULE)-decl.txt
1.1.24 by Chris Coulson
Import upstream version 3.1.4
242
	@if test "$(abs_srcdir)" != "$(abs_builddir)" ; then \
1.4.2 by Laurent Bigonville
Import upstream version 3.0.0
243
	    rm -f $(SETUP_FILES) $(expand_content_files) $(DOC_MODULE).types; \
244
	    rm -rf tmpl; \
245
	fi
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
246
1.5.1 by Michael Biebl
Import upstream version 3.4.0
247
maintainer-clean-local:
1.1.24 by Chris Coulson
Import upstream version 3.1.4
248
	@rm -rf xml html
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
249
250
install-data-local:
1.4.3 by Michael Biebl
Import upstream version 3.2.0
251
	@installfiles=`echo $(builddir)/html/*`; \
252
	if test "$$installfiles" = '$(builddir)/html/*'; \
1.1.24 by Chris Coulson
Import upstream version 3.1.4
253
	then echo 1>&2 'Nothing to install' ; \
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
254
	else \
255
	  if test -n "$(DOC_MODULE_VERSION)"; then \
256
	    installdir="$(DESTDIR)$(TARGET_DIR)-$(DOC_MODULE_VERSION)"; \
257
	  else \
258
	    installdir="$(DESTDIR)$(TARGET_DIR)"; \
259
	  fi; \
260
	  $(mkinstalldirs) $${installdir} ; \
261
	  for i in $$installfiles; do \
1.1.24 by Chris Coulson
Import upstream version 3.1.4
262
	    echo ' $(INSTALL_DATA) '$$i ; \
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
263
	    $(INSTALL_DATA) $$i $${installdir}; \
264
	  done; \
265
	  if test -n "$(DOC_MODULE_VERSION)"; then \
266
	    mv -f $${installdir}/$(DOC_MODULE).devhelp2 \
267
	      $${installdir}/$(DOC_MODULE)-$(DOC_MODULE_VERSION).devhelp2; \
268
	  fi; \
1.1.16 by Robert Ancell
Import upstream version 2.31.6
269
	  $(GTKDOC_REBASE) --relative --dest-dir=$(DESTDIR) --html-dir=$${installdir}; \
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
270
	fi
271
272
uninstall-local:
1.1.16 by Robert Ancell
Import upstream version 2.31.6
273
	@if test -n "$(DOC_MODULE_VERSION)"; then \
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
274
	  installdir="$(DESTDIR)$(TARGET_DIR)-$(DOC_MODULE_VERSION)"; \
275
	else \
276
	  installdir="$(DESTDIR)$(TARGET_DIR)"; \
277
	fi; \
278
	rm -rf $${installdir}
279
280
#
281
# Require gtk-doc when making dist
282
#
283
if ENABLE_GTK_DOC
1.5.2 by Michael Biebl
Import upstream version 3.4.1
284
dist-check-gtkdoc: docs
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
285
else
286
dist-check-gtkdoc:
287
	@echo "*** gtk-doc must be installed and enabled in order to make dist"
288
	@false
289
endif
290
291
dist-hook: dist-check-gtkdoc dist-hook-local
1.1.24 by Chris Coulson
Import upstream version 3.1.4
292
	@mkdir $(distdir)/tmpl
293
	@mkdir $(distdir)/html
294
	@-cp ./tmpl/*.sgml $(distdir)/tmpl
295
	@cp ./html/* $(distdir)/html
296
	@-cp ./$(DOC_MODULE).pdf $(distdir)/
297
	@-cp ./$(DOC_MODULE).types $(distdir)/
298
	@-cp ./$(DOC_MODULE)-sections.txt $(distdir)/
299
	@cd $(distdir) && rm -f $(DISTCLEANFILES)
300
	@$(GTKDOC_REBASE) --online --relative --html-dir=$(distdir)/html
1.2.1 by Filippo Giunchedi
Import upstream version 2.27.5
301
302
.PHONY : dist-hook-local docs