Przeglądaj źródła

boost: fix compile for MIPS

Waldemar Brodkorb 8 lat temu
rodzic
commit
052a320a9c

+ 16 - 3
package/boost/Makefile

@@ -54,6 +54,8 @@ CONFIGURE_ARGS+=	--target=$(GNU_TARGET_NAME) \
 			--prefix=${WRKINST}/usr \
 			--ignore-site-config \
 			--without-mpi \
+			--without-context \
+			--without-coroutine \
 			--without-locale
 
 ifneq (${ADK_PACKAGE_BOOST_IOSTREAMS},)
@@ -95,16 +97,27 @@ ifeq (${ADK_PACKAGE_BOOST_WAVE},)
 CONFIGURE_ARGS+=	--without-wave
 endif
 
+BOOST_ARCH:=	$(ADK_TARGET_ARCH)
+
 ifeq ($(ADK_TARGET_ARCH),x86_64)
 BOOST_ARCH:=	x86
-else ifeq ($(ADK_TARGET_ARCH),ppc)
+endif
+ifeq ($(ADK_TARGET_ARCH),ppc)
 BOOST_ARCH:=	power
-else
-BOOST_ARCH:=	$(ADK_TARGET_ARCH)
 endif
+ifeq ($(ADK_CPU_MIPS_MIPS32),y)
+BOOST_ARCH:=	mips32
+endif
+ifeq ($(ADK_CPU_MIPS_MIPS32R2),y)
+BOOST_ARCH:=	mips32r2
+endif
+
 ifeq ($(ADK_TARGET_ARCH),arm)
 BOOST_ABI:=	abi=aapcs
 endif
+ifeq ($(ADK_TARGET_ARCH),mips)
+BOOST_ABI:=	abi=o32
+endif
 
 # some variables for build
 GPP_PATH:=	${TOOLCHAIN_DIR}/usr/bin/${GNU_TARGET_NAME}-g++

+ 11 - 0
package/boost/patches/patch-tools_build_src_tools_gcc_jam

@@ -0,0 +1,11 @@
+--- boost_1_58_0.orig/tools/build/src/tools/gcc.jam	2015-04-04 19:25:07.000000000 +0200
++++ boost_1_58_0/tools/build/src/tools/gcc.jam	2015-11-03 20:58:00.000000000 +0100
+@@ -451,7 +451,7 @@ rule setup-address-model ( targets * : s
+         else
+         {
+             local arch = [ feature.get-values architecture : $(properties) ] ;
+-            if $(arch) != arm
++            if $(arch) = power || $(arch) = sparc || $(arch) = x86
+             {
+                 if $(model) = 32
+                 {