Home Home > GIT Browse > linux-next
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichal Suchanek <msuchanek@suse.de>2018-12-03 18:59:40 +0100
committerMichal Suchanek <msuchanek@suse.de>2018-12-03 18:59:40 +0100
commit5262b8221af67134292eb6a2c56e03571fa1c516 (patch)
tree615540b8fd49e03728b18a497f7cd0f295ea71e5
parentcd790d4c1d9557895647b6ddd4f1ff7c2567b5c6 (diff)
parent98367ef04931be721ac54e3e7205a89db345ca4c (diff)
Merge branch 'scripts' into linux-next
-rwxr-xr-xscripts/run_oldconfig.sh31
1 files changed, 31 insertions, 0 deletions
diff --git a/scripts/run_oldconfig.sh b/scripts/run_oldconfig.sh
index 123ab38243..de637afa3a 100755
--- a/scripts/run_oldconfig.sh
+++ b/scripts/run_oldconfig.sh
@@ -407,6 +407,37 @@ for config in $config_files; do
MAKE_ARGS="ARCH=$cpu_arch"
;;
esac
+ unset cross_arch
+ unset cross_extra
+ case $config in
+ arm64/*)
+ cross_arch="aarch64"
+ ;;
+ arm*/*)
+ cross_arch="arm"
+ cross_extra="gnueabi-"
+ ;;
+ ppc64le/*)
+ cross_arch="powerpc64le"
+ ;;
+ ppc64/*)
+ cross_arch="powerpc64"
+ ;;
+ ppc/*)
+ cross_arch="powerpc"
+ ;;
+ i386/*)
+ # hack: whatever i386-suse-linux-gcc is, it does not support asm-goto
+ cross_arch="x86_64"
+ ;;
+ *)
+ cross_arch="${config%%/*}"
+ ;;
+ esac
+ cross_compile="${CROSS_COMPILE-${cross_arch}-suse-linux-${cross_extra}}"
+ if [ -n "$cross_compile" -a -x /usr/bin/${cross_compile}gcc ]; then
+ MAKE_ARGS="$MAKE_ARGS CROSS_COMPILE=$cross_compile"
+ fi
if [ -n "$CC" ]; then
MAKE_ARGS="$MAKE_ARGS CC=$CC"
fi