From: Peter Eisentraut <peter.eisentraut@enterprisedb.com>
To: Andres Freund <andres@anarazel.de>
Cc: pgsql-hackers@postgresql.org, samay sharma <smilingsamay@gmail.com>
Cc: Nazir Bilal Yavuz <byavuz81@gmail.com>
Subject: Re: [RFC] building postgres with meson - v12
Date: Wed, 7 Sep 2022 09:19:51 +0200
Message-ID: <a56cebc5-47cd-45e7-d08b-a6c21778f42c@enterprisedb.com> (raw)
In-Reply-To: <20220831181154.ebqkjahjzs5bttfa@awork3.anarazel.de>
References: <20211012083721.hvixq4pnh2pixr3j@alap3.anarazel.de>
<20220827180447.zbmfk6sp2af4ntio@awork3.anarazel.de>
<2180a97c-c026-1b6c-cec8-d6e499f97017@enterprisedb.com>
<20220831181154.ebqkjahjzs5bttfa@awork3.anarazel.de>
On 31.08.22 20:11, Andres Freund wrote:
>> doc/src/sgml/resolv.xsl: I don't understand what this is doing. Maybe
>> at least add a comment in the file.
> It's only used for building epubs. Perhaps I should extract that into a
> separate patch as well? The relevant section is:
>
>> #
>> # epub
>> #
>>
>> # This was previously implemented using dbtoepub - but that doesn't seem to
>> # support running in build != source directory (i.e. VPATH builds already
>> # weren't supported).
>> if pandoc.found() and xsltproc.found()
>> # XXX: Wasn't able to make pandoc successfully resolve entities
>> # XXX: Perhaps we should just make all targets use this, to avoid repeatedly
>> # building whole thing? It's comparatively fast though.
>> postgres_full_xml = custom_target('postgres-full.xml',
>> input: ['resolv.xsl', 'postgres.sgml'],
>> output: ['postgres-full.xml'],
>> depends: doc_generated + [postgres_sgml_valid],
>> command: [xsltproc, '--path', '@OUTDIR@/', xsltproc_flags,
>> '-o', '@OUTPUT@', '@INPUT@'],
>> build_by_default: false,
>> )
> A noted, I couldn't make pandoc resolve our entities, so I used resolv.xsl
> them, before calling pandoc.
>
> I'll rename it to resolve-entities.xsl and add a comment.
We can have xmllint do this. The following gets the epub build working
with vpath:
inline patch 1: doc/src/sgml/Makefile (+0/-0 lines) download inline-1.patchdiff --git a/doc/src/sgml/Makefile b/doc/src/sgml/Makefileindex 4ae7ca2be7..33b72d03db 100644--- a/doc/src/sgml/Makefile+++ b/doc/src/sgml/Makefile@@ -184,8 +184,12 @@ XSLTPROC_FO_FLAGS += --stringparam img.src.path '$(srcdir)/'
epub: postgres.epub
postgres.epub: postgres.sgml $(ALLSGML) $(ALL_IMAGES)
- $(XMLLINT) --noout --valid $<
- $(DBTOEPUB) -o $@ $<
+ $(XMLLINT) $(XMLINCLUDE) --output tmp.sgml --noent --valid $<
+ifeq ($(vpath_build),yes)
+ $(MKDIR_P) images
+ cp $(ALL_IMAGES) images/
+endif
+ $(DBTOEPUB) -o $@ tmp.sgml
This could also be combined with the idea of the postgres.sgml.valid
thing you have in the meson patch set.
I'll finish this up and produce a proper patch.
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: pgsql-hackers@postgresql.org
Cc: peter.eisentraut@enterprisedb.com, andres@anarazel.de, smilingsamay@gmail.com, byavuz81@gmail.com
Subject: Re: [RFC] building postgres with meson - v12
In-Reply-To: <a56cebc5-47cd-45e7-d08b-a6c21778f42c@enterprisedb.com>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox