X-Git-Url: http://git.osdn.net/view?a=blobdiff_plain;f=scripts%2Flink-vmlinux.sh;h=1a10d8ac81620faad519d4f95ca8552ac4a958c1;hb=2c069a118fe1d80c47dca84e1561045fc7f3cc9e;hp=86a4fe75f453735936e3b218f885dcd887216659;hpb=28176ab6d0c3def4d5c1f3c37e560b0093c58547;p=uclinux-h8%2Flinux.git diff --git a/scripts/link-vmlinux.sh b/scripts/link-vmlinux.sh index 86a4fe75f453..1a10d8ac8162 100755 --- a/scripts/link-vmlinux.sh +++ b/scripts/link-vmlinux.sh @@ -82,7 +82,7 @@ kallsyms() kallsymopt="${kallsymopt} --all-symbols" fi - if [ -n "${CONFIG_ARM}" ] && [ -n "${CONFIG_PAGE_OFFSET}" ]; then + if [ -n "${CONFIG_ARM}" ] && [ -z "${CONFIG_XIP_KERNEL}" ] && [ -n "${CONFIG_PAGE_OFFSET}" ]; then kallsymopt="${kallsymopt} --page-offset=$CONFIG_PAGE_OFFSET" fi @@ -111,7 +111,6 @@ sortextable() } # Delete output files in case of error -trap cleanup SIGHUP SIGINT SIGQUIT SIGTERM ERR cleanup() { rm -f .old_version @@ -124,6 +123,20 @@ cleanup() rm -f vmlinux.o } +on_exit() +{ + if [ $? -ne 0 ]; then + cleanup + fi +} +trap on_exit EXIT + +on_signals() +{ + exit 1 +} +trap on_signals HUP INT QUIT TERM + # # # Use "make V=1" to debug this script @@ -231,7 +244,6 @@ if [ -n "${CONFIG_KALLSYMS}" ]; then if ! cmp -s System.map .tmp_System.map; then echo >&2 Inconsistent kallsyms data echo >&2 Try "make KALLSYMS_EXTRA_PASS=1" as a workaround - cleanup exit 1 fi fi