• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Copyright (c) 2014-2018 The Khronos Group Inc.
2#
3# Licensed under the Apache License, Version 2.0 (the "License");
4# you may not use this file except in compliance with the License.
5# You may obtain a copy of the License at
6#
7#     http://www.apache.org/licenses/LICENSE-2.0
8#
9# Unless required by applicable law or agreed to in writing, software
10# distributed under the License is distributed on an "AS IS" BASIS,
11# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12# See the License for the specific language governing permissions and
13# limitations under the License.
14
15# Vulkan Specification makefile
16#
17# To build the spec with a specific version included, set the
18# $(VERSIONS) variable on the make command line to a space-separated
19# list of version names (e.g. VK_VERSION_1_1) *including all previous
20# versions of the API* (e.g. VK_VERSION_1_1 must also include
21# VK_VERSION_1_0). $(VERSIONS) is converted into asciidoc and generator
22# script arguments $(VERSIONATTRIBS) and $(VERSIONOPTIONS)
23#
24# To build the specification and reference pages with optional
25# extensions included, set the $(EXTENSIONS) variable on the make
26# command line to a space-separated list of extension names. The
27# VK_KHR_sampler_mirror_clamp_to_edge extension which is a required part
28# of Vulkan 1.0, is always included. $(EXTENSIONS) is converted into
29# asciidoc and generator script arguments $(EXTATTRIBS) and
30# $(EXTOPTIONS).
31
32# If a recipe fails, delete its target file. Without this cleanup, the leftover
33# file from the failed recipe can falsely satisfy dependencies on subsequent
34# runs of `make`.
35.DELETE_ON_ERROR:
36
37VERSIONS := VK_VERSION_1_0 VK_VERSION_1_1
38VERSIONATTRIBS := $(foreach version,$(VERSIONS),-a $(version))
39VERSIONOPTIONS := $(foreach version,$(VERSIONS),-feature $(version))
40
41EXTS := $(sort VK_KHR_sampler_mirror_clamp_to_edge $(EXTENSIONS) $(DIFFEXTENSIONS))
42EXTATTRIBS := $(foreach ext,$(EXTS),-a $(ext))
43EXTOPTIONS := $(foreach ext,$(EXTS),-extension $(ext))
44
45# APITITLE can be set to extra text to append to the document title,
46# normally used when building with extensions included.
47APITITLE =
48
49# The default 'all' target builds the following sub-targets:
50#  html - HTML single-page API specification
51#  pdf - PDF single-page API specification
52#  styleguide - HTML5 single-page "Documentation and Extensions" guide
53#  registry - HTML5 single-page XML Registry Schema documentation
54#  manhtml - HTML5 single-page reference guide
55#  manpdf - PDF reference guide
56#  manhtmlpages - HTML5 separate per-feature reference pages
57#  checkinc - validator script for asciidoc include files
58#  checklinks - validator script for asciidoc xrefs
59
60all: alldocs allchecks
61
62alldocs: allspecs allman
63
64allspecs: html pdf styleguide registry
65
66allman: manhtml manpdf manhtmlpages
67
68allchecks: checkinc checklinks
69
70# Note that the := assignments below are immediate, not deferred, and
71# are therefore order-dependent in the Makefile
72
73QUIET	 ?= @
74PYTHON	 ?= python3
75ASCIIDOC ?= asciidoctor
76RM	 = rm -f
77RMRF	 = rm -rf
78MKDIR	 = mkdir -p
79CP	 = cp
80ECHO	 = echo
81GS_EXISTS := $(shell command -v gs 2> /dev/null)
82
83# Target directories for output files
84# HTMLDIR - 'html' target
85# PDFDIR - 'pdf' target
86# CHECKDIR - 'allchecks' target
87OUTDIR	  := $(CURDIR)/out
88HTMLDIR   := $(OUTDIR)/html
89VUDIR	  := $(OUTDIR)/validation
90PDFDIR	  := $(OUTDIR)/pdf
91CHECKDIR  := $(OUTDIR)/checks
92
93# PDF Equations are written to SVGs, this dictates the location to store those files (temporary)
94PDFMATHDIR:=$(OUTDIR)/equations_temp
95
96# Set VERBOSE to -v to see what asciidoc is doing.
97VERBOSE =
98
99# asciidoc attributes to set.
100# PATCHVERSION must == VK_HEADER_VERSION from vk.xml / vulkan_core.h
101# NOTEOPTS   sets options controlling which NOTEs are generated
102# ATTRIBOPTS sets the api revision and enables MathJax generation
103# VERSIONATTRIBS sets attributes for enabled API versions (set above
104#	     based on $(VERSIONS))
105# EXTATTRIBS sets attributes for enabled extensions (set above based on
106#	     $(EXTENSIONS))
107# EXTRAATTRIBS sets additional attributes, if passed to make
108# ADOCOPTS   options for asciidoc->HTML5 output
109NOTEOPTS     = -a editing-notes -a implementation-guide
110PATCHVERSION = 83
111ifneq (,$(findstring VK_VERSION_1_1,$(VERSIONS)))
112SPECREVISION = 1.1.$(PATCHVERSION)
113else
114SPECREVISION = 1.0.$(PATCHVERSION)
115endif
116
117# Spell out ISO 8601 format as not all date commands support --rfc-3339
118SPECDATE     = $(shell echo `date -u "+%Y-%m-%d %TZ"`)
119
120# Generate Asciidoc attributes for spec remark
121# Could use `git log -1 --format="%cd"` to get branch commit date
122# This used to be a dependency in the spec html/pdf targets,
123# but that's likely to lead to merge conflicts. Just regenerate
124# when pushing a new spec for review to the sandbox.
125# The dependency on HEAD is per the suggestion in
126# http://neugierig.org/software/blog/2014/11/binary-revisions.html
127SPECREMARK = from git branch: $(shell echo `git symbolic-ref --short HEAD 2> /dev/null || echo Git branch information not available`) \
128	     commit: $(shell echo `git log -1 --format="%H"`)
129
130ATTRIBOPTS   = -a revnumber="$(SPECREVISION)" \
131	       -a revdate="$(SPECDATE)" \
132	       -a revremark="$(SPECREMARK)" \
133	       -a apititle="$(APITITLE)" \
134	       -a stem=latexmath \
135	       $(VERSIONATTRIBS) \
136	       $(EXTATTRIBS) \
137	       $(EXTRAATTRIBS)
138
139ADOCEXTS     = -r $(CURDIR)/config/vulkan-macros.rb -r $(CURDIR)/config/tilde_open_block.rb
140ADOCOPTS     = -d book $(ATTRIBOPTS) $(NOTEOPTS) $(VERBOSE) $(ADOCEXTS)
141
142ADOCHTMLEXTS = -r $(CURDIR)/config/katex_replace.rb
143
144# ADOCHTMLOPTS relies on the relative runtime path from the output HTML
145# file to the katex scripts being set with KATEXDIR. This is overridden
146# by some targets.
147# ADOCHTMLOPTS also relies on the absolute build-time path to the
148# 'stylesdir' containing our custom CSS.
149KATEXDIR     = katex
150ADOCHTMLOPTS = $(ADOCHTMLEXTS) -a katexpath=$(KATEXDIR) \
151	       -a stylesheet=khronos.css -a stylesdir=$(CURDIR)/config
152
153ADOCPDFEXTS  = -r asciidoctor-pdf -r asciidoctor-mathematical -r $(CURDIR)/config/asciidoctor-mathematical-ext.rb
154ADOCPDFOPTS  = $(ADOCPDFEXTS) -a mathematical-format=svg \
155	       -a imagesoutdir=$(PDFMATHDIR) \
156	       -a pdf-stylesdir=config/themes -a pdf-style=pdf
157
158ADOCVUEXTS = -r $(CURDIR)/config/vu-to-json.rb
159ADOCVUOPTS = $(ADOCVUEXTS)
160
161.PHONY: directories
162
163# Images used by the spec. These are included in generated HTML now.
164IMAGEPATH :=images
165SVGFILES  := $(wildcard $(IMAGEPATH)/*.svg)
166
167# Top-level spec source file
168SPECSRC := vkspec.txt
169# Files making up sections of the API spec. The wildcard expression
170# should work in extension branches to pull in those files as well.
171SPECFILES = $(wildcard chapters/[A-Za-z]*.txt appendices/[A-Za-z]*.txt chapters/*/[A-Za-z]*.txt appendices/*/[A-Za-z]*.txt)
172GENINCLUDE = $(wildcard api/*/[A-Za-z]*.txt validity/*/[A-Za-z]*.txt hostsynctable/*.txt)
173# Shorthand for where the extension appendix generated files go
174METADIR = appendices/meta
175# Generated dependencies of the spec
176GENDEPENDS = api/timeMarker validity/timeMarker hostsynctable/timeMarker $(METADIR)/timeMarker
177# All non-format-specific dependencies
178COMMONDOCS = $(SPECFILES) $(GENINCLUDE) $(GENDEPENDS)
179
180# Install katex in $(OUTDIR)/katex for reference by all HTML targets
181# README.md is a proxy for all the katex files that need to be installed
182katexinst: KATEXDIR = katex
183katexinst: $(OUTDIR)/$(KATEXDIR)/README.md
184
185$(OUTDIR)/$(KATEXDIR)/README.md: katex/README.md
186	$(QUIET)$(MKDIR) $(OUTDIR)
187	$(QUIET)$(RMRF)  $(OUTDIR)/$(KATEXDIR)
188	$(QUIET)$(CP) -rf katex $(OUTDIR)
189
190# Spec targets
191# There is some complexity to try and avoid short virtual targets like 'html'
192# causing specs to *always* be regenerated.
193html: $(HTMLDIR)/vkspec.html $(SPECSRC) $(COMMONDOCS)
194
195$(HTMLDIR)/vkspec.html: KATEXDIR = ../katex
196$(HTMLDIR)/vkspec.html: $(SPECSRC) $(COMMONDOCS) katexinst
197	$(QUIET)$(ASCIIDOC) -b html5 $(ADOCOPTS) $(ADOCHTMLOPTS) -o $@ $(SPECSRC)
198
199diff_html: $(HTMLDIR)/diff.html $(SPECSRC) $(COMMONDOCS)
200
201$(HTMLDIR)/diff.html: KATEXDIR = ../katex
202$(HTMLDIR)/diff.html: $(SPECSRC) $(COMMONDOCS) katexinst
203	$(QUIET)$(ASCIIDOC) -b html5 $(ADOCOPTS) $(ADOCHTMLOPTS) -a diff_extensions="$(DIFFEXTENSIONS)" -r $(CURDIR)/config/extension-highlighter.rb --trace -o $@ $(SPECSRC)
204
205pdf: $(PDFDIR)/vkspec.pdf $(SPECSRC) $(COMMONDOCS)
206
207$(PDFDIR)/vkspec.pdf: $(SPECSRC) $(COMMONDOCS)
208	$(QUIET)$(MKDIR) $(PDFDIR)
209	$(QUIET)$(MKDIR) $(PDFMATHDIR)
210	$(QUIET)$(ASCIIDOC) -b pdf $(ADOCOPTS) $(ADOCPDFOPTS) -o $@ $(SPECSRC)
211ifndef GS_EXISTS
212	$(QUIET) echo "Warning: Ghostscript not installed, skipping pdf optimization"
213else
214	$(QUIET)$(CURDIR)/config/optimize-pdf $@
215	$(QUIET)rm $@
216	$(QUIET)mv $(PDFDIR)/vkspec-optimized.pdf $@
217endif
218	$(QUIET)rm -rf $(PDFMATHDIR)
219
220validusage: $(VUDIR)/validusage.json $(SPECSRC) $(COMMONDOCS)
221
222$(VUDIR)/validusage.json: $(SPECSRC) $(COMMONDOCS)
223	$(QUIET)$(MKDIR) $(VUDIR)
224	$(QUIET)$(ASCIIDOC) $(ADOCOPTS) $(ADOCVUOPTS) --trace -a json_output=$@ -o $@ $(SPECSRC)
225
226# Vulkan Documentation and Extensions, a.k.a. "Style Guide" documentation
227
228STYLESRC = styleguide.txt
229STYLEFILES = $(wildcard style/[A-Za-z]*.txt)
230
231styleguide: $(OUTDIR)/styleguide.html
232
233$(OUTDIR)/styleguide.html: KATEXDIR = katex
234$(OUTDIR)/styleguide.html: $(STYLESRC) $(STYLEFILES) $(GENINCLUDE) $(GENDEPENDS) katexinst
235	$(QUIET)$(MKDIR) $(OUTDIR)
236	$(QUIET)$(ASCIIDOC) -b html5 $(ADOCOPTS) $(ADOCHTMLOPTS) -o $@ $(STYLESRC)
237
238
239# Vulkan API Registry (XML Schema) documentation
240# Currently does not use latexmath / KaTeX
241
242REGSRC = registry.txt
243
244registry: $(OUTDIR)/registry.html
245
246$(OUTDIR)/registry.html: $(REGSRC)
247	$(QUIET)$(MKDIR) $(OUTDIR)
248	$(QUIET)$(ASCIIDOC) -b html5 $(ADOCOPTS) $(ADOCHTMLOPTS) -o $@ $(REGSRC)
249
250
251# Reflow text in spec sources
252REFLOW = reflow.py
253REFLOWOPTS = -overwrite
254
255reflow:
256	$(QUIET) echo "Warning: please verify the spec outputs build without changes!"
257	$(PYTHON) $(REFLOW) $(REFLOWOPTS) $(SPECSRC) $(SPECFILES) $(STYLESRC) $(STYLEFILES)
258
259# Clean generated and output files
260
261clean: clean_html clean_pdf clean_man clean_checks clean_generated clean_validusage
262
263clean_html:
264	$(QUIET)$(RMRF) $(HTMLDIR) $(OUTDIR)/katex
265	$(QUIET)$(RM) $(OUTDIR)/apispec.html $(OUTDIR)/styleguide.html \
266	    $(OUTDIR)/registry.html
267
268clean_pdf:
269	$(QUIET)$(RM) $(PDFDIR)/vkspec.pdf $(OUTDIR)/apispec.pdf
270
271clean_man:
272	$(QUIET)$(RMRF) $(MANHTMLDIR)
273
274clean_checks:
275	$(QUIET)$(RMRF) $(CHECKDIR)
276
277clean_generated:
278	$(QUIET)$(RMRF) api/* hostsynctable/* validity/* $(METADIR)/* vkapi.py
279	$(QUIET)$(RM) config/extDependency.stamp config/extDependency.pyc config/extDependency.sh config/extDependency.py
280	$(QUIET)$(RM) man/apispec.txt $(LOGFILE) man/[Vv][Kk]*.txt man/PFN*.txt
281	$(QUIET)$(RMRF) $(PDFMATHDIR)
282
283clean_validusage:
284	$(QUIET)$(RM) $(VUDIR)/validusage.json
285
286
287# Ref page targets for individual pages
288MANDIR	    := man
289MANSECTION  := 3
290
291# These lists should be autogenerated
292
293# Ref page sources, split up by core API (CORE), KHR extensions (KHR), and
294# other extensions (VEN). This is a hacky approach to ref page generation
295# now that the single-branch model is in place, and there are outstanding
296# issues to resolve it. For the moment, we always just build the core
297# ref pages.
298
299KHRSOURCES   = $(wildcard $(MANDIR)/*KHR.txt)
300MACROSOURCES = $(wildcard $(MANDIR)/VK_*[A-Z][A-Z].txt)
301VENSOURCES   = $(filter-out $(KHRSOURCES) $(MACROSOURCES),$(wildcard $(MANDIR)/*[A-Z][A-Z].txt))
302CORESOURCES  = $(filter-out $(KHRSOURCES) $(VENSOURCES),$(wildcard $(MANDIR)/[Vv][Kk]*.txt $(MANDIR)/PFN*.txt))
303MANSOURCES   = $(CORESOURCES)
304MANCOPYRIGHT = $(MANDIR)/copyright-ccby.txt $(MANDIR)/footer.txt
305
306# Automatic generation of ref pages. Needs to have a proper dependency
307# causing the man page sources to be generated by running genRef (once),
308# but adding $(MANSOURCES) to the targets causes genRef to run
309# once/target.
310#
311# @@ Needs to pass in $(EXTOPTIONS) and use that to determine which
312# pages to generate. As it stands, all the extension ref pages are
313# also generated, though they are not usable at present.
314
315LOGFILE = man/logfile
316man/apispec.txt: $(SPECFILES) genRef.py reflib.py vkapi.py
317	$(PYTHON) genRef.py -log $(LOGFILE) $(SPECFILES)
318
319# These dependencies don't take into account include directives
320
321# These targets are HTML5 ref pages
322
323# The recursive $(MAKE) is an apparently unavoidable hack, since the
324# actual list of man page sources isn't known until after
325# man/apispec.txt is generated.
326manhtmlpages: man/apispec.txt
327	$(MAKE) buildmanpages
328
329# buildmanpages: $(MANSOURCES:$(MANDIR)/%.txt=$(MANHTMLDIR)/%.html)
330
331MANHTMLDIR  = $(OUTDIR)/man/html
332MANHTML     = $(MANSOURCES:$(MANDIR)/%.txt=$(MANHTMLDIR)/%.html)
333buildmanpages: $(MANHTML)
334
335$(MANHTMLDIR)/%.html: KATEXDIR = ../../katex
336$(MANHTMLDIR)/%.html: $(MANDIR)/%.txt $(MANCOPYRIGHT) $(GENINCLUDE) $(GENDEPENDS) katexinst
337	$(QUIET)$(MKDIR) $(MANHTMLDIR)
338	$(QUIET)$(ASCIIDOC) -b html5 -a cross-file-links -a html_spec_relative='../../html/vkspec.html' $(ADOCOPTS) $(ADOCHTMLOPTS) -d manpage -o $@ $<
339
340# These targets are HTML5 and PDF single-file versions of the ref pages
341# The generated ref page sources are included by man/apispec.txt, and
342# are always generated along with man/apispec.txt. Therefore there's no
343# need for a recursive $(MAKE) or a $(MANHTML) dependency, unlike the
344# manhtmlpages target.
345
346manpdf: $(OUTDIR)/apispec.pdf
347
348$(OUTDIR)/apispec.pdf: $(SPECVERSION) man/apispec.txt $(MANCOPYRIGHT) $(SVGFILES) $(GENINCLUDE) $(GENDEPENDS)
349	$(QUIET)$(MKDIR) $(OUTDIR)
350	$(QUIET)$(MKDIR) $(PDFMATHDIR)
351	$(QUIET)$(ASCIIDOC) -b pdf -a html_spec_relative='html/vkspec.html' $(ADOCOPTS) $(ADOCPDFOPTS) -o $@ man/apispec.txt
352ifndef GS_EXISTS
353	$(QUIET) echo "Warning: Ghostscript not installed, skipping pdf optimization"
354else
355	$(QUIET)$(CURDIR)/config/optimize-pdf $@
356	$(QUIET)rm $@
357	$(QUIET)mv $(OUTDIR)/apispec-optimized.pdf $@
358endif
359
360manhtml: $(OUTDIR)/apispec.html
361
362$(OUTDIR)/apispec.html: KATEXDIR = katex
363$(OUTDIR)/apispec.html: $(SPECVERSION) man/apispec.txt $(MANCOPYRIGHT) $(SVGFILES) $(GENINCLUDE) $(GENDEPENDS) katexinst
364	$(QUIET)$(MKDIR) $(OUTDIR)
365	$(QUIET)$(ASCIIDOC) -b html5 -a html_spec_relative='html/vkspec.html' $(ADOCOPTS) $(ADOCHTMLOPTS) -o $@ man/apispec.txt
366
367# Automated (though heuristic) checks of consistency in the spec and
368# ref page sources.
369# These are way out of date WRT current spec markup, and probably won't
370# work properly.
371
372# Validate includes in spec source vs. includes actually in the tree
373# Generates file in $(CHECKDIR)
374#   $(NOTINSPEC) notInSpec.txt - include files only found in XML, not in spec
375# Intermediate files removed after the run
376#   $(ACTUAL) - include files generated from vk.xml
377#   $(INSPEC) - include files referenced from the spec (not ref page) source
378# Other files which could be generated but are basically useless
379#   include files only found in the spec source - comm -13 $(ACTUAL) $(INSPEC)
380#   include files both existing and referenced by the spec - comm -12 $(ACTUAL) $(INSPEC)
381INCFILES = $(CHECKDIR)/incfiles
382ACTUAL = $(CHECKDIR)/actual
383INSPEC = $(CHECKDIR)/inspec
384NOTINSPEC = $(CHECKDIR)/notInSpec.txt
385checkinc:
386	$(QUIET)if test ! -d $(CHECKDIR) ; then $(MKDIR) $(CHECKDIR) ; fi
387	$(QUIET)ls $(GENINCLUDE) | sort > $(ACTUAL)
388	$(QUIET)cat $(SPECFILES) | \
389	    egrep '^include::\.\./' | tr -d '[]' | \
390	    sed -e 's#^include::\.\./##g' | sort > $(INCFILES)
391	$(QUIET)echo "List of API include files repeatedly included in the API specification"  > $(NOTINSPEC)
392	$(QUIET)echo "----------------------------------------------------------------------" >> $(NOTINSPEC)
393	$(QUIET)uniq -d $(INCFILES) >> $(NOTINSPEC)
394	$(QUIET)(echo ; echo "List of API include files not referenced in the API specification") >> $(NOTINSPEC)
395	$(QUIET)echo "-----------------------------------------------------------------" >> $(NOTINSPEC)
396	$(QUIET)comm -23 $(ACTUAL) $(INCFILES) >> $(NOTINSPEC)
397	$(QUIET)echo "Include files not found in the spec source are in $(CHECKDIR)/notInSpec.txt"
398	$(QUIET)$(RM) $(INCFILES) $(ACTUAL) $(INSPEC)
399
400# Validate link tags in spec and ref page sources against vk.xml
401# (represented in vkapi.py, which is autogenerated along with the
402# headers and ref page includes).
403# Generates files in $(CHECKDIR):
404#   specErrs.txt - errors & warnings in API spec
405#   manErrs.txt - errors & warnings in man pages
406checklinks: vkapi.py
407	$(QUIET)if test ! -d $(CHECKDIR) ; then $(MKDIR) $(CHECKDIR) ; fi
408	$(QUIET)echo "Generating link checks for spec (specErrs.txt) and man pages (manErrs.txt)"
409	$(QUIET)$(PYTHON) checkLinks.py -follow man/[Vv][Kk]*.txt > $(CHECKDIR)/manErrs.txt
410	$(QUIET)$(PYTHON) checkLinks.py -follow $(SPECFILES) > $(CHECKDIR)/specErrs.txt
411
412# Targets generated from the XML and registry processing scripts
413#   vkapi.py - Python encoding of the registry
414#   api/timeMarker - proxy for 'apiincludes' - API include files under api/*/*.txt
415#   hostsynctable/timeMarker - proxy for host sync table include files under hostsynctable/*.txt
416#   validity/timeMarker - proxy for API validity include files under validity/*/*.txt
417#   appendices/meta/timeMarker - proxy for extension appendix metadata include files under appendices/*.txt
418#
419# $(VERSIONOPTIONS) specifies the core API versions which are included
420# in these targets, and is set above based on $(VERSIONS)
421#
422# $(EXTOPTIONS) specifies the extensions which are included in these
423# targets, and is set above based on $(EXTENSIONS).
424
425REGISTRY = xml
426VKXML	 = $(REGISTRY)/vk.xml
427GENVK	 = $(REGISTRY)/genvk.py
428GENVKOPTS= $(VERSIONOPTIONS) $(EXTOPTIONS) -registry $(VKXML)
429
430vkapi.py: $(VKXML) $(GENVK)
431	$(PYTHON) $(GENVK) $(GENVKOPTS) -o . vkapi.py
432
433apiinc: api/timeMarker
434
435api/timeMarker: $(VKXML) $(GENVK)
436	$(QUIET)$(MKDIR) api
437	$(QUIET)$(PYTHON) $(GENVK) $(GENVKOPTS) -o api apiinc
438
439hostsyncinc: hostsynctable/timeMarker
440
441hostsynctable/timeMarker: $(VKXML) $(GENVK)
442	$(QUIET)$(MKDIR) hostsynctable
443	$(QUIET)$(PYTHON) $(GENVK) $(GENVKOPTS) -o hostsynctable hostsyncinc
444
445validinc: validity/timeMarker
446
447validity/timeMarker: $(VKXML) $(GENVK)
448	$(QUIET)$(MKDIR) validity
449	$(QUIET)$(PYTHON) $(GENVK) $(GENVKOPTS) -o validity validinc
450
451extinc: $(METADIR)/timeMarker
452
453$(METADIR)/timeMarker: $(VKXML) $(GENVK)
454	$(QUIET)$(MKDIR) $(METADIR)
455	$(QUIET)$(PYTHON) $(GENVK) $(GENVKOPTS) -o $(METADIR) extinc
456
457# Debugging aid - generate all files from registry XML
458# This leaves out config/extDependency.sh intentionally as it only
459# needs to be updated when the extension dependencies in vk.xml change.
460
461generated: vkapi.py api/timeMarker hostsynctable/timeMarker validity/timeMarker $(METADIR)/timeMarker
462
463# Extension dependencies derived from vk.xml
464# Both Bash and Python versions are generated
465
466config/extDependency.sh: config/extDependency.stamp
467config/extDependency.py: config/extDependency.stamp
468
469DEPSCRIPT = $(REGISTRY)/extDependency.py
470config/extDependency.stamp: $(VKXML) $(DEPSCRIPT)
471	$(QUIET)$(PYTHON) $(DEPSCRIPT) -registry $(VKXML) \
472	    -outscript config/extDependency.sh \
473	    -outpy config/extDependency.py
474	$(QUIET)touch $@
475