mirror of
https://git.freebsd.org/ports.git
synced 2025-07-15 16:29:15 -04:00
Port changes: * Changed to DISTVERSION * Now uses meson instead of configure/make * Added the MANPAGES option, manpage now is built by py-sphinx * Removed targets that are now done by meson PR: 226219 Submitted by: Zsolt Udvari <uzsolt@uzsolt.hu> (maintainer) Approved by: tcberner (mentor, implicit) Differential Revision: https://reviews.freebsd.org/D14531
43 lines
1.4 KiB
Text
43 lines
1.4 KiB
Text
--- doc/meson.build.orig 2018-02-11 12:01:23 UTC
|
|
+++ doc/meson.build
|
|
@@ -1,23 +1,27 @@
|
|
-sphinx = find_program('sphinx-build', required:false)
|
|
|
|
-if sphinx.found()
|
|
- custom_target(
|
|
- 'HTML documentation',
|
|
- output: 'html',
|
|
- input: ['index.rst', 'conf.py'],
|
|
- command: [sphinx, '-q', '-b', 'html', '-d', '@OUTDIR@/doctrees', meson.current_source_dir(), '@OUTPUT@'],
|
|
- build_by_default: true,
|
|
- install: true,
|
|
- install_dir: join_paths(get_option('datadir'), 'doc', meson.project_name()),
|
|
- )
|
|
+use_sphinx = get_option('use_sphinx')
|
|
+
|
|
+if use_sphinx == 'false'
|
|
+ use_sphinx = false
|
|
+elif use_sphinx == 'true'
|
|
+ sphinx = find_program('sphinx-build', required:false)
|
|
+ if not sphinx.found()
|
|
+ error('can\'t find sphinx')
|
|
+ endif
|
|
+ use_sphinx = true
|
|
+else
|
|
+ sphinx = find_program('sphinx-build', required:false)
|
|
+ use_sphinx = sphinx.found()
|
|
+endif
|
|
|
|
+if use_sphinx
|
|
custom_target(
|
|
'Manpage documentation',
|
|
output: 'man',
|
|
input: ['index.rst', 'conf.py'],
|
|
- command: [sphinx, '-q', '-b', 'man', '-d', '@OUTDIR@/doctrees', meson.current_source_dir(), '@OUTPUT@'],
|
|
+ command: [sphinx, '-q', '-b', 'man', '-d', '@OUTDIR@/doctrees', meson.current_source_dir(), '@OUTPUT@/man1'],
|
|
build_by_default: true,
|
|
install: true,
|
|
- install_dir: join_paths(get_option('datadir'), 'man', 'man1'),
|
|
+ install_dir: join_paths(get_option('mandir')),
|
|
)
|
|
endif
|