diff options
author | Richard Purdie <richard.purdie@linuxfoundation.org> | 2022-07-20 12:29:39 +0100 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2022-08-17 19:57:32 +0100 |
commit | 794371ad2da471321bfde494523ee73a10380e0a (patch) | |
tree | b6b5d09acad809e9d51b01940a8e69707ed3d5e9 /meta/recipes-devtools/gcc/libgcc-common.inc | |
parent | 1d6c7af0e35811e66a0b3cd3dcc7e3d15b54f99a (diff) | |
download | poky-794371ad2da471321bfde494523ee73a10380e0a.tar.gz |
libgcc/gcc-runtime: Improve source reference handling
This code was some of the earliest reproducible build work we did. To
correctly handle the encoding of file paths, we used relative build
paths to run configure which resulted in relative build paths in the
binaries.
We now have more modern approaches used elsewhere with the prefix remapping
options. These work best with absolute paths, not relative ones. As such,
drop the relative path mangling and switch to using prefix mapping
exclusively on absolute paths.
This makes the code matc the rest of the system and triggers the correct
code to be added in /usr/src/debug.
We have to include both file-prefix and debug-prefix since the assembler
only looks at debug-prefix.
(From OE-Core rev: 309e5d8bb56eb8599d756831f0bd38e6a50cfb05)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-devtools/gcc/libgcc-common.inc')
-rw-r--r-- | meta/recipes-devtools/gcc/libgcc-common.inc | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/meta/recipes-devtools/gcc/libgcc-common.inc b/meta/recipes-devtools/gcc/libgcc-common.inc index cf8d6b7ed6..e813926313 100644 --- a/meta/recipes-devtools/gcc/libgcc-common.inc +++ b/meta/recipes-devtools/gcc/libgcc-common.inc | |||
@@ -4,14 +4,21 @@ require gcc-configure-common.inc | |||
4 | 4 | ||
5 | INHIBIT_DEFAULT_DEPS = "1" | 5 | INHIBIT_DEFAULT_DEPS = "1" |
6 | 6 | ||
7 | DEBUGSOURCE = "/usr/src/debug/${PN}/${EXTENDPE}${PV}-${PR}" | ||
8 | DEBUG_PREFIX_MAP = " \ | ||
9 | -fdebug-prefix-map=${WORKDIR}/${MLPREFIX}recipe-sysroot= \ | ||
10 | -fdebug-prefix-map=${WORKDIR}/recipe-sysroot-native= \ | ||
11 | -fdebug-prefix-map=${B}=${DEBUGSOURCE} \ | ||
12 | -fdebug-prefix-map=${S}=${DEBUGSOURCE} \ | ||
13 | " | ||
14 | |||
7 | do_configure () { | 15 | do_configure () { |
8 | install -d ${D}${base_libdir} ${D}${libdir} | 16 | install -d ${D}${base_libdir} ${D}${libdir} |
9 | mkdir -p ${B}/${BPN} | 17 | mkdir -p ${B}/${BPN} |
10 | mkdir -p ${B}/${TARGET_SYS}/${BPN}/ | 18 | mkdir -p ${B}/${TARGET_SYS}/${BPN}/ |
11 | cd ${B}/${BPN} | 19 | cd ${B}/${BPN} |
12 | chmod a+x ${S}/${BPN}/configure | 20 | chmod a+x ${S}/${BPN}/configure |
13 | relpath=${@os.path.relpath("${S}/${BPN}", "${B}/${BPN}")} | 21 | ${S}/${BPN}/configure ${CONFIGUREOPTS} ${EXTRA_OECONF} |
14 | $relpath/configure ${CONFIGUREOPTS} ${EXTRA_OECONF} | ||
15 | } | 22 | } |
16 | EXTRACONFFUNCS += "extract_stashed_builddir" | 23 | EXTRACONFFUNCS += "extract_stashed_builddir" |
17 | do_configure[depends] += "${COMPILERDEP}" | 24 | do_configure[depends] += "${COMPILERDEP}" |