public inbox for [email protected]
help / color / mirror / Atom feedFrom: Andres Freund <[email protected]>
Subject: [PATCH v1 3/5] wip: meson: add install-{docs,doc-html,doc-man} targets
Date: Wed, 15 Mar 2023 16:43:40 -0700
---
meson.build | 2 +-
doc/src/sgml/meson.build | 27 ++++++++++++++++++++++++++-
2 files changed, 27 insertions(+), 2 deletions(-)
diff --git a/meson.build b/meson.build
index b4b87f1a9fc..0ffeffa9edc 100644
--- a/meson.build
+++ b/meson.build
@@ -504,7 +504,7 @@ dir_man = get_option('mandir')
# FIXME: These used to be separately configurable - worth adding?
dir_doc = get_option('datadir') / 'doc' / 'postgresql'
-dir_doc_html = dir_doc
+dir_doc_html = dir_doc / 'html'
dir_locale = get_option('localedir')
diff --git a/doc/src/sgml/meson.build b/doc/src/sgml/meson.build
index e6fe124c7bc..2da737c8af4 100644
--- a/doc/src/sgml/meson.build
+++ b/doc/src/sgml/meson.build
@@ -1,6 +1,7 @@
# Copyright (c) 2022-2023, PostgreSQL Global Development Group
docs = []
+installdocs = []
alldocs = []
doc_generated = []
@@ -120,8 +121,16 @@ if xsltproc_bin.found()
)
alldocs += html
- # build multi-page html docs as part of docs target
+ install_doc_html = run_target('install-doc-html',
+ command: [
+ python, install_files, '--prefix', dir_prefix,
+ '--install-dir-contents', dir_doc_html, html.full_path()],
+ depends: html)
+
+ # build and install multi-page html docs as part of docs target
docs += html
+ installdocs += install_doc_html
+
htmlhelp = custom_target('htmlhelp',
input: ['stylesheet-hh.xsl', postgres_full_xml],
@@ -208,6 +217,21 @@ if xsltproc_bin.found()
build_by_default: false,
)
alldocs += man
+
+ mans = []
+ foreach man_n : man.to_list()
+ mans += man_n.full_path()
+ endforeach
+
+ install_doc_man = run_target('install-doc-man',
+ command: [
+ python, install_files, '--prefix', dir_prefix,
+ '--install-dirs', dir_man, mans],
+ depends: man)
+
+ # even though we don't want to build man pages as part of 'docs', we do want
+ # to install them as part of install-docs
+ installdocs += install_doc_man
endif
@@ -266,6 +290,7 @@ if docs.length() == 0
run_target('docs', command: [missing, 'xsltproc'])
else
alias_target('docs', docs)
+ alias_target('install-docs', installdocs)
endif
if alldocs.length() == 0
--
2.38.0
--vw474qzskdrrkpyy
Content-Type: text/x-diff; charset=us-ascii
Content-Disposition: attachment;
filename="v1-0004-docs-html-copy-images-to-output-as-part-of-xslt-b.patch"
view thread (4+ messages) latest in thread
reply
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: [email protected]
Cc: [email protected]
Subject: Re: [PATCH v1 3/5] wip: meson: add install-{docs,doc-html,doc-man} targets
In-Reply-To: <no-message-id-1857951@localhost>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox