diff options
| -rw-r--r-- | meta-oe/recipes-devtools/jq/jq/0001-Support-building-with-disable-maintainer-mode-and-so.patch | 44 | ||||
| -rw-r--r-- | meta-oe/recipes-devtools/jq/jq_1.8.1.bb | 14 |
2 files changed, 52 insertions, 6 deletions
diff --git a/meta-oe/recipes-devtools/jq/jq/0001-Support-building-with-disable-maintainer-mode-and-so.patch b/meta-oe/recipes-devtools/jq/jq/0001-Support-building-with-disable-maintainer-mode-and-so.patch new file mode 100644 index 0000000000..12a64a75ed --- /dev/null +++ b/meta-oe/recipes-devtools/jq/jq/0001-Support-building-with-disable-maintainer-mode-and-so.patch | |||
| @@ -0,0 +1,44 @@ | |||
| 1 | From 27f417f4812e688a59fc5186b7768cec004cd6e5 Mon Sep 17 00:00:00 2001 | ||
| 2 | From: Peter Kjellerstedt <peter.kjellerstedt@gmail.com> | ||
| 3 | Date: Wed, 8 Apr 2026 05:58:49 +0200 | ||
| 4 | Subject: [PATCH] Support building with --disable-maintainer-mode and source != | ||
| 5 | build dir (#3518) | ||
| 6 | |||
| 7 | If --disable-maintainer-mode is enabled, then the rules for generating | ||
| 8 | parser.[ch] and lexer.[ch] did nothing. This worked fine if the source | ||
| 9 | and build directories are the same as the pre-generated parser.c and | ||
| 10 | lexer.c files would suffice. However, if the build directory is not the | ||
| 11 | same as the source directory, then the rest of the Make rules expect | ||
| 12 | parser.[ch] and lexer.[ch] to have been created in the build directory | ||
| 13 | if their source files (parser.y and lexer.l) are newer than the target | ||
| 14 | files, which can happen in case the source is fetched using Git. | ||
| 15 | |||
| 16 | Avoid the problem by copying the files to the build directory if needed. | ||
| 17 | |||
| 18 | Co-authored-by: Peter Kjellerstedt <pkj@axis.com> | ||
| 19 | Upstream-Status: Backport [https://github.com/jqlang/jq/commit/27f417f4812e688a59fc5186b7768cec004cd6e5] | ||
| 20 | --- | ||
| 21 | Makefile.am | 9 +++++++-- | ||
| 22 | 1 file changed, 7 insertions(+), 2 deletions(-) | ||
| 23 | |||
| 24 | diff --git a/Makefile.am b/Makefile.am | ||
| 25 | index 96d6038..acb9443 100644 | ||
| 26 | --- a/Makefile.am | ||
| 27 | +++ b/Makefile.am | ||
| 28 | @@ -41,9 +41,14 @@ src/lexer.h: src/lexer.c | ||
| 29 | else | ||
| 30 | BUILT_SOURCES = src/builtin.inc src/config_opts.inc src/version.h | ||
| 31 | .y.c: | ||
| 32 | - $(AM_V_YACC) echo "NOT building parser.c!" | ||
| 33 | + $(AM_V_YACC) [ "$(<D)" = "$(@D)" ] || cp $(<D)/$(@F) $@ | ||
| 34 | + $(AM_V_YACC) [ "$(<D)" = "$(@D)" ] || cp $(<D)/$(*F).h $*.h | ||
| 35 | + $(AM_V_YACC) touch $@ $*.h | ||
| 36 | + | ||
| 37 | .l.c: | ||
| 38 | - $(AM_V_LEX) echo "NOT building lexer.c!" | ||
| 39 | + $(AM_V_LEX) [ "$(<D)" = "$(@D)" ] || cp $(<D)/$(@F) $@ | ||
| 40 | + $(AM_V_LEX) [ "$(<D)" = "$(@D)" ] || cp $(<D)/$(*F).h $*.h | ||
| 41 | + $(AM_V_LEX) touch $@ $*.h | ||
| 42 | endif | ||
| 43 | |||
| 44 | # Tell YACC (Bison) autoconf macros that you want a header file created. | ||
diff --git a/meta-oe/recipes-devtools/jq/jq_1.8.1.bb b/meta-oe/recipes-devtools/jq/jq_1.8.1.bb index b9383c76f7..6eaa2de6df 100644 --- a/meta-oe/recipes-devtools/jq/jq_1.8.1.bb +++ b/meta-oe/recipes-devtools/jq/jq_1.8.1.bb | |||
| @@ -8,15 +8,17 @@ SECTION = "utils" | |||
| 8 | LICENSE = "MIT & BSD-2-Clause" | 8 | LICENSE = "MIT & BSD-2-Clause" |
| 9 | LIC_FILES_CHKSUM = "file://COPYING;md5=cf7fcb0a1def4a7ad62c028f7d0dca47" | 9 | LIC_FILES_CHKSUM = "file://COPYING;md5=cf7fcb0a1def4a7ad62c028f7d0dca47" |
| 10 | 10 | ||
| 11 | GITHUB_BASE_URI = "https://github.com/jqlang/${BPN}/releases/" | 11 | SRCREV = "4467af7068b1bcd7f882defff6e7ea674c5357f4" |
| 12 | SRC_URI = "${GITHUB_BASE_URI}/download/${BPN}-${PV}/${BPN}-${PV}.tar.gz \ | 12 | |
| 13 | SRC_URI = " \ | ||
| 14 | git://github.com/jqlang/jq.git;protocol=https;branch=master;tag=jq-${PV} \ | ||
| 13 | file://run-ptest \ | 15 | file://run-ptest \ |
| 14 | " | 16 | file://0001-Support-building-with-disable-maintainer-mode-and-so.patch \ |
| 15 | SRC_URI[sha256sum] = "2be64e7129cecb11d5906290eba10af694fb9e3e7f9fc208a311dc33ca837eb0" | 17 | " |
| 16 | 18 | ||
| 17 | inherit autotools github-releases ptest | 19 | inherit autotools ptest |
| 18 | 20 | ||
| 19 | UPSTREAM_CHECK_REGEX = "releases/tag/${BPN}-(?P<pver>\d+(\.\d+)+)" | 21 | UPSTREAM_CHECK_GITTAGREGEX = "${BPN}-(?P<pver>\d+(\.\d+)+)" |
| 20 | 22 | ||
| 21 | PACKAGECONFIG ?= "oniguruma" | 23 | PACKAGECONFIG ?= "oniguruma" |
| 22 | 24 | ||
