Skip to content

Commit bb090fd

Browse files
Julien Thierryjpoimboe
authored andcommitted
objtool: Make sync-check consider the target architecture
Do not take into account outdated headers unrelated to the build of the current architecture. [ jpoimboe: use $SRCARCH directly ] Reviewed-by: Miroslav Benes <mbenes@suse.cz> Signed-off-by: Julien Thierry <jthierry@redhat.com> Signed-off-by: Josh Poimboeuf <jpoimboe@redhat.com>
1 parent 3890b8d commit bb090fd

1 file changed

Lines changed: 7 additions & 0 deletions

File tree

tools/objtool/sync-check.sh

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,12 @@
11
#!/bin/sh
22
# SPDX-License-Identifier: GPL-2.0
33

4+
if [ -z "$SRCARCH" ]; then
5+
echo 'sync-check.sh: error: missing $SRCARCH environment variable' >&2
6+
exit 1
7+
fi
8+
9+
if [ "$SRCARCH" = "x86" ]; then
410
FILES="
511
arch/x86/include/asm/inat_types.h
612
arch/x86/include/asm/orc_types.h
@@ -13,6 +19,7 @@ arch/x86/include/asm/insn.h -I '^#include [\"<]\(asm/\)*inat.h[\">]'
1319
arch/x86/lib/inat.c -I '^#include [\"<]\(../include/\)*asm/insn.h[\">]'
1420
arch/x86/lib/insn.c -I '^#include [\"<]\(../include/\)*asm/in\(at\|sn\).h[\">]' -I '^#include [\"<]\(../include/\)*asm/emulate_prefix.h[\">]'
1521
"
22+
fi
1623

1724
check_2 () {
1825
file1=$1

0 commit comments

Comments
 (0)