From 7047a0b2b2d18d51594cad92d5356bd626da063d Mon Sep 17 00:00:00 2001 From: Waldemar Brodkorb Date: Fri, 29 May 2009 13:13:17 +0200 Subject: add lemote / loongson2f target support (no runtime tests yet) - update glibc to latest version (GIT), tarball includes glibc-ports needed for MIPS architecture - fix building of toolchain for mips64el glibc/uclibc - use /lib instead of /lib64 (no biarch support) - fix X11 dependencies in build system - fix glibc build errors for openldap, libnl, mpd and rtorrent - verified toolchain changes on alix1c --- toolchain/binutils/Makefile | 7 ++- toolchain/gcc/Makefile | 7 +++ toolchain/gcc/patches/no-lib64.patch | 11 ++++ toolchain/glibc/Makefile | 23 ++++--- toolchain/glibc/Makefile.inc | 6 +- toolchain/glibc/patches/binutils.patch | 12 ---- toolchain/glibc/patches/gcc43.patch | 18 ------ toolchain/glibc/patches/i586-chk.patch | 15 ----- toolchain/glibc/patches/install-extra.patch | 84 -------------------------- toolchain/glibc/patches/install-lib.patch | 17 ++++++ toolchain/glibc/patches/make-install-lib.patch | 17 ------ toolchain/glibc/patches/mips64.patch | 58 ++++++++++++++++++ toolchain/uClibc/Makefile | 2 + toolchain/uClibc/patches/mips64.patch | 12 ++++ 14 files changed, 129 insertions(+), 160 deletions(-) create mode 100644 toolchain/gcc/patches/no-lib64.patch delete mode 100644 toolchain/glibc/patches/binutils.patch delete mode 100644 toolchain/glibc/patches/gcc43.patch delete mode 100644 toolchain/glibc/patches/i586-chk.patch delete mode 100644 toolchain/glibc/patches/install-extra.patch create mode 100644 toolchain/glibc/patches/install-lib.patch delete mode 100644 toolchain/glibc/patches/make-install-lib.patch create mode 100644 toolchain/glibc/patches/mips64.patch create mode 100644 toolchain/uClibc/patches/mips64.patch (limited to 'toolchain') diff --git a/toolchain/binutils/Makefile b/toolchain/binutils/Makefile index 217b8e77b..b7791eaca 100644 --- a/toolchain/binutils/Makefile +++ b/toolchain/binutils/Makefile @@ -14,6 +14,10 @@ else CONFOPTS+= --disable-libssp endif +ifeq ($(ADK_LINUX_MIPS64_LEMOTE),y) +CONFOPTS+= --enable-64-bit-bfd +endif + $(WRKBUILD)/.headers: $(WRKBUILD)/.configure_done: (cd $(WRKBUILD); \ @@ -25,10 +29,11 @@ $(WRKBUILD)/.configure_done: --disable-nls \ --with-sysroot=$(TOOLCHAIN_SYSROOT) \ --with-sysroot=$(STAGING_DIR) \ - ${CONFOPTS} \ + --disable-multilib \ --disable-dependency-tracking \ --disable-libtool-lock \ --disable-werror \ + ${CONFOPTS} \ ); touch $@ diff --git a/toolchain/gcc/Makefile b/toolchain/gcc/Makefile index a85e4fa74..a0e972c3f 100644 --- a/toolchain/gcc/Makefile +++ b/toolchain/gcc/Makefile @@ -23,8 +23,10 @@ GCC_CONFOPTS= --prefix=$(STAGING_TOOLS) \ --disable-__cxa_atexit \ --enable-target-optspace \ --with-gnu-ld \ + --without-headers \ --disable-libmudflap \ --disable-libgomp \ + --disable-biarch \ --disable-multilib \ --disable-nls @@ -38,6 +40,10 @@ ifeq ($(ADK_NO_FPU),y) GCC_CONFOPTS+= --with-float=soft endif +ifeq ($(ADK_LINUX_MIPS64_LEMOTE),y) +GCC_CONFOPTS+= --with-abi=64 +endif + include ${TOPDIR}/mk/buildhlp.mk GCC_BUILD_DIR1:= $(WRKBUILD)-initial @@ -74,6 +80,7 @@ $(GCC_BUILD_DIR2)/.configured: ${GCC_CONFOPTS} \ --enable-languages=$(TARGET_LANGUAGES) \ --with-sysroot=$(STAGING_DIR) \ + --with-slibdir=$(STAGING_DIR)/lib \ --enable-shared \ ); touch $@ diff --git a/toolchain/gcc/patches/no-lib64.patch b/toolchain/gcc/patches/no-lib64.patch new file mode 100644 index 000000000..efa4099ee --- /dev/null +++ b/toolchain/gcc/patches/no-lib64.patch @@ -0,0 +1,11 @@ +diff -Nur gcc-4.4.0.orig/gcc/config/mips/t-linux64 gcc-4.4.0/gcc/config/mips/t-linux64 +--- gcc-4.4.0.orig/gcc/config/mips/t-linux64 2006-06-06 14:51:24.000000000 +0200 ++++ gcc-4.4.0/gcc/config/mips/t-linux64 2009-05-28 18:13:45.000000000 +0200 +@@ -1,6 +1,6 @@ + MULTILIB_OPTIONS = mabi=n32/mabi=32/mabi=64 + MULTILIB_DIRNAMES = n32 32 64 +-MULTILIB_OSDIRNAMES = ../lib32 ../lib ../lib64 ++MULTILIB_OSDIRNAMES = ../lib ../lib ../lib + + EXTRA_MULTILIB_PARTS=crtbegin.o crtend.o crtbeginS.o crtendS.o crtbeginT.o + diff --git a/toolchain/glibc/Makefile b/toolchain/glibc/Makefile index a819c65d9..19aee9952 100644 --- a/toolchain/glibc/Makefile +++ b/toolchain/glibc/Makefile @@ -24,14 +24,17 @@ $(WRKBUILD)/.headers_configure: $(WRKBUILD)/configure \ --prefix=/usr \ --build=$(GNU_HOST_NAME) \ - --host=$(GNU_HOST_NAME) \ - --target=$(REAL_GNU_TARGET_NAME) \ + --host=$(REAL_GNU_TARGET_NAME) \ --disable-nls \ --without-cvs \ + --with-__thread \ + --with-tls \ + --enable-add-ons \ + --enable-kernel="2.6.0" \ --disable-sanity-checks \ - ${GLIBC_CONFOPTS} \ --with-headers=$(TOOLCHAIN_SYSROOT)/usr/include \ --with-sysroot=$(TOOLCHAIN_SYSROOT) \ + ${GLIBC_CONFOPTS} \ ); touch $@ @@ -41,8 +44,7 @@ $(WRKBUILD)/.headers: $(WRKBUILD)/.headers_configure install_root=$(TOOLCHAIN_SYSROOT) \ CFLAGS="-DBOOTSTRAP_GCC" install-headers touch $(TOOLCHAIN_SYSROOT)/usr/include/gnu/stubs.h - $(CP) $(GLIBC_BUILD_DIR)/bits/stdio_lim.h \ - $(TOOLCHAIN_SYSROOT)/usr/include/bits + touch $(TOOLCHAIN_SYSROOT)/usr/include/bits/stdio_lim.h touch $@ $(WRKBUILD)/.configure_done: @@ -57,9 +59,10 @@ $(WRKBUILD)/.configure_done: LD=${REAL_GNU_TARGET_NAME}-ld \ libc_cv_forced_unwind=yes \ libc_cv_c_cleanup=yes \ + libc_cv_gnu99_inline=yes \ $(WRKBUILD)/configure \ --prefix=/usr \ - --build=$(GNU_TARGET_NAME) \ + --build=$(GNU_HOST_NAME) \ --host=$(REAL_GNU_TARGET_NAME) \ --disable-nls \ --without-cvs \ @@ -68,11 +71,12 @@ $(WRKBUILD)/.configure_done: --without-gd \ --enable-shared \ --enable-stackguard-randomization \ - --enable-add-ons=nptl --with-__thread \ + --with-__thread \ --with-tls \ - --enable-tls \ - ${GLIBC_CONFOPTS} \ + --enable-add-ons \ + --enable-kernel=2.6.0 \ --with-headers=$(TOOLCHAIN_SYSROOT)/usr/include \ + ${GLIBC_CONFOPTS} \ ); touch $@ @@ -88,7 +92,6 @@ $(WRKBUILD)/.compiled: $(WRKBUILD)/.installed: PATH='${TARGET_PATH}' \ - #CFLAGS="$(TARGET_CFLAGS_ARCH) $(TARGET_CFLAGS)" \ $(MAKE) -C $(GLIBC_BUILD_DIR2) \ install_root=$(STAGING_DIR) \ install-lib-all install-headers \ diff --git a/toolchain/glibc/Makefile.inc b/toolchain/glibc/Makefile.inc index b2784a195..22c9cd710 100644 --- a/toolchain/glibc/Makefile.inc +++ b/toolchain/glibc/Makefile.inc @@ -4,7 +4,7 @@ # material, please see the LICENCE file in the top-level directory. PKG_NAME:= glibc -PKG_VERSION:= 2.7 +PKG_VERSION:= 2.10-current PKG_RELEASE:= 1 -PKG_MD5SUM:= 0b4bc75fb7413bbd7e43c0a0e7c672b6 -MASTER_SITES:= ${MASTER_SITE_GNU:=glibc/} +PKG_MD5SUM:= f1d6d30f762e0be537a1f84d26fa0403 +MASTER_SITES:= http://www.openadk.org/distfiles diff --git a/toolchain/glibc/patches/binutils.patch b/toolchain/glibc/patches/binutils.patch deleted file mode 100644 index 5b1bd763e..000000000 --- a/toolchain/glibc/patches/binutils.patch +++ /dev/null @@ -1,12 +0,0 @@ -diff -Nur glibc-2.7.orig/sysdeps/i386/fpu/ftestexcept.c glibc-2.7/sysdeps/i386/fpu/ftestexcept.c ---- glibc-2.7.orig/sysdeps/i386/fpu/ftestexcept.c 2004-03-05 11:14:48.000000000 +0100 -+++ glibc-2.7/sysdeps/i386/fpu/ftestexcept.c 2008-12-22 01:03:19.000000000 +0100 -@@ -26,7 +26,7 @@ - int - fetestexcept (int excepts) - { -- int temp; -+ short temp; - int xtemp = 0; - - /* Get current exceptions. */ diff --git a/toolchain/glibc/patches/gcc43.patch b/toolchain/glibc/patches/gcc43.patch deleted file mode 100644 index 8bd45ee8c..000000000 --- a/toolchain/glibc/patches/gcc43.patch +++ /dev/null @@ -1,18 +0,0 @@ -diff -Nur glibc-2.7.orig/configure glibc-2.7/configure ---- glibc-2.7.orig/configure 2007-10-18 13:22:23.000000000 +0200 -+++ glibc-2.7/configure 2008-11-29 23:48:57.461566623 +0100 -@@ -5062,8 +5062,12 @@ - # header directory and add that to the list. NOTE: Only does the right - # thing on a system that doesn't need fixincludes. (Not presently a problem.) - if test -n "$sysheaders"; then -- ccheaders=`$CC -print-file-name=include` -- SYSINCLUDES="-nostdinc -isystem $ccheaders \ -+ SYSINCLUDES=-nostdinc -+ for d in include include-fixed; do -+ i=`$CC -print-file-name="$d"` && test "x$i" != "x$d" && -+ SYSINCLUDES="$SYSINCLUDES -isystem $i" -+ done -+ SYSINCLUDES="$SYSINCLUDES \ - -isystem `echo $sysheaders | sed 's/:/ -isystem /g'`" - if test -n "$CXX"; then - cxxversion=`$CXX -dumpversion 2>&5` && diff --git a/toolchain/glibc/patches/i586-chk.patch b/toolchain/glibc/patches/i586-chk.patch deleted file mode 100644 index 8ebc182e0..000000000 --- a/toolchain/glibc/patches/i586-chk.patch +++ /dev/null @@ -1,15 +0,0 @@ -diff -Nur glibc-2.7.orig/sysdeps/i386/i586/memcpy_chk.S glibc-2.7/sysdeps/i386/i586/memcpy_chk.S ---- glibc-2.7.orig/sysdeps/i386/i586/memcpy_chk.S 1970-01-01 01:00:00.000000000 +0100 -+++ glibc-2.7/sysdeps/i386/i586/memcpy_chk.S 2008-09-17 12:22:02.000000000 +0200 -@@ -0,0 +1 @@ -+#include -diff -Nur glibc-2.7.orig/sysdeps/i386/i586/mempcpy_chk.S glibc-2.7/sysdeps/i386/i586/mempcpy_chk.S ---- glibc-2.7.orig/sysdeps/i386/i586/mempcpy_chk.S 1970-01-01 01:00:00.000000000 +0100 -+++ glibc-2.7/sysdeps/i386/i586/mempcpy_chk.S 2008-09-17 12:22:02.000000000 +0200 -@@ -0,0 +1 @@ -+#include -diff -Nur glibc-2.7.orig/sysdeps/i386/i586/memset_chk.S glibc-2.7/sysdeps/i386/i586/memset_chk.S ---- glibc-2.7.orig/sysdeps/i386/i586/memset_chk.S 1970-01-01 01:00:00.000000000 +0100 -+++ glibc-2.7/sysdeps/i386/i586/memset_chk.S 2008-09-17 12:22:02.000000000 +0200 -@@ -0,0 +1 @@ -+#include diff --git a/toolchain/glibc/patches/install-extra.patch b/toolchain/glibc/patches/install-extra.patch deleted file mode 100644 index 790bafc17..000000000 --- a/toolchain/glibc/patches/install-extra.patch +++ /dev/null @@ -1,84 +0,0 @@ -diff -Nur glibc-2.7.orig/elf/Makefile glibc-2.7/elf/Makefile ---- glibc-2.7.orig/elf/Makefile 2007-08-16 23:20:11.000000000 +0200 -+++ glibc-2.7/elf/Makefile 2008-09-17 08:57:12.000000000 +0200 -@@ -116,7 +116,7 @@ - ifeq (yes,$(build-shared)) - extra-objs = $(all-rtld-routines:%=%.os) soinit.os sofini.os interp.os - generated += librtld.os dl-allobjs.os ld.so ldd --install-others = $(inst_slibdir)/$(rtld-installed-name) -+install-extra = $(inst_slibdir)/$(rtld-installed-name) - install-bin-script = ldd - endif - -diff -Nur glibc-2.7.orig/iconvdata/Makefile glibc-2.7/iconvdata/Makefile ---- glibc-2.7.orig/iconvdata/Makefile 2007-09-30 06:00:02.000000000 +0200 -+++ glibc-2.7/iconvdata/Makefile 2008-09-17 08:56:57.000000000 +0200 -@@ -211,7 +211,7 @@ - - - extra-objs += $(modules.so) --install-others = $(addprefix $(inst_gconvdir)/, $(modules.so)) \ -+install-extra = $(addprefix $(inst_gconvdir)/, $(modules.so)) \ - $(inst_gconvdir)/gconv-modules - - # We can build the conversion tables for numerous charsets automatically. -diff -Nur glibc-2.7.orig/intl/Makefile glibc-2.7/intl/Makefile ---- glibc-2.7.orig/intl/Makefile 2005-05-04 19:53:42.000000000 +0200 -+++ glibc-2.7/intl/Makefile 2008-09-17 08:55:58.000000000 +0200 -@@ -45,7 +45,7 @@ - - before-compile = $(objpfx)msgs.h - --install-others = $(inst_msgcatdir)/locale.alias -+install-extra = $(inst_msgcatdir)/locale.alias - - generated = msgs.h mtrace-tst-gettext tst-gettext.mtrace - generated-dirs := domaindir localedir -diff -Nur glibc-2.7.orig/localedata/Makefile glibc-2.7/localedata/Makefile ---- glibc-2.7.orig/localedata/Makefile 2007-10-02 19:19:40.000000000 +0200 -+++ glibc-2.7/localedata/Makefile 2008-09-17 08:55:35.000000000 +0200 -@@ -102,7 +102,7 @@ - endif - - # Files to install. --install-others := $(addprefix $(inst_i18ndir)/, \ -+install-extra := $(addprefix $(inst_i18ndir)/, \ - $(addsuffix .gz, $(charmaps)) \ - $(locales)) - -diff -Nur glibc-2.7.orig/po/Makefile glibc-2.7/po/Makefile ---- glibc-2.7.orig/po/Makefile 2007-05-29 20:08:41.000000000 +0200 -+++ glibc-2.7/po/Makefile 2008-09-17 08:55:15.000000000 +0200 -@@ -46,7 +46,7 @@ - mo-installed = $(inst_msgcatdir)/%/LC_MESSAGES/$(domainname).mo - - # Files to install: a $(domainname).mo file for each language. --install-others = $(LINGUAS:%=$(mo-installed)) -+install-extra = $(LINGUAS:%=$(mo-installed)) - - # Files to distribute: all the source and compiled binary translation files. - distribute = $(ALL_LINGUAS:=.po) $(BROKEN_LINGUAS:=.po) $(ALL_LINGUAS:=.mo) \ -diff -Nur glibc-2.7.orig/sunrpc/Makefile glibc-2.7/sunrpc/Makefile ---- glibc-2.7.orig/sunrpc/Makefile 2006-10-18 21:25:38.000000000 +0200 -+++ glibc-2.7/sunrpc/Makefile 2008-09-17 08:54:26.000000000 +0200 -@@ -52,7 +52,7 @@ - svc_auth.h types.h xdr.h auth_des.h \ - des_crypt.h key_prot.h rpc_des.h) \ - $(rpcsvc:%=rpcsvc/%) rpcsvc/bootparam.h --install-others = $(inst_sysconfdir)/rpc -+install-extra = $(inst_sysconfdir)/rpc - generated = $(rpcsvc:%.x=rpcsvc/%.h) $(rpcsvc:%.x=x%.c) $(rpcsvc:%.x=x%.stmp) \ - $(rpcsvc:%.x=rpcsvc/%.stmp) rpcgen - generated-dirs := rpcsvc -diff -Nur glibc-2.7.orig/timezone/Makefile glibc-2.7/timezone/Makefile ---- glibc-2.7.orig/timezone/Makefile 2007-07-28 22:33:11.000000000 +0200 -+++ glibc-2.7/timezone/Makefile 2008-09-17 08:54:43.000000000 +0200 -@@ -71,7 +71,7 @@ - - ifeq ($(cross-compiling),no) - # Don't try to install the zoneinfo files since we can't run zic. --install-others = $(addprefix $(inst_zonedir)/,$(zonenames) \ -+install-extra = $(addprefix $(inst_zonedir)/,$(zonenames) \ - $(zonenames:%=posix/%) \ - $(zonenames:%=right/%)) \ - $(installed-localtime-file) $(installed-posixrules-file) diff --git a/toolchain/glibc/patches/install-lib.patch b/toolchain/glibc/patches/install-lib.patch new file mode 100644 index 000000000..9be206def --- /dev/null +++ b/toolchain/glibc/patches/install-lib.patch @@ -0,0 +1,17 @@ +diff -Nur glibc-2.9.orig/Makerules glibc-2.9/Makerules +--- glibc-2.9.orig/Makerules 2008-02-07 01:39:18.000000000 +0100 ++++ glibc-2.9/Makerules 2009-05-27 00:30:47.000000000 +0200 +@@ -853,6 +853,13 @@ + installed-libcs := $(foreach o,$(filter-out .os,$(object-suffixes-for-libc)),\ + $(inst_libdir)/$(patsubst %,$(libtype$o),\ + $(libprefix)$(libc-name))) ++ ++install-lib-all: $(inst_slibdir)/libc.so$(libc.so-version) \ ++ $(inst_slibdir)/libc-$(version).so \ ++ $(inst_libdir)/libc.so \ ++ $(inst_libdir)/libc.a \ ++ install-lib ++ + install: $(installed-libcs) + $(installed-libcs): $(inst_libdir)/lib$(libprefix)%: lib $(+force) + $(make-target-directory) diff --git a/toolchain/glibc/patches/make-install-lib.patch b/toolchain/glibc/patches/make-install-lib.patch deleted file mode 100644 index b5fb9295a..000000000 --- a/toolchain/glibc/patches/make-install-lib.patch +++ /dev/null @@ -1,17 +0,0 @@ -diff -Nur glibc-2.7.orig/Makerules glibc-2.7/Makerules ---- glibc-2.7.orig/Makerules 2007-08-26 04:18:03.000000000 +0200 -+++ glibc-2.7/Makerules 2008-09-12 11:35:40.000000000 +0200 -@@ -867,6 +867,13 @@ - installed-libcs := $(foreach o,$(filter-out .os,$(object-suffixes-for-libc)),\ - $(inst_libdir)/$(patsubst %,$(libtype$o),\ - $(libprefix)$(libc-name))) -+ -+install-lib-all: $(inst_slibdir)/libc.so$(libc.so-version) \ -+ $(inst_slibdir)/libc-$(version).so \ -+ $(inst_libdir)/libc.so \ -+ $(inst_libdir)/libc.a \ -+ install-lib -+ - install: $(installed-libcs) - $(installed-libcs): $(inst_libdir)/lib$(libprefix)%: lib $(+force) - $(make-target-directory) diff --git a/toolchain/glibc/patches/mips64.patch b/toolchain/glibc/patches/mips64.patch new file mode 100644 index 000000000..04743e09d --- /dev/null +++ b/toolchain/glibc/patches/mips64.patch @@ -0,0 +1,58 @@ +diff -Nur glibc-2.10-current.orig/ports/sysdeps/mips/mips64/n32/Makefile glibc-2.10-current/ports/sysdeps/mips/mips64/n32/Makefile +--- glibc-2.10-current.orig/ports/sysdeps/mips/mips64/n32/Makefile 2009-05-26 22:53:27.000000000 +0200 ++++ glibc-2.10-current/ports/sysdeps/mips/mips64/n32/Makefile 2009-05-27 02:23:06.000000000 +0200 +@@ -1,6 +1,2 @@ + # `long double' is a distinct type we support. + long-double-fcts = yes +- +-ifeq ($(filter -mabi=n32,$(CC)),) +-CC += -mabi=n32 +-endif +diff -Nur glibc-2.10-current.orig/ports/sysdeps/mips/mips64/n64/Makefile glibc-2.10-current/ports/sysdeps/mips/mips64/n64/Makefile +--- glibc-2.10-current.orig/ports/sysdeps/mips/mips64/n64/Makefile 2009-05-26 22:53:27.000000000 +0200 ++++ glibc-2.10-current/ports/sysdeps/mips/mips64/n64/Makefile 2009-05-27 02:20:00.000000000 +0200 +@@ -1,6 +1,2 @@ + # `long double' is a distinct type we support. + long-double-fcts = yes +- +-ifeq ($(filter -mabi=64,$(CC)),) +-CC += -mabi=64 +-endif +diff -Nur glibc-2.10-current.orig/ports/sysdeps/mips/preconfigure glibc-2.10-current/ports/sysdeps/mips/preconfigure +--- glibc-2.10-current.orig/ports/sysdeps/mips/preconfigure 2009-05-26 22:53:27.000000000 +0200 ++++ glibc-2.10-current/ports/sysdeps/mips/preconfigure 2009-05-27 02:20:14.000000000 +0200 +@@ -22,7 +22,7 @@ + if test $mips_config_abi != $mips_cc_abi; then + # This won't make it to config.make, but we want to + # set this in case configure tests depend on it. +- CPPFLAGS="$CPPFLAGS -mabi=$mips_config_abi" ++ CPPFLAGS="$CPPFLAGS" + fi + ;; + mips*) base_machine=mips machine=mips/mips32/$machine ;; +diff -Nur glibc-2.10-current.orig/ports/sysdeps/unix/sysv/linux/mips/configure glibc-2.10-current/ports/sysdeps/unix/sysv/linux/mips/configure +--- glibc-2.10-current.orig/ports/sysdeps/unix/sysv/linux/mips/configure 2009-05-26 22:53:29.000000000 +0200 ++++ glibc-2.10-current/ports/sysdeps/unix/sysv/linux/mips/configure 2009-05-27 20:34:25.000000000 +0200 +@@ -84,22 +84,6 @@ + # and libc_cv_localedir. + test -n "$libc_cv_slibdir" || \ + case $machine in +- mips/mips64/n64/* ) +- libc_cv_slibdir="/lib64" +- if test "$libdir" = '${exec_prefix}/lib'; then +- libdir='${exec_prefix}/lib64'; +- # Locale data can be shared between 32bit and 64bit libraries +- libc_cv_localedir='${exec_prefix}/lib/locale' +- fi +- ;; +- mips/mips64/n32/* ) +- libc_cv_slibdir="/lib32" +- if test "$libdir" = '${exec_prefix}/lib'; then +- libdir='${exec_prefix}/lib32'; +- # Locale data can be shared between 32bit and 64bit libraries +- libc_cv_localedir='${exec_prefix}/lib/locale' +- fi +- ;; + *) + libc_cv_slibdir="/lib" + ;; diff --git a/toolchain/uClibc/Makefile b/toolchain/uClibc/Makefile index a96f3533a..8a77a6022 100644 --- a/toolchain/uClibc/Makefile +++ b/toolchain/uClibc/Makefile @@ -55,6 +55,7 @@ $(WRKBUILD)/.install_headers: $(WRKBUILD)/.compiled PREFIX=$(STAGING_DIR) \ DEVEL_PREFIX=/ \ RUNTIME_PREFIX=/ \ + CPU_CFLAGS="$(TARGET_CFLAGS)" \ install_dev touch $@ @@ -63,6 +64,7 @@ $(WRKBUILD)/.installed: $(WRKBUILD)/.install_headers PREFIX=$(STAGING_DIR) \ DEVEL_PREFIX=/ \ RUNTIME_PREFIX=/ \ + CPU_CFLAGS="$(TARGET_CFLAGS)" \ install_runtime echo $(PKG_VERSION) >$(STAGING_DIR)/uclibc_version rm -rf $(STAGING_DIR)/lib/libc.so diff --git a/toolchain/uClibc/patches/mips64.patch b/toolchain/uClibc/patches/mips64.patch new file mode 100644 index 000000000..70fcc24e6 --- /dev/null +++ b/toolchain/uClibc/patches/mips64.patch @@ -0,0 +1,12 @@ +diff -Nur uClibc-0.9.30.1.orig/Rules.mak uClibc-0.9.30.1/Rules.mak +--- uClibc-0.9.30.1.orig/Rules.mak 2009-03-02 22:10:04.000000000 +0100 ++++ uClibc-0.9.30.1/Rules.mak 2009-05-28 15:08:37.000000000 +0200 +@@ -292,7 +292,7 @@ + CPU_CFLAGS-$(CONFIG_MIPS_ISA_4)+=-mips4 -mtune=mips4 + CPU_CFLAGS-$(CONFIG_MIPS_ISA_MIPS32)+=-mips32 -mtune=mips32 + CPU_CFLAGS-$(CONFIG_MIPS_ISA_MIPS32R2)+=-march=mips32r2 -mtune=mips32r2 +- CPU_CFLAGS-$(CONFIG_MIPS_ISA_MIPS64)+=-mips64 -mtune=mips32 ++ CPU_CFLAGS-$(CONFIG_MIPS_ISA_MIPS64)+=-mips64 + ifeq ($(strip $(ARCH_BIG_ENDIAN)),y) + CPU_LDFLAGS-$(CONFIG_MIPS_N64_ABI)+=-Wl,-melf64btsmip + CPU_LDFLAGS-$(CONFIG_MIPS_O32_ABI)+=-Wl,-melf32btsmip -- cgit v1.2.3