summaryrefslogtreecommitdiffstats
path: root/arch/sh/Makefile
diff options
context:
space:
mode:
authorDavid S. Miller <davem@davemloft.net>2008-04-03 14:33:42 -0700
committerDavid S. Miller <davem@davemloft.net>2008-04-03 14:33:42 -0700
commit3bb5da3837cc1aa17736b05139c9a22c3794851a (patch)
treec92d5684a866542b1cb20641607ac1643ce03a47 /arch/sh/Makefile
parent7feb49c82a74bc7c091b8ab2a3f96baa33d08ece (diff)
parent9597362d354f8655ece324b01d0c640a0e99c077 (diff)
downloadop-kernel-dev-3bb5da3837cc1aa17736b05139c9a22c3794851a.zip
op-kernel-dev-3bb5da3837cc1aa17736b05139c9a22c3794851a.tar.gz
Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6
Diffstat (limited to 'arch/sh/Makefile')
-rw-r--r--arch/sh/Makefile8
1 files changed, 6 insertions, 2 deletions
diff --git a/arch/sh/Makefile b/arch/sh/Makefile
index c510c22..cffc92b 100644
--- a/arch/sh/Makefile
+++ b/arch/sh/Makefile
@@ -154,7 +154,11 @@ drivers-$(CONFIG_OPROFILE) += arch/sh/oprofile/
boot := arch/sh/boot
+ifneq ($(KBUILD_SRC),)
incdir-prefix := $(srctree)/include/asm-sh/
+else
+incdir-prefix :=
+endif
# Update machine arch and proc symlinks if something which affects
# them changed. We use .arch and .mach to indicate when they were
@@ -182,7 +186,7 @@ include/asm-sh/.mach: $(wildcard include/config/sh/*.h) \
$(Q)if [ ! -d include/asm-sh ]; then mkdir -p include/asm-sh; fi
$(Q)rm -f include/asm-sh/mach
$(Q)for i in $(incdir-y); do \
- if [ -d $(incdir-prefix)$$i ]; then \
+ if [ -d $(srctree)/include/asm-sh/$$i ]; then \
echo -n ' SYMLINK include/asm-sh/mach -> '; \
echo -e "include/asm-sh/$$i"; \
ln -fsn $(incdir-prefix)$$i \
@@ -191,7 +195,7 @@ include/asm-sh/.mach: $(wildcard include/config/sh/*.h) \
if [ ! -d include/asm-sh/mach ]; then \
echo -n ' SYMLINK include/asm-sh/mach -> '; \
echo -e 'include/asm-sh'; \
- ln -fsn $(incdir-prefix) include/asm-sh/mach; \
+ ln -fsn $(incdir-prefix)../asm-sh include/asm-sh/mach; \
fi; \
fi; \
done
OpenPOWER on IntegriCloud