* [Buildroot] [PATCH] doxygen: fix a build issue
@ 2017-06-26 9:20 Bartosz Golaszewski
2017-06-26 9:20 ` Bartosz Golaszewski
0 siblings, 1 reply; 3+ messages in thread
From: Bartosz Golaszewski @ 2017-06-26 9:20 UTC (permalink / raw)
To: buildroot
I have submitted this fix for upstream inclusion, but I don't know how
long it will take for the maintainers to respond. In the meantime I'm
still getting these build reports everyday on my e-mail.
This patch fixes the doxygen build issues by fixing a script generating
a C header file. The script redirects its stderr to the generated file
so any warning emitted by it or its child processes ends up in this
very file. This is obviously broken and needs to be changed.
Bartosz Golaszewski (1):
doxygen: fix a build issue
...build-fix-the-way-lang_cfg.h-is-generated.patch | 58 ++++++++++++++++++++++
1 file changed, 58 insertions(+)
create mode 100644 package/doxygen/0002-build-fix-the-way-lang_cfg.h-is-generated.patch
--
2.9.3
^ permalink raw reply [flat|nested] 3+ messages in thread
* [Buildroot] [PATCH] doxygen: fix a build issue
2017-06-26 9:20 [Buildroot] [PATCH] doxygen: fix a build issue Bartosz Golaszewski
@ 2017-06-26 9:20 ` Bartosz Golaszewski
2017-07-02 16:38 ` Peter Korsgaard
0 siblings, 1 reply; 3+ messages in thread
From: Bartosz Golaszewski @ 2017-06-26 9:20 UTC (permalink / raw)
To: buildroot
Add a patch fixing a build issue in doxygen. This patch is currently
under review for upstream inclusion[1].
[1] https://github.com/doxygen/doxygen/pull/574
Fixes: http://autobuild.buildroot.net/results/f55/f55a04e32c83620661d0542e89eb2dba9433e476/
Signed-off-by: Bartosz Golaszewski <brgl@bgdev.pl>
---
...build-fix-the-way-lang_cfg.h-is-generated.patch | 58 ++++++++++++++++++++++
1 file changed, 58 insertions(+)
create mode 100644 package/doxygen/0002-build-fix-the-way-lang_cfg.h-is-generated.patch
diff --git a/package/doxygen/0002-build-fix-the-way-lang_cfg.h-is-generated.patch b/package/doxygen/0002-build-fix-the-way-lang_cfg.h-is-generated.patch
new file mode 100644
index 0000000..282b2bd
--- /dev/null
+++ b/package/doxygen/0002-build-fix-the-way-lang_cfg.h-is-generated.patch
@@ -0,0 +1,58 @@
+From f9a3aa72c2bf15726bcdafd140fd21f790de555d Mon Sep 17 00:00:00 2001
+From: Bartosz Golaszewski <brgl@bgdev.pl>
+Date: Wed, 21 Jun 2017 14:32:25 +0200
+Subject: [PATCH] build: fix the way lang_cfg.h is generated
+
+This header is generated by running cmake/lang_cfg.cmake and
+redirecting its stderr. If any warning is emitted by this script, it
+ends up in the generated header and breaks the build.
+
+To avoid such problems: pass the path to the header as an argument to
+the cmake script and use the cmake 'file' command instead of 'message'.
+
+We can't even use message(STATUS...) as - although it prints to stdout
+as opposed to other types of messages - it prepends all output with
+a double hyphen.
+
+Signed-off-by: Bartosz Golaszewski <brgl@bgdev.pl>
+---
+ cmake/lang_cfg.cmake | 10 +++++-----
+ src/CMakeLists.txt | 2 +-
+ 2 files changed, 6 insertions(+), 6 deletions(-)
+
+diff --git a/cmake/lang_cfg.cmake b/cmake/lang_cfg.cmake
+index c57d3ed..86c2d9a 100644
+--- a/cmake/lang_cfg.cmake
++++ b/cmake/lang_cfg.cmake
+@@ -1,10 +1,10 @@
+-if(${CMAKE_ARGC} GREATER 1)
+- if ("${CMAKE_ARGV3}" STREQUAL "ENONLY")
+- message("#define ENGLISH_ONLY")
++if(${CMAKE_ARGC} GREATER 2)
++ if ("${CMAKE_ARGV4}" STREQUAL "ENONLY")
++ file(APPEND ${CMAKE_ARGV3} " #define ENGLISH_ONLY")
+ else()
+ math(EXPR UPTO ${CMAKE_ARGC}-1)
+- foreach(i RANGE 3 ${UPTO})
+- message("#define LANG_${CMAKE_ARGV${i}}")
++ foreach(i RANGE 4 ${UPTO})
++ file(APPEND ${CMAKE_ARGV3} " #define LANG_${CMAKE_ARGV${i}}")
+ endforeach()
+ endif()
+ endif()
+diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
+index 08c8439..dcf4ef8 100644
+--- a/src/CMakeLists.txt
++++ b/src/CMakeLists.txt
+@@ -73,7 +73,7 @@ set_source_files_properties(${GENERATED_SRC}/ce_parse.h PROPERTIES GENERATED 1)
+ # lang_cfg.h
+ add_custom_command(
+ COMMENT "Generating ${GENERATED_SRC}/lang_cfg.h"
+- COMMAND ${CMAKE_COMMAND} -P ${CMAKE_SOURCE_DIR}/cmake/lang_cfg.cmake ${LANG_CODES} 2> ${GENERATED_SRC}/lang_cfg.h
++ COMMAND ${CMAKE_COMMAND} -P ${CMAKE_SOURCE_DIR}/cmake/lang_cfg.cmake ${GENERATED_SRC}/lang_cfg.h ${LANG_CODES}
+ DEPENDS ${LANGUAGE_FILES}
+ OUTPUT ${GENERATED_SRC}/lang_cfg.h
+ )
+--
+2.9.3
+
--
2.9.3
^ permalink raw reply related [flat|nested] 3+ messages in thread
* [Buildroot] [PATCH] doxygen: fix a build issue
2017-06-26 9:20 ` Bartosz Golaszewski
@ 2017-07-02 16:38 ` Peter Korsgaard
0 siblings, 0 replies; 3+ messages in thread
From: Peter Korsgaard @ 2017-07-02 16:38 UTC (permalink / raw)
To: buildroot
>>>>> "Bartosz" == Bartosz Golaszewski <brgl@bgdev.pl> writes:
> Add a patch fixing a build issue in doxygen. This patch is currently
> under review for upstream inclusion[1].
> [1] https://github.com/doxygen/doxygen/pull/574
> Fixes: http://autobuild.buildroot.net/results/f55/f55a04e32c83620661d0542e89eb2dba9433e476/
> Signed-off-by: Bartosz Golaszewski <brgl@bgdev.pl>
Committed, thanks.
--
Bye, Peter Korsgaard
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2017-07-02 16:38 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-06-26 9:20 [Buildroot] [PATCH] doxygen: fix a build issue Bartosz Golaszewski
2017-06-26 9:20 ` Bartosz Golaszewski
2017-07-02 16:38 ` Peter Korsgaard
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox