summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--meta/recipes-devtools/flex/flex/0001-build-tests-add-missing-parser-scanner-dependencies.patch51
-rw-r--r--meta/recipes-devtools/flex/flex_2.6.4.bb4
2 files changed, 53 insertions, 2 deletions
diff --git a/meta/recipes-devtools/flex/flex/0001-build-tests-add-missing-parser-scanner-dependencies.patch b/meta/recipes-devtools/flex/flex/0001-build-tests-add-missing-parser-scanner-dependencies.patch
new file mode 100644
index 0000000000..130eccc9b4
--- /dev/null
+++ b/meta/recipes-devtools/flex/flex/0001-build-tests-add-missing-parser-scanner-dependencies.patch
@@ -0,0 +1,51 @@
1From 47e3916842ffefd7def84ae85758fdcceeb77839 Mon Sep 17 00:00:00 2001
2From: Ross Burton <ross.burton@arm.com>
3Date: Thu, 20 Mar 2025 12:16:50 +0000
4Subject: [PATCH] build(tests): add missing parser->scanner dependencies
5
6With sufficient parallelism and `make --shuffle` to reorder builds the
7test suite occasionally fails to build with errors like this:
8
9 tests/bison_yylval_parser.y:36:10: fatal error: bison_yylval_scanner.h: No such file or directory
10 36 | #include "bison_yylval_scanner.h"
11
12Solve this by adding the missing dependencies to the *_parser.o targets
13on the _scanner.h files.
14
15Upstream-Status: Submitted [https://github.com/westes/flex/pull/702]
16Signed-off-by: Ross Burton <ross.burton@arm.com>
17---
18 tests/Makefile.am | 3 +++
19 1 file changed, 3 insertions(+)
20
21diff --git a/tests/Makefile.am b/tests/Makefile.am
22index 2cb51df..d0c199d 100644
23--- a/tests/Makefile.am
24+++ b/tests/Makefile.am
25@@ -343,6 +343,7 @@ FLEX = $(top_builddir)/src/flex
26
27 bison_nr_main.$(OBJEXT): bison_nr_parser.h bison_nr_scanner.h
28 bison_nr_scanner.$(OBJEXT): bison_nr_parser.h
29+bison_nr_parser.$(OBJEXT): bison_nr_scanner.h
30
31 bison_nr_scanner.h: bison_nr_scanner.c
32 @if test ! -f $@; then rm -f $<; else :; fi
33@@ -350,6 +351,7 @@ bison_nr_scanner.h: bison_nr_scanner.c
34
35 bison_yylloc_main.$(OBJEXT): bison_yylloc_parser.h bison_yylloc_scanner.h
36 bison_yylloc_scanner.$(OBJEXT): bison_yylloc_parser.h
37+bison_yylloc_parser.$(OBJEXT): bison_yylloc_scanner.h
38
39 bison_yylloc_scanner.h: bison_yylloc_scanner.c
40 @if test ! -f $@; then rm -f $<; else :; fi
41@@ -357,6 +359,7 @@ bison_yylloc_scanner.h: bison_yylloc_scanner.c
42
43 bison_yylval_main.$(OBJEXT): bison_yylval_parser.h bison_yylval_scanner.h
44 bison_yylval_scanner.$(OBJEXT): bison_yylval_parser.h
45+bison_yylval_parser.$(OBJEXT): bison_yylval_scanner.h
46
47 bison_yylval_scanner.h: bison_yylval_scanner.c
48 @if test ! -f $@; then rm -f $<; else :; fi
49--
502.43.0
51
diff --git a/meta/recipes-devtools/flex/flex_2.6.4.bb b/meta/recipes-devtools/flex/flex_2.6.4.bb
index 434ce47c03..793a935962 100644
--- a/meta/recipes-devtools/flex/flex_2.6.4.bb
+++ b/meta/recipes-devtools/flex/flex_2.6.4.bb
@@ -18,6 +18,7 @@ SRC_URI = "${GITHUB_BASE_URI}/download/v${PV}/flex-${PV}.tar.gz \
18 file://0001-build-AC_USE_SYSTEM_EXTENSIONS-in-configure.ac.patch \ 18 file://0001-build-AC_USE_SYSTEM_EXTENSIONS-in-configure.ac.patch \
19 file://check-funcs.patch \ 19 file://check-funcs.patch \
20 file://0001-Emit-no-line-directives-if-gen_line_dirs-is-false.patch \ 20 file://0001-Emit-no-line-directives-if-gen_line_dirs-is-false.patch \
21 file://0001-build-tests-add-missing-parser-scanner-dependencies.patch \
21 " 22 "
22 23
23SRC_URI[md5sum] = "2882e3179748cc9f9c23ec593d6adc8d" 24SRC_URI[md5sum] = "2882e3179748cc9f9c23ec593d6adc8d"
@@ -55,9 +56,8 @@ RDEPENDS:${PN} += "m4"
55RDEPENDS:${PN}-ptest += "bash gawk make" 56RDEPENDS:${PN}-ptest += "bash gawk make"
56 57
57do_compile_ptest() { 58do_compile_ptest() {
58 oe_runmake -C ${B}/tests -f ${B}/tests/Makefile top_builddir=${B} INCLUDES=-I${S}/src buildtests 59 oe_runmake -C ${B}/tests buildtests
59} 60}
60PTEST_PARALLEL_MAKE = ""
61 61
62do_install_ptest() { 62do_install_ptest() {
63 mkdir -p ${D}${PTEST_PATH}/build-aux/ 63 mkdir -p ${D}${PTEST_PATH}/build-aux/