Skip to contentSkip to conversation

doc: fix doc build with latest meson

PATCH Applied Bruce Richardson 3 participants 6 messages Jul 5, 2019 Arm/Amlogic Meson SoC support

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 doc: fix doc build with latest meson

The latest versions of meson don't build targets when build_by_default is false but install is true, unlike older versions. We can fix this by having both build_by_default and install settings come from the build-time option.

Bugzilla ID: 303

Fixes d02a2dab2dfb ("doc: support building HTML guides with meson")
Fixes 720b14db3ae2 ("build: generate API documentation with meson")
---
 doc/api/meson.build    | 4 ++--
 doc/guides/meson.build | 2 +-
 2 files changed, 3 insertions(+), 3 deletions(-)
doc/api/meson.build +2 -2
index 30bdc573b..1c48b7672 100644
@@ -26,7 +26,7 @@ if doxygen.found()
 		command: [generate_examples, '@INPUT@', '@OUTPUT@'],
 		install: get_option('enable_docs'),
 		install_dir: htmldir,
-		build_by_default: false)
+		build_by_default: get_option('enable_docs'))
 
 	cdata = configuration_data()
 	cdata.set('VERSION', meson.project_version())
@@ -48,7 +48,7 @@ if doxygen.found()
 		command: [generate_doxygen, '@INPUT@', '@OUTPUT@', generate_css],
 		install: get_option('enable_docs'),
 		install_dir: htmldir,
-		build_by_default: false)
+		build_by_default: get_option('enable_docs'))
 
 	doc_targets += doxy_build
 	doc_target_names += 'Doxygen_API'
doc/guides/meson.build +1 -1
index 06f14882b..7931ef3bb 100644
@@ -11,7 +11,7 @@ if sphinx.found()
 		command: [sphinx, '-b', 'html',
 			'-d', meson.current_build_dir() + '/.doctrees',
 			'@INPUT@', meson.current_build_dir() + '/guides'],
-		build_by_default: false,
+		build_by_default: get_option('enable_docs'),
 		install: get_option('enable_docs'),
 		install_dir: htmldir)
 
Signature · 1 line
2.21.0
#1 lore raw
Quoted 60 lines · Bruce Richardson

The latest versions of meson don't build targets when build_by_default is
false but install is true, unlike older versions. We can fix this by having
both build_by_default and install settings come from the build-time option.

Bugzilla ID: 303

Fixes d02a2dab2dfb ("doc: support building HTML guides with meson")
Fixes 720b14db3ae2 ("build: generate API documentation with meson")

Cc:
[email protected]

Cc:
[email protected]

Cc:
[email protected]

Reported-by: Ali Alnubani <
[email protected]

Quoted 1 line

Signed-off-by: Bruce Richardson <
[email protected]

Quoted 1 line
---
 doc/api/meson.build    | 4 ++--
 doc/guides/meson.build | 2 +-
 2 files changed, 3 insertions(+), 3 deletions(-)
doc/api/meson.build +2 -2
index 30bdc573b..1c48b7672 100644
@@ -26,7 +26,7 @@ if doxygen.found()
 		command: [generate_examples, '@INPUT@', '@OUTPUT@'],
 		install: get_option('enable_docs'),
 		install_dir: htmldir,
-		build_by_default: false)
+		build_by_default: get_option('enable_docs'))
 
 	cdata = configuration_data()
 	cdata.set('VERSION', meson.project_version())
@@ -48,7 +48,7 @@ if doxygen.found()
 		command: [generate_doxygen, '@INPUT@', '@OUTPUT@',
 generate_css],
 		install: get_option('enable_docs'),
 		install_dir: htmldir,
-		build_by_default: false)
+		build_by_default: get_option('enable_docs'))
 
 	doc_targets += doxy_build
doc/api/meson.build +0 -0
 	doc_target_names += 'Doxygen_API'
doc/guides/meson.build +0 -0
index 06f14882b..7931ef3bb 100644

doc/guides/meson.build if sphinx.found() · line 17

Quoted 8 lines
doc/guides/meson.build +1 -1
@@ -11,7 +11,7 @@ if sphinx.found()
 		command: [sphinx, '-b', 'html',
 			'-d', meson.current_build_dir() + '/.doctrees',
 			'@INPUT@', meson.current_build_dir() +
 '/guides'],
-		build_by_default: false,
+		build_by_default: get_option('enable_docs'),
 		install: get_option('enable_docs'),
 		install_dir: htmldir)

Mmh why do I feel a deja-vu? Did we already fix this in the past?

Signature · 2 lines
Kind regards,
Luca Boccassi
#2 lore raw
Quoted 71 lines · Luca Boccassi
Quoted 70 lines · Bruce Richardson

The latest versions of meson don't build targets when build_by_default is
false but install is true, unlike older versions. We can fix this by
having
both build_by_default and install settings come from the build-time option.

Bugzilla ID: 303

Fixes d02a2dab2dfb ("doc: support building HTML guides with

meson")

Fixes 720b14db3ae2 ("build: generate API documentation with

meson")
Cc:
[email protected]

Cc:
[email protected]

Cc:
[email protected]

Reported-by: Ali Alnubani <
[email protected]

Signed-off-by: Bruce Richardson <
[email protected]

---
 doc/api/meson.build    | 4 ++--
 doc/guides/meson.build | 2 +-
 2 files changed, 3 insertions(+), 3 deletions(-)
doc/api/meson.build +2 -2
index 30bdc573b..1c48b7672 100644
@@ -26,7 +26,7 @@ if doxygen.found()
 		command: [generate_examples, '@INPUT@', '@OUTPUT@'],
 		install: get_option('enable_docs'),
 		install_dir: htmldir,
-		build_by_default: false)
+		build_by_default: get_option('enable_docs'))
 
 	cdata = configuration_data()
 	cdata.set('VERSION', meson.project_version())
