diff options
-rw-r--r-- | configure.ac | 18 | ||||
-rw-r--r-- | contrib/packages/guix/guix-env-gillmann.scm | 40 | ||||
-rw-r--r-- | doc/documentation/Makefile.am | 12 | ||||
-rw-r--r-- | doc/man/Makefile.am | 5 |
4 files changed, 64 insertions, 11 deletions
diff --git a/configure.ac b/configure.ac index 10991e574..3be070b91 100644 --- a/configure.ac +++ b/configure.ac | |||
@@ -688,6 +688,24 @@ else | |||
688 | AC_DEFINE([DOCUMENTATION],[0],[Not building the documentation]) | 688 | AC_DEFINE([DOCUMENTATION],[0],[Not building the documentation]) |
689 | fi | 689 | fi |
690 | 690 | ||
691 | # TODO: Include check for mandoc + texi2mdoc. | ||
692 | # TODO: Rename the switch? Just 'section7' is too vague. | ||
693 | # mdoc section 7 output. | ||
694 | AC_MSG_CHECKING(wether to build section 7 mdoc output) | ||
695 | AC_ARG_ENABLE([section7], | ||
696 | [AS_HELP_STRING([--disable-section7], [do not build section 7 mdoc output])], | ||
697 | [section7=${enableval}], | ||
698 | [section7=yes]) | ||
699 | AC_MSG_RESULT($section7) | ||
700 | if test "x$section7" = "xyes" | ||
701 | then | ||
702 | AM_CONDITIONAL([SECTION7],true) | ||
703 | AC_DEFINE([SECTION7],[1],[Building section 7 mdoc output]) | ||
704 | else | ||
705 | AM_CONDITIONAL([SECTION7],false) | ||
706 | AC_DEFINE([SECTION7],[0],[Not building section 7 mdoc output]) | ||
707 | fi | ||
708 | |||
691 | # should the build process be building only the documentation? | 709 | # should the build process be building only the documentation? |
692 | AC_MSG_CHECKING(whether to build only documentation) | 710 | AC_MSG_CHECKING(whether to build only documentation) |
693 | AC_ARG_ENABLE([documentation-only], | 711 | AC_ARG_ENABLE([documentation-only], |
diff --git a/contrib/packages/guix/guix-env-gillmann.scm b/contrib/packages/guix/guix-env-gillmann.scm index 4b977c1bb..3951620e8 100644 --- a/contrib/packages/guix/guix-env-gillmann.scm +++ b/contrib/packages/guix/guix-env-gillmann.scm | |||
@@ -64,6 +64,8 @@ | |||
64 | (gnu packages video) | 64 | (gnu packages video) |
65 | (gnu packages web) | 65 | (gnu packages web) |
66 | (gnu packages xiph) | 66 | (gnu packages xiph) |
67 | (ports app-text mandoc mandoc) | ||
68 | (ports app-text texi2mdoc texi2mdoc) | ||
67 | ((guix licenses) #:prefix license:)) | 69 | ((guix licenses) #:prefix license:)) |
68 | 70 | ||
69 | (define %source-dir (current-source-directory)) | 71 | (define %source-dir (current-source-directory)) |
@@ -119,17 +121,20 @@ | |||
119 | ("automake" ,automake) | 121 | ("automake" ,automake) |
120 | ("gnu-gettext" ,gnu-gettext) | 122 | ("gnu-gettext" ,gnu-gettext) |
121 | ("which" ,which) | 123 | ("which" ,which) |
124 | ("mandoc" ,mandoc) | ||
125 | ("texi2mdoc" ,texi2mdoc) | ||
122 | ("texinfo" ,texinfo-5) ; Debian stable: 5.2 | 126 | ("texinfo" ,texinfo-5) ; Debian stable: 5.2 |
123 | ("libtool" ,libtool))) | 127 | ("libtool" ,libtool))) |
124 | (outputs '("out" "debug")) | 128 | (outputs '("out" "debug")) |
129 | ;;#:configure-flags | ||
130 | ;;(list (string-append "--with-nssdir=" %output "/lib") | ||
131 | ;;"--enable-gcc-hardening" | ||
132 | ;;"--enable-linker-hardening" | ||
133 | ;;;;"--enable-documentation-only") | ||
134 | ;;;"--enable-logging=verbose" | ||
135 | ;;;"CFLAGS=-ggdb -O0") | ||
125 | (arguments | 136 | (arguments |
126 | `(;#:configure-flags | 137 | `(#:configure-flags (list "--enable-section7") |
127 | ;;(list (string-append "--with-nssdir=" %output "/lib") | ||
128 | ;;"--enable-gcc-hardening" | ||
129 | ;;"--enable-linker-hardening" | ||
130 | ;;;;"--enable-documentation-only") | ||
131 | ;;;"--enable-logging=verbose" | ||
132 | ;;;"CFLAGS=-ggdb -O0") | ||
133 | #:phases | 138 | #:phases |
134 | ;; swap check and install phases and set paths to installed bin | 139 | ;; swap check and install phases and set paths to installed bin |
135 | (modify-phases %standard-phases | 140 | (modify-phases %standard-phases |
@@ -140,12 +145,25 @@ | |||
140 | #t)) | 145 | #t)) |
141 | (add-after 'patch-bin-sh 'bootstrap | 146 | (add-after 'patch-bin-sh 'bootstrap |
142 | (lambda _ | 147 | (lambda _ |
143 | (zero? (system* "sh" "bootstrap")))) | 148 | (invoke "sh" "bootstrap"))) |
149 | (add-after 'build 'install-section7 | ||
150 | (lambda _ | ||
151 | (with-directory-excursion "doc/documentation" | ||
152 | (invoke "make" "gnunet-c-tutorial.7") | ||
153 | (invoke "make" "gnunet-documentation.7") | ||
154 | (mkdir-p (string-append (assoc-ref %outputs "out") | ||
155 | "/share/man/man7")) | ||
156 | (copy-file "../man/gnunet-c-tutorial.7" | ||
157 | (string-append (assoc-ref %outputs "out") | ||
158 | "/share/man/man7/gnunet-c-tutorial.7")) | ||
159 | (copy-file "../man/gnunet-documentation.7" | ||
160 | (string-append (assoc-ref %outputs "out") | ||
161 | "/share/man/man7/gnunet-documentation.7"))))) | ||
144 | ;;(add-before 'build 'chdir | 162 | ;;(add-before 'build 'chdir |
145 | ;; (lambda _ | 163 | ;; (lambda _ |
146 | ;; (chdir "doc/documentation"))) | 164 | ;; (chdir "doc/documentation"))) |
147 | (delete 'check) | 165 | (delete 'check))))))) |
148 | ;; XXX: https://gnunet.org/bugs/view.php?id=4619 | 166 | ;; XXX: https://gnunet.org/bugs/view.php?id=4619 |
149 | )))))) | 167 | |
150 | 168 | ||
151 | gnunet-dev-env | 169 | gnunet-dev-env |
diff --git a/doc/documentation/Makefile.am b/doc/documentation/Makefile.am index b6c666c4d..0032b22e9 100644 --- a/doc/documentation/Makefile.am +++ b/doc/documentation/Makefile.am | |||
@@ -175,6 +175,18 @@ version2.texi: | |||
175 | echo "@set EDITION $(PACKAGE_VERSION)" >> $@ | 175 | echo "@set EDITION $(PACKAGE_VERSION)" >> $@ |
176 | echo "@set VERSION $(PACKAGE_VERSION)" >> $@ | 176 | echo "@set VERSION $(PACKAGE_VERSION)" >> $@ |
177 | 177 | ||
178 | if SECTION7 | ||
179 | gnunet-c-tutorial.7: version2.texi | ||
180 | @echo Attempting to output an mdoc formatted section 7 document | ||
181 | @texi2mdoc -I$(pwd):$(pwd)/chapters gnunet-c-tutorial.texi > ../man/gnunet-c-tutorial.7 | ||
182 | |||
183 | gnunet-documentation.7: version2.texi | ||
184 | @echo Attempting to output an mdoc formatted section 7 document | ||
185 | @texi2mdoc -I$(pwd):$(pwd)/chapters gnunet.texi > ../man/gnunet-documentation.7 | ||
186 | |||
187 | # TODO: (Maybe) other outputs resulting from this. | ||
188 | endif | ||
189 | |||
178 | # FIXME: rm *.html and *.pdf | 190 | # FIXME: rm *.html and *.pdf |
179 | #doc-clean: | 191 | #doc-clean: |
180 | # @rm *.aux *.log *.toc *.cp *.cps | 192 | # @rm *.aux *.log *.toc *.cp *.cps |
diff --git a/doc/man/Makefile.am b/doc/man/Makefile.am index 37f881d60..d0871571d 100644 --- a/doc/man/Makefile.am +++ b/doc/man/Makefile.am | |||
@@ -46,3 +46,8 @@ man_MANS = \ | |||
46 | gnunet-zoneimport.1 | 46 | gnunet-zoneimport.1 |
47 | 47 | ||
48 | EXTRA_DIST = ${man_MANS} | 48 | EXTRA_DIST = ${man_MANS} |
49 | |||
50 | if SECTION7 | ||
51 | EXTRA_DIST += gnunet-documentation.7 \ | ||
52 | gnunet-c-tutorial.7 | ||
53 | endif | ||