summaryrefslogtreecommitdiffstats
path: root/arch/sandbox/include
diff options
context:
space:
mode:
authorJean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>2011-10-27 19:50:42 +0800
committerSascha Hauer <s.hauer@pengutronix.de>2011-11-22 21:09:26 +0100
commita59471d133e0f80e7e1095b0cb161e31341694ad (patch)
treec4b993b8522dc2df5e3cfbe4d23baaf0e2e9851e /arch/sandbox/include
parent77e81882692a4612905aeb25a684d1ed9e4828de (diff)
downloadbarebox-a59471d133e0f80e7e1095b0cb161e31341694ad.tar.gz
barebox-a59471d133e0f80e7e1095b0cb161e31341694ad.tar.xz
sandbox: move ELFCLASS detection to asm/elf.h
now we can detect the host build from gcc macro and cross compile the sandbox Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com> Cc: Loïc Minier <loic.minier@linaro.org> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'arch/sandbox/include')
-rw-r--r--arch/sandbox/include/asm/elf.h11
1 files changed, 10 insertions, 1 deletions
diff --git a/arch/sandbox/include/asm/elf.h b/arch/sandbox/include/asm/elf.h
index b60d24890c..3939336ccb 100644
--- a/arch/sandbox/include/asm/elf.h
+++ b/arch/sandbox/include/asm/elf.h
@@ -1,2 +1,11 @@
+#ifndef __ASM_SANDBOX_ELF_H__
+#define __ASM_SANDBOX_ELF_H__
-/* nothing yet */
+#if __SIZEOF_POINTER__ == 8
+#define ELF_CLASS ELFCLASS64
+#define CONFIG_PHYS_ADDR_T_64BIT
+#else
+#define ELF_CLASS ELFCLASS32
+#endif
+
+#endif /* __ASM_SANDBOX_ELF_H__ */