@@ -48,7 +48,7 @@ if doxygen.found()
 		command: [generate_doxygen, '@INPUT@', '@OUTPUT@',
 generate_css],
 		install: get_option('enable_docs'),
 		install_dir: htmldir,
-		build_by_default: false)
+		build_by_default: get_option('enable_docs'))
 
 	doc_targets += doxy_build
doc/api/meson.build +0 -0
 	doc_target_names += 'Doxygen_API'
doc/guides/meson.build +0 -0
index 06f14882b..7931ef3bb 100644
@@ -11,7 +11,7 @@ if sphinx.found()
 		command: [sphinx, '-b', 'html',
 			'-d', meson.current_build_dir() + '/.doctrees',
 			'@INPUT@', meson.current_build_dir() +
Quoted 8 lines

doc/guides/meson.build if sphinx.found() · line 16

Quoted 6 lines
doc/guides/meson.build +1 -1
 '/guides'],
-		build_by_default: false,
+		build_by_default: get_option('enable_docs'),
 		install: get_option('enable_docs'),
 		install_dir: htmldir)

Mmh why do I feel a deja-vu? Did we already fix this in the past?

lol it's my fault that's why: https://github.com/mesonbuild/meson/commit/267792174c9921e6be296086b0c806a684432a1b

Signature · 2 lines
Kind regards,
Luca Boccassi
#3 lore raw
Quoted 81 lines · Luca Boccassi
Quoted 71 lines · Luca Boccassi
Quoted 70 lines · Bruce Richardson

The latest versions of meson don't build targets when build_by_default is
false but install is true, unlike older versions. We can fix this by
having
both build_by_default and install settings come from the build-time option.

Bugzilla ID: 303

Fixes d02a2dab2dfb ("doc: support building HTML guides with

meson")

Fixes 720b14db3ae2 ("build: generate API documentation with

meson")
Cc:
[email protected]

Cc:
[email protected]

Cc:
[email protected]

Reported-by: Ali Alnubani <
[email protected]

Signed-off-by: Bruce Richardson <
[email protected]

---
 doc/api/meson.build    | 4 ++--
 doc/guides/meson.build | 2 +-
 2 files changed, 3 insertions(+), 3 deletions(-)
doc/api/meson.build +2 -2
index 30bdc573b..1c48b7672 100644
@@ -26,7 +26,7 @@ if doxygen.found()
 		command: [generate_examples, '@INPUT@', '@OUTPUT@'],
 		install: get_option('enable_docs'),
 		install_dir: htmldir,
-		build_by_default: false)
+		build_by_default: get_option('enable_docs'))
 
 	cdata = configuration_data()
 	cdata.set('VERSION', meson.project_version())
@@ -48,7 +48,7 @@ if doxygen.found()
 		command: [generate_doxygen, '@INPUT@', '@OUTPUT@',
 generate_css],
 		install: get_option('enable_docs'),
 		install_dir: htmldir,
-		build_by_default: false)
+		build_by_default: get_option('enable_docs'))
 
 	doc_targets += doxy_build
doc/api/meson.build +0 -0
 	doc_target_names += 'Doxygen_API'
doc/guides/meson.build +0 -0
index 06f14882b..7931ef3bb 100644
@@ -11,7 +11,7 @@ if sphinx.found()
 		command: [sphinx, '-b', 'html',
 			'-d', meson.current_build_dir() + '/.doctrees',
 			'@INPUT@', meson.current_build_dir() +
Quoted 8 lines

doc/guides/meson.build if sphinx.found() · line 16

Quoted 6 lines
doc/guides/meson.build +1 -1
 '/guides'],
-		build_by_default: false,
+		build_by_default: get_option('enable_docs'),
 		install: get_option('enable_docs'),
 		install_dir: htmldir)

Mmh why do I feel a deja-vu? Did we already fix this in the past?

Quoted 2 lines

lol it's my fault that's why: https://github.com/mesonbuild/meson/commit/267792174c9921e6be296086b0c806a684432a1b

Ok, good to know. Thomas can add a "Blame-it-on:" tag when applying :-)

Acked-by on v1 1/1
#4 lore raw
In reply to Bruce Richardson
Quoted 23 lines · Bruce Richardson

The latest versions of meson don't build targets when build_by_default is
false but install is true, unlike older versions. We can fix this by having
both build_by_default and install settings come from the build-time option.

Bugzilla ID: 303

Fixes d02a2dab2dfb ("doc: support building HTML guides with meson")
Fixes 720b14db3ae2 ("build: generate API documentation with meson")

Cc:
[email protected]

Cc:
[email protected]

Cc:
[email protected]

Reported-by: Ali Alnubani <
[email protected]

Quoted 1 line
Quoted 7 lines

Signed-off-by: Bruce Richardson <
[email protected]

Quoted 1 line
---
 doc/api/meson.build    | 4 ++--
 doc/guides/meson.build | 2 +-
 2 files changed, 3 insertions(+), 3 deletions(-)
Signature · 2 lines
Kind regards,
Luca Boccassi
#5 lore raw

05/07/2019 18:31, Luca Boccassi:

Quoted 15 lines · Bruce Richardson
Quoted 14 lines

The latest versions of meson don't build targets when build_by_default is
false but install is true, unlike older versions. We can fix this by having
both build_by_default and install settings come from the build-time option.

Bugzilla ID: 303

Fixes d02a2dab2dfb ("doc: support building HTML guides with meson")
Fixes 720b14db3ae2 ("build: generate API documentation with meson")
Quoted 4 lines
Quoted 2 lines

Applied, thanks