[dia: 13/105] #19: Build dia.1 and dia.pdf.



commit 5dd5c6537f1cc2b0fb0f2a8f6ad684a1f3fcbd28
Author: Eduard Nicodei <eddnicodei gmail com>
Date:   Mon Dec 17 23:59:28 2018 +0000

    #19: Build dia.1 and dia.pdf.
    
      - Also add Makefile-html for easy html generation.

 doc/en/Makefile-html | 14 ++++++++++++++
 doc/en/meson.build   | 17 +++++++++++++++++
 doc/meson.build      |  6 ++++++
 meson.build          |  1 +
 4 files changed, 38 insertions(+)
---
diff --git a/doc/en/Makefile-html b/doc/en/Makefile-html
new file mode 100644
index 00000000..30aff1fa
--- /dev/null
+++ b/doc/en/Makefile-html
@@ -0,0 +1,14 @@
+dia_html: dia.xml html.xsl ../html graphics
+       mkdir ./dia_html
+       mkdir ./dia_html/graphics
+       mkdir ./dia_html/images
+       mkdir ./dia_html/images/callouts
+       mkdir ./dia_html/css
+       cp ../html/images/*.png ./dia_html/images
+       cp ../html/images/callouts/*.png ./dia_html/images/callouts
+       cp ../html/css/*.css ./dia_html/css
+       cp ./graphics/*.png ./dia_html/graphics
+       cd ./dia_html \
+         && xsltproc --stringparam graphic.default.extension png \
+           ../html.xsl ../dia.xml
+
diff --git a/doc/en/meson.build b/doc/en/meson.build
new file mode 100644
index 00000000..bb9f7372
--- /dev/null
+++ b/doc/en/meson.build
@@ -0,0 +1,17 @@
+# TODO: we need to generate dependecies for dia.xml.
+doc_pdf = custom_target('dia.pdf',
+    output : 'dia.pdf',
+    input  : 'dia.xml',
+    command : [dblatex, '-t', 'pdf', '-q', '-o', '@OUTPUT@', '@INPUT@'],
+    install : true,
+    install_dir : 'doc'
+)
+
+xsltproc = find_program('xsltproc')
+manpage = custom_target('dia.1',
+    output : 'dia.1',
+    input  : 'dia.dbk',
+    command : [xsltproc, '--novalid', '--output', '@OUTPUT@', DBMAN, '@INPUT@'],
+    install : true,
+    install_dir : 'doc'
+)
diff --git a/doc/meson.build b/doc/meson.build
new file mode 100644
index 00000000..d2062cf1
--- /dev/null
+++ b/doc/meson.build
@@ -0,0 +1,6 @@
+dblatex = find_program('dblatex')
+
+DBMAN = 'http://docbook.sourceforge.net/release/xsl/current/manpages/docbook.xsl'
+
+subdir('en')
+
diff --git a/meson.build b/meson.build
index 97da7256..9bc891de 100644
--- a/meson.build
+++ b/meson.build
@@ -62,3 +62,4 @@ add_project_arguments('-DHAVE_CONFIG_H', language : 'c')
 subdir('lib')
 subdir('objects')
 subdir('app')
+subdir('doc')


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]