From: Michael Tremer Date: Sat, 22 Aug 2015 10:25:49 +0000 (+0200) Subject: Allow building the toolchain for x86_64 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=81aa971410ce16adde033489dc947a3ea4d3fede;p=people%2Fms%2Fipfire-2.x.git Allow building the toolchain for x86_64 Signed-off-by: Michael Tremer --- diff --git a/lfs/binutils b/lfs/binutils index 08bc7c9b69..0fdc570531 100644 --- a/lfs/binutils +++ b/lfs/binutils @@ -36,6 +36,8 @@ DIR_APP = $(DIR_SRC)/$(THISAPP) ifeq "$(ROOT)" "" TARGET = $(DIR_INFO)/$(THISAPP) EXTRA_CONFIG = \ + --host="${BUILDTARGET}" \ + --build="${BUILDTARGET}" \ --prefix=/usr \ --enable-shared \ --disable-nls @@ -76,6 +78,9 @@ ifeq "$(MACHINE_TYPE)" "arm" --with-float=soft endif +EXTRA_CONFIG += \ + --enable-64-bit-bfd + ############################################################################### # Top-level Rules ############################################################################### @@ -125,9 +130,9 @@ $(TARGET) : $(patsubst %,$(DIR_DL)/%,$(objects)) # Prevent installing libiberty to lib64. cd $(DIR_APP) && sed -i 's%\(^MULTIOSDIR = \).*%\1 ../lib%' libiberty/Makefile.in - cd $(DIR_SRC)/binutils-build && $(EXTRA_ENV) MACHINE= $(DIR_APP)/configure $(EXTRA_CONFIG) - cd $(DIR_SRC)/binutils-build && make $(EXTRA_MAKE) $(MAKETUNING) MACHINE= - cd $(DIR_SRC)/binutils-build && make $(EXTRA_INSTALL) install MACHINE= + cd $(DIR_SRC)/binutils-build && $(EXTRA_ENV) $(DIR_APP)/configure $(EXTRA_CONFIG) + cd $(DIR_SRC)/binutils-build && make $(EXTRA_MAKE) $(MAKETUNING) + cd $(DIR_SRC)/binutils-build && make $(EXTRA_INSTALL) install ifeq "$(ROOT)" "" cp -v $(DIR_APP)/include/libiberty.h /usr/include else diff --git a/lfs/gcc b/lfs/gcc index 0264d37f83..ca6f4d722d 100644 --- a/lfs/gcc +++ b/lfs/gcc @@ -114,6 +114,11 @@ ifeq "$(MACHINE)" "i586" --with-tune=generic endif +ifeq "$(MACHINE)" "x86_64" + EXTRA_CONFIG += \ + --disable-multilib +endif + EXTRA_CONFIG += \ --with-bugurl=http://bugtracker.ipfire.org \ --disable-libunwind-exceptions \ diff --git a/lfs/glibc b/lfs/glibc index 4ec71a788e..3391d2d106 100644 --- a/lfs/glibc +++ b/lfs/glibc @@ -304,10 +304,15 @@ ifeq "$(ROOT)" "" ifeq "$(MACHINE_TYPE)" "arm" cd $(DIR_APP) && sed -i 's|libs -o|libs -L/usr/lib -Wl,-dynamic-linker=/lib/ld-linux.so.3 -o|' \ scripts/test-installation.pl +else +ifeq "$(MACHINE)" "x86_64" + cd $(DIR_APP) && sed -i 's|libs -o|libs -L/usr/lib64 -Wl,-dynamic-linker=/lib64/ld-linux-x86-64.so.2 -o|' \ + scripts/test-installation.pl else cd $(DIR_APP) && sed -i 's|libs -o|libs -L/usr/lib -Wl,-dynamic-linker=/lib/ld-linux.so.2 -o|' \ scripts/test-installation.pl endif +endif endif cd $(DIR_SRC)/glibc-build && \ @@ -337,6 +342,8 @@ ifeq "$(ROOT)" "" # Timezone data will be shipped by tzdata. rm -rfv /usr/share/zoneinfo +else + ln -svf lib /tools/lib64 endif @rm -rf $(DIR_APP) $(DIR_SRC)/glibc-build @$(POSTBUILD)