@@ -287,6 +287,39 @@ if pandoc.found() and xsltproc_bin.found()
287287 alldocs += postgres_epub
288288endif
289289
290+
291+ ##
292+ ## Experimental Texinfo targets
293+ ##
294+
295+ db2x_xsltproc = find_program (' db2x_xsltproc' , native : true , required : false )
296+ db2x_texixml = find_program (' db2x_texixml' , native : true , required : false )
297+ makeinfo = find_program (' makeinfo' , native : true , required : false )
298+
299+ if db2x_texixml.found() and db2x_xsltproc.found() and makeinfo.found()
300+ postgres_texixml = custom_target (' postgres.texixml' ,
301+ output : ' postgres.texixml' ,
302+ command : [db2x_xsltproc, ' -s' , ' texi' ,
303+ ' -g' , ' output-file=postgres' ,
304+ postgres_full_xml, ' -o' , ' @OUTPUT@' ],
305+ build_by_default : false ,
306+ )
307+ postgres_texi = custom_target (' postgres.texi' ,
308+ output : ' postgres.texi' ,
309+ command : [db2x_texixml, ' --encoding=utf-8' , postgres_texixml,
310+ ' --output-dir=@OUTDIR@' ],
311+ build_by_default : false ,
312+ )
313+ postgres_info = custom_target (' postgres.info' ,
314+ output : ' postgres.info' ,
315+ command : [makeinfo, ' --enable-encoding' , ' --no-split' , ' --no-validate' ,
316+ postgres_texi, ' -o' , ' @OUTPUT0@' ],
317+ build_by_default : false ,
318+ )
319+ alldocs += postgres_info
320+ endif
321+
322+
290323if docs.length() == 0
291324 run_target (' docs' , command : [missing, ' xsltproc' ])
292325else
0 commit comments