]> git.ipfire.org Git - ipfire-2.x.git/blobdiff - lfs/binutils
cmake: update to 3.8.1
[ipfire-2.x.git] / lfs / binutils
index be890a88a5091fa5c9c4c758302e2f490d4ade66..8bf6decd94ffff73f4865af6619905757a65fefe 100644 (file)
@@ -38,20 +38,23 @@ ifeq "$(ROOT)" ""
   EXTRA_CONFIG = \
        --prefix=/usr \
        --enable-shared \
-       --disable-nls \
-       --disable-werror
+       --with-system-zlib \
+       --enable-plugins \
+       --enable-ld=default \
+       --disable-gold
   EXTRA_MAKE = tooldir=/usr
   EXTRA_INSTALL = tooldir=/usr
 else
 ifeq "$(PASS)" "1"
+  CFLAGS := $(patsubst -march=%,,$(CFLAGS))
+  CFLAGS := $(patsubst -mfloat-abi=%,,$(CFLAGS))
+
   TARGET = $(DIR_INFO)/$(THISAPP)-tools1
   EXTRA_CONFIG = \
        --target=$(CROSSTARGET) \
        --prefix=/tools \
        --with-sysroot=$(ROOT) \
-       --with-lib-path=/tools/lib \
-       --disable-nls \
-       --disable-werror
+       --with-lib-path=/tools/lib
   EXTRA_MAKE =
   EXTRA_INSTALL = 
 else
@@ -64,9 +67,7 @@ else
        --host=$(BUILDTARGET) \
        --build=$(BUILDTARGET) \
        --prefix=/tools \
-       --with-lib-path=/tools/lib \
-       --disable-nls \
-       --disable-werror
+       --with-lib-path=/tools/lib
   EXTRA_MAKE = 
   EXTRA_INSTALL = 
 endif
@@ -79,6 +80,7 @@ ifeq "$(BUILD_ARCH)" "armv5tel"
 endif
 
 EXTRA_CONFIG += \
+       --disable-werror \
        --enable-64-bit-bfd
 
 ###############################################################################
@@ -129,12 +131,15 @@ $(TARGET) : $(patsubst %,$(DIR_DL)/%,$(objects))
        cd $(DIR_SRC)/binutils-build && make $(EXTRA_INSTALL) install
 ifeq "$(ROOT)" ""
        cp -v $(DIR_APP)/include/libiberty.h /usr/include
-else
-ifeq "$(PASS)" "2"
+endif
+
+ifeq "$(TOOLCHAIN)" "1"
+ ifeq "$(PASS)" "2"
        cd $(DIR_SRC)/binutils-build && make -C ld clean
        cd $(DIR_SRC)/binutils-build && make -C ld LIB_PATH=/usr/lib:/lib
        cd $(DIR_SRC)/binutils-build && cp -v ld/ld-new /tools/bin
+ endif
 endif
-endif
+
        @rm -rf $(DIR_APP) $(DIR_SRC)/binutils-build
        @$(POSTBUILD)