summaryrefslogtreecommitdiff
path: root/toolchain/uclibc
diff options
context:
space:
mode:
authorWaldemar Brodkorb <wbx@openadk.org>2014-09-06 14:17:02 +0200
committerWaldemar Brodkorb <wbx@openadk.org>2014-09-06 14:17:02 +0200
commitabb21a3a50a3c12aaa759db96a7aaf5d3bc52951 (patch)
tree0f8731b2cde05232cb1cf2b1f8d91570986365c7 /toolchain/uclibc
parent6b2356a8a56112dae8fa21b5674491ec277b7c43 (diff)
rework uClibc config file generation
Diffstat (limited to 'toolchain/uclibc')
-rw-r--r--toolchain/uclibc/Makefile54
1 files changed, 36 insertions, 18 deletions
diff --git a/toolchain/uclibc/Makefile b/toolchain/uclibc/Makefile
index b1e43e568..2935a6503 100644
--- a/toolchain/uclibc/Makefile
+++ b/toolchain/uclibc/Makefile
@@ -35,6 +35,31 @@ else
$(SED) 's/.*\(ARCH_LITTLE_ENDIAN\).*/# \1 is not set/' ${WRKBUILD}/.config
$(SED) 's/.*\(ARCH_WANTS_LITTLE_ENDIAN\).*/# \1 is not set/' ${WRKBUILD}/.config
endif
+ifeq ($(ADK_TARGET_USE_STATIC_LIBS)$(ADK_TARGET_BINFMT_FLAT),)
+ $(SED) 's/.*\(HAVE_SHARED\).*/#\1=y/' ${WRKBUILD}/.config
+else
+ $(SED) 's/.*\(HAVE_SHARED\).*/# \1 is not set/' ${WRKBUILD}/.config
+endif
+ifeq ($(ADK_TARGET_USE_GNU_HASHSTYLE),y)
+ $(SED) 's/.*\(LDSO_GNU_HASH_SUPPORT\).*/#\1=y/' ${WRKBUILD}/.config
+else
+ $(SED) 's/.*\(LDSO_GNU_HASH_SUPPORT\).*/# \1 is not set/' ${WRKBUILD}/.config
+endif
+ifneq ($(ADK_PACKAGE_GDB),)
+ $(SED) "s/.*\(PTHREADS_DEBUG_SUPPORT\).*/\1=y/" ${WRKBUILD}/.config
+endif
+ifneq ($(ADK_PACKAGE_GDBSERVER),)
+ $(SED) "s/.*\(PTHREADS_DEBUG_SUPPORT\).*/\1=y/" ${WRKBUILD}/.config
+endif
+ifeq ($(ADK_TARGET_USE_SSP),y)
+ $(SED) 's,.*UCLIBC_HAS_SSP,UCLIBC_HAS_SSP=y,' ${WRKBUILD}/.config
+ echo "UCLIBC_HAS_SSP_COMPAT=n" >> ${WRKBUILD}/.config
+ echo "SSP_QUICK_CANARY=n" >> ${WRKBUILD}/.config
+ echo "UCLIBC_BUILD_SSP=y" >> ${WRKBUILD}/.config
+endif
+
+# architecture specific options
+# arm
ifeq ($(ADK_LINUX_ARM),y)
ifeq ($(ADK_TARGET_ABI_EABI),y)
$(SED) 's/.*\(UCLIBC_HAS_FPU\).*/# \1 is not set/' ${WRKBUILD}/.config
@@ -45,16 +70,11 @@ ifeq ($(ADK_TARGET_ABI_EABIHF),y)
$(SED) 's/.*\(UCLIBC_HAS_FPU\).*/\1=y/' ${WRKBUILD}/.config
$(SED) 's/.*\(UCLIBC_HAS_SOFT_FLOAT\).*/# \1 is not set/' ${WRKBUILD}/.config
endif
-endif
-ifeq ($(ADK_LINUX_PPC),y)
-ifeq ($(ADK_TARGET_CPU_WITH_FPU),y)
- $(SED) 's/.*\(UCLIBC_HAS_FPU\).*/\1=y/' ${WRKBUILD}/.config
- $(SED) 's/.*\(UCLIBC_HAS_SOFT_FLOAT\).*/# \1 is not set/' ${WRKBUILD}/.config
-else
- $(SED) 's/.*\(UCLIBC_HAS_FPU\).*/# \1 is not set/' ${WRKBUILD}/.config
- $(SED) 's/.*\(UCLIBC_HAS_SOFT_FLOAT\).*/#\1=y/' ${WRKBUILD}/.config
+ifeq ($(ADK_LINUX_ARM_WITH_THUMB),y)
+ $(SED) 's/.*\(COMPILE_IN_THUMB_MODE\).*/\1=y/' ${WRKBUILD}/.config
endif
endif
+# mips/mips64
ifeq ($(ADK_LINUX_MIPS64),y)
$(SED) 's/.*\(CONFIG_MIPS_ISA_MIPS64\).*/\1=y/' ${WRKBUILD}/.config
$(SED) 's/.*\(CONFIG_MIPS_ISA_MIPS32\).*/# \1 is not set/' ${WRKBUILD}/.config
@@ -80,17 +100,15 @@ ifeq ($(ADK_o32),y)
$(SED) 's/.*\(CONFIG_MIPS_N64_ABI\).*/# \1 is not set/' ${WRKBUILD}/.config
endif
endif
-ifneq ($(ADK_PACKAGE_GDB),)
- $(SED) "s/.*\(PTHREADS_DEBUG_SUPPORT\).*/\1=y/" ${WRKBUILD}/.config
-endif
-ifeq ($(ADK_LINUX_ARM_WITH_THUMB),y)
- $(SED) 's/.*\(COMPILE_IN_THUMB_MODE\).*/\1=y/' ${WRKBUILD}/.config
+# powerpc
+ifeq ($(ADK_LINUX_PPC),y)
+ifeq ($(ADK_TARGET_CPU_WITH_FPU),y)
+ $(SED) 's/.*\(UCLIBC_HAS_FPU\).*/\1=y/' ${WRKBUILD}/.config
+ $(SED) 's/.*\(UCLIBC_HAS_SOFT_FLOAT\).*/# \1 is not set/' ${WRKBUILD}/.config
+else
+ $(SED) 's/.*\(UCLIBC_HAS_FPU\).*/# \1 is not set/' ${WRKBUILD}/.config
+ $(SED) 's/.*\(UCLIBC_HAS_SOFT_FLOAT\).*/#\1=y/' ${WRKBUILD}/.config
endif
-ifeq ($(ADK_TARGET_USE_SSP),y)
- $(SED) 's,.*UCLIBC_HAS_SSP,UCLIBC_HAS_SSP=y,' ${WRKBUILD}/.config
- echo "UCLIBC_HAS_SSP_COMPAT=n" >> ${WRKBUILD}/.config
- echo "SSP_QUICK_CANARY=n" >> ${WRKBUILD}/.config
- echo "UCLIBC_BUILD_SSP=y" >> ${WRKBUILD}/.config
endif
echo N|PATH='$(HOST_PATH)' $(MAKE) ${UCLIBC_MAKEOPTS} -C $(WRKBUILD) \
PREFIX=$(STAGING_TARGET_DIR) \