mirror of
https://github.com/xen-project/xen.git
synced 2026-10-28 02:01:24 +01:00
The hide pattern .xen-syms.[013] leaves pass 2 visible. On x86
LAST_LINKING_PASS is 2, so that is the final link. On Arm
LAST_LINKING_PASS is 3 and the final image is .xen-syms.3. Pass 2 is
usually only a symlink, so Eclair saw no program link and reported every
translation unit as unreachable.
During analysis preparation, read LAST_LINKING_PASS from the architecture
makefile and the pass numbers from the foreach list in
xen/scripts/Makefile.link. Hide every pass except that one. An earlier
pass that is a real link stays hidden. The generator runs from
generate_ecl.sh, together with the other ECLAIR configuration scripts.
Fixes: a401b5c9dc ("Eclair: re-enable scanning of the (almost) final linking step")
Signed-off-by: Dmytro Prokopchuk <dmytro_prokopchuk1@epam.com>
Acked-by: Nicola Vetrini <nicola.vetrini@bugseng.com>
Acked-by: Jan Beulich <jbeulich@suse.com>
26 lines
630 B
Bash
Executable File
26 lines
630 B
Bash
Executable File
#!/bin/bash
|
|
|
|
# Generates the .ecl files
|
|
|
|
set -eu
|
|
|
|
script_dir="$(
|
|
cd "$(dirname "$0")"
|
|
echo "${PWD}"
|
|
)"
|
|
|
|
exclude_list="${ECLAIR_PROJECT_ROOT}/docs/misra/exclude-list.json"
|
|
accepted_rst="${ECLAIR_PROJECT_ROOT}/docs/misra/rules.rst"
|
|
|
|
# Generate the exclude list file
|
|
"${script_dir}/adopted.sh" "${exclude_list}"
|
|
|
|
# Generate accepted guidelines
|
|
"${script_dir}/accepted_guidelines.sh" "${accepted_rst}"
|
|
|
|
# Generate the list of linker-defined symbols (must be run after a Xen build)
|
|
"${script_dir}/generate-linker-symbols.sh"
|
|
|
|
# Hide every xen-syms linking pass except LAST_LINKING_PASS.
|
|
"${script_dir}/generate-xen-syms-passes.sh"
|