summaryrefslogtreecommitdiff
path: root/toolchain
diff options
context:
space:
mode:
authorWaldemar Brodkorb <wbx@openadk.org>2011-01-07 16:59:51 +0100
committerWaldemar Brodkorb <wbx@openadk.org>2011-01-07 16:59:51 +0100
commitd3b021b5410aeb3f62a7225dccb3f6f2617d4c38 (patch)
treee4313904bd4622b4b9c6ec8dc2fa24a970c9bd60 /toolchain
parenta34589bab665fdf945eaa22d756b45418763deea (diff)
add toolchain settings menu point
- gdb compilation can be disabled - gcc languages (c++/java) can be enabled/disabled - gcc stack smashing protection can be enabled/disabled
Diffstat (limited to 'toolchain')
-rw-r--r--toolchain/Makefile2
-rw-r--r--toolchain/binutils/Makefile9
-rw-r--r--toolchain/gcc/Makefile17
-rw-r--r--toolchain/uClibc/Makefile3
4 files changed, 27 insertions, 4 deletions
diff --git a/toolchain/Makefile b/toolchain/Makefile
index 1e36c6b5f..b9a13f04a 100644
--- a/toolchain/Makefile
+++ b/toolchain/Makefile
@@ -26,7 +26,9 @@ ifeq ($(ADK_TARGET_LIB_UCLIBC),y)
TARGETS+=uClibc
LIBC:=uClibc
endif
+ifeq ($(ADK_TOOLCHAIN_GDB),y)
TARGETS+=gdb
+endif
DOWNLOAD:=kernel-headers-download $(patsubst %,%-download,$(TARGETS))
TARGETS_INSTALL:=$(patsubst %,%-install,$(TARGETS))
diff --git a/toolchain/binutils/Makefile b/toolchain/binutils/Makefile
index 33f03c7fb..2b0137db9 100644
--- a/toolchain/binutils/Makefile
+++ b/toolchain/binutils/Makefile
@@ -6,6 +6,12 @@ include Makefile.inc
include ../rules.mk
include ${TOPDIR}/mk/buildhlp.mk
+ifeq ($(ADK_TOOLCHAIN_GCC_SSP),y)
+CONFOPTS+= --enable-libssp
+else
+CONFOPTS+= --disable-libssp
+endif
+
ifeq ($(ADK_LINUX_64),y)
CONFOPTS+= --enable-64-bit-bfd
endif
@@ -22,14 +28,13 @@ $(WRKBUILD)/.configured:
--build=$(GNU_HOST_NAME) \
--host=$(GNU_HOST_NAME) \
--target=$(REAL_GNU_TARGET_NAME) \
- --disable-nls \
--with-sysroot=$(TOOLCHAIN_SYSROOT) \
--with-sysroot=$(STAGING_TARGET_DIR) \
--disable-multilib \
--disable-dependency-tracking \
--disable-libtool-lock \
+ --disable-nls \
--disable-werror \
- --disable-libssp \
${CONFOPTS} \
);
touch $@
diff --git a/toolchain/gcc/Makefile b/toolchain/gcc/Makefile
index 7e806c68c..3c160d4f4 100644
--- a/toolchain/gcc/Makefile
+++ b/toolchain/gcc/Makefile
@@ -19,7 +19,6 @@ GCC_CONFOPTS= --prefix=$(STAGING_HOST_DIR) \
--disable-decimal-float \
--disable-multilib \
--disable-sjlj-exceptions \
- --disable-libssp \
--disable-libstdcxx-pch \
--disable-ppl-version-check \
--disable-cloog-version-check \
@@ -27,6 +26,12 @@ GCC_CONFOPTS= --prefix=$(STAGING_HOST_DIR) \
--without-cloog \
--disable-nls
+ifeq ($(ADK_TOOLCHAIN_GCC_SSP),y)
+GCC_CONFOPTS+= --enable-libssp
+else
+GCC_CONFOPTS+= --disable-libssp
+endif
+
ifeq ($(ARCH),cris)
GCC_CONFOPTS+= --disable-tls
else
@@ -55,6 +60,14 @@ ifeq (${ADK_MAKE_PARALLEL},y)
GCC_MAKEOPTS+= -j${ADK_MAKE_JOBS}
endif
+LANGUAGES:=c
+ifeq ($(ADK_TOOLCHAIN_GCC_CXX),y)
+LANGUAGES:=${LANGUAGES},c++
+endif
+ifeq ($(ADK_TOOLCHAIN_GCC_JAVA),y)
+LANGUAGES:=${LANGUAGES},java
+endif
+
include ${TOPDIR}/mk/buildhlp.mk
GCC_BUILD_DIR_MINIMAL:= $(WRKBUILD)-minimal
@@ -119,7 +132,7 @@ $(GCC_BUILD_DIR_FINAL)/.configured:
PATH='$(TARGET_PATH)' \
$(WRKBUILD)/configure \
${GCC_CONFOPTS} \
- --enable-languages=c,c++ \
+ --enable-languages=$(LANGUAGES) \
--with-sysroot=$(STAGING_TARGET_DIR) \
--with-slibdir=$(STAGING_TARGET_DIR)/lib \
--enable-shared \
diff --git a/toolchain/uClibc/Makefile b/toolchain/uClibc/Makefile
index 194bce39a..e04985dac 100644
--- a/toolchain/uClibc/Makefile
+++ b/toolchain/uClibc/Makefile
@@ -19,6 +19,9 @@ $(WRKBUILD)/.headers:
ifneq ($(ADK_DEBUG),)
$(SED) 's,DOSTRIP,DODEBUG,' ${WRKBUILD}/.config
endif
+ifneq ($(ADK_TOOLCHAIN_GCC_SSP),)
+ $(SED) 's,.*UCLIBC_HAS_SSP,UCLIBC_HAS_SSP=y,' ${WRKBUILD}/.config
+endif
$(MAKE) ${UCLIBC_MAKEOPTS} -C $(WRKBUILD) \
PREFIX=$(TOOLCHAIN_SYSROOT) \
DEVEL_PREFIX=/usr/ \