Index: head/Mk/bsd.port.mk =================================================================== --- head/Mk/bsd.port.mk +++ head/Mk/bsd.port.mk @@ -1098,15 +1098,13 @@ .endif CONFIGURE_ENV+= HOSTCC="${HOSTCC}" HOSTCXX="${HOSTCXX}" CC_FOR_BUILD="${CC_FOR_BUILD}" CXX_FOR_BUILD="${CXX_FOR_BUILD}" -CC= ${XCC} -CXX= ${XCXX} -CFLAGS+= --sysroot=${CROSS_SYSROOT} -isystem ${CROSS_SYSROOT}/usr/include -CXXFLAGS+= --sysroot=${CROSS_SYSROOT} -isystem ${CROSS_SYSROOT}/usr/include -isystem ${CROSS_SYSROOT}/usr/include/c++/v1 -nostdinc++ -CPPFLAGS+= --sysroot=${CROSS_SYSROOT} -isystem ${CROSS_SYSROOT}/usr/include -LDFLAGS+= --sysroot=${CROSS_SYSROOT} +CC= ${XCC} --sysroot=${CROSS_SYSROOT} +CXX= ${XCXX} --sysroot=${CROSS_SYSROOT} +CPP= ${XCPP} --sysroot=${CROSS_SYSROOT} .for _tool in AS AR LD NM OBJCOPY RANLIB SIZE STRINGS ${_tool}= ${CROSS_BINUTILS_PREFIX}${tool:tl} .endfor +LD+= --sysroot=${CROSS_SYSROOT} STRIP_CMD= ${CROSS_BINUTILS_PREFIX}strip # only bmake support the below STRIPBIN= ${STRIP_CMD} @@ -1144,6 +1142,10 @@ .if !defined(ARCH) ARCH!= ${UNAME} -p .endif +HOSTARCH:= ${ARCH} +.if defined(CROSS_TOOLCHAIN) +ARCH= ${CROSS_TOOLCHAIN:C,-.*$,,} +.endif _EXPORTED_VARS+= ARCH # Get the operating system type @@ -2619,7 +2621,7 @@ CONFIGURE_SCRIPT?= configure CONFIGURE_CMD?= ./${CONFIGURE_SCRIPT} -CONFIGURE_TARGET?= ${ARCH}-portbld-${OPSYS:tl}${OSREL} +CONFIGURE_TARGET?= ${HOSTARCH}-portbld-${OPSYS:tl}${OSREL} CONFIGURE_TARGET:= ${CONFIGURE_TARGET:S/--build=//} CONFIGURE_LOG?= config.log Index: head/base/binutils/Makefile =================================================================== --- head/base/binutils/Makefile +++ head/base/binutils/Makefile @@ -8,7 +8,7 @@ COMMENT= GNU binary tools for base MASTERDIR= ${.CURDIR}/../../devel/binutils -PLIST= ${.CURDIR}/pkg-plist.${TARGET_ARCH} +PLIST= ${.CURDIR}/pkg-plist.${ARCH} .if !defined(CROSS_TOOLCHAIN) .error Please define CROSS_TOOLCHAIN before building @@ -18,8 +18,7 @@ .error Please define CROSS_SYSROOT before building .endif -TARGET_ARCH= ${CROSS_TOOLCHAIN:C,-.*$,,} -BUTARGET= ${TARGET_ARCH}-unknown-${OPSYS:tl}${OSREL} +BUTARGET= ${ARCH}-unknown-${OPSYS:tl}${OSREL} CONFIGURE_ARGS+= --disable-host-shared PREFIX= /usr Index: head/base/binutils/pkg-plist.mips =================================================================== --- head/base/binutils/pkg-plist.mips +++ head/base/binutils/pkg-plist.mips @@ -0,0 +1,278 @@ +bin/as +bin/ld +bin/ld.bfd +bin/objdump +bin/%%BUTARGET%%-as +bin/%%BUTARGET%%-ld +bin/%%BUTARGET%%-ld.bfd +bin/%%BUTARGET%%-objdump +%%BUTARGET%%/lib/ldscripts/elf32btsmip.x +%%BUTARGET%%/lib/ldscripts/elf32btsmip.xbn +%%BUTARGET%%/lib/ldscripts/elf32btsmip.xc +%%BUTARGET%%/lib/ldscripts/elf32btsmip.xce +%%BUTARGET%%/lib/ldscripts/elf32btsmip.xd +%%BUTARGET%%/lib/ldscripts/elf32btsmip.xdc +%%BUTARGET%%/lib/ldscripts/elf32btsmip.xdce +%%BUTARGET%%/lib/ldscripts/elf32btsmip.xde +%%BUTARGET%%/lib/ldscripts/elf32btsmip.xdw +%%BUTARGET%%/lib/ldscripts/elf32btsmip.xdwe +%%BUTARGET%%/lib/ldscripts/elf32btsmip.xe +%%BUTARGET%%/lib/ldscripts/elf32btsmip.xn +%%BUTARGET%%/lib/ldscripts/elf32btsmip.xr +%%BUTARGET%%/lib/ldscripts/elf32btsmip.xs +%%BUTARGET%%/lib/ldscripts/elf32btsmip.xsc +%%BUTARGET%%/lib/ldscripts/elf32btsmip.xsce +%%BUTARGET%%/lib/ldscripts/elf32btsmip.xse +%%BUTARGET%%/lib/ldscripts/elf32btsmip.xsw +%%BUTARGET%%/lib/ldscripts/elf32btsmip.xswe +%%BUTARGET%%/lib/ldscripts/elf32btsmip.xu +%%BUTARGET%%/lib/ldscripts/elf32btsmip.xw +%%BUTARGET%%/lib/ldscripts/elf32btsmip.xwe +%%BUTARGET%%/lib/ldscripts/elf32btsmip_fbsd.x +%%BUTARGET%%/lib/ldscripts/elf32btsmip_fbsd.xbn +%%BUTARGET%%/lib/ldscripts/elf32btsmip_fbsd.xc +%%BUTARGET%%/lib/ldscripts/elf32btsmip_fbsd.xce +%%BUTARGET%%/lib/ldscripts/elf32btsmip_fbsd.xd +%%BUTARGET%%/lib/ldscripts/elf32btsmip_fbsd.xdc +%%BUTARGET%%/lib/ldscripts/elf32btsmip_fbsd.xdce +%%BUTARGET%%/lib/ldscripts/elf32btsmip_fbsd.xde +%%BUTARGET%%/lib/ldscripts/elf32btsmip_fbsd.xdw +%%BUTARGET%%/lib/ldscripts/elf32btsmip_fbsd.xdwe +%%BUTARGET%%/lib/ldscripts/elf32btsmip_fbsd.xe +%%BUTARGET%%/lib/ldscripts/elf32btsmip_fbsd.xn +%%BUTARGET%%/lib/ldscripts/elf32btsmip_fbsd.xr +%%BUTARGET%%/lib/ldscripts/elf32btsmip_fbsd.xs +%%BUTARGET%%/lib/ldscripts/elf32btsmip_fbsd.xsc +%%BUTARGET%%/lib/ldscripts/elf32btsmip_fbsd.xsce +%%BUTARGET%%/lib/ldscripts/elf32btsmip_fbsd.xse +%%BUTARGET%%/lib/ldscripts/elf32btsmip_fbsd.xsw +%%BUTARGET%%/lib/ldscripts/elf32btsmip_fbsd.xswe +%%BUTARGET%%/lib/ldscripts/elf32btsmip_fbsd.xu +%%BUTARGET%%/lib/ldscripts/elf32btsmip_fbsd.xw +%%BUTARGET%%/lib/ldscripts/elf32btsmip_fbsd.xwe +%%BUTARGET%%/lib/ldscripts/elf32btsmipn32.x +%%BUTARGET%%/lib/ldscripts/elf32btsmipn32.xbn +%%BUTARGET%%/lib/ldscripts/elf32btsmipn32.xc +%%BUTARGET%%/lib/ldscripts/elf32btsmipn32.xce +%%BUTARGET%%/lib/ldscripts/elf32btsmipn32.xd +%%BUTARGET%%/lib/ldscripts/elf32btsmipn32.xdc +%%BUTARGET%%/lib/ldscripts/elf32btsmipn32.xdce +%%BUTARGET%%/lib/ldscripts/elf32btsmipn32.xde +%%BUTARGET%%/lib/ldscripts/elf32btsmipn32.xdw +%%BUTARGET%%/lib/ldscripts/elf32btsmipn32.xdwe +%%BUTARGET%%/lib/ldscripts/elf32btsmipn32.xe +%%BUTARGET%%/lib/ldscripts/elf32btsmipn32.xn +%%BUTARGET%%/lib/ldscripts/elf32btsmipn32.xr +%%BUTARGET%%/lib/ldscripts/elf32btsmipn32.xs +%%BUTARGET%%/lib/ldscripts/elf32btsmipn32.xsc +%%BUTARGET%%/lib/ldscripts/elf32btsmipn32.xsce +%%BUTARGET%%/lib/ldscripts/elf32btsmipn32.xse +%%BUTARGET%%/lib/ldscripts/elf32btsmipn32.xsw +%%BUTARGET%%/lib/ldscripts/elf32btsmipn32.xswe +%%BUTARGET%%/lib/ldscripts/elf32btsmipn32.xu +%%BUTARGET%%/lib/ldscripts/elf32btsmipn32.xw +%%BUTARGET%%/lib/ldscripts/elf32btsmipn32.xwe +%%BUTARGET%%/lib/ldscripts/elf32btsmipn32_fbsd.x +%%BUTARGET%%/lib/ldscripts/elf32btsmipn32_fbsd.xbn +%%BUTARGET%%/lib/ldscripts/elf32btsmipn32_fbsd.xc +%%BUTARGET%%/lib/ldscripts/elf32btsmipn32_fbsd.xce +%%BUTARGET%%/lib/ldscripts/elf32btsmipn32_fbsd.xd +%%BUTARGET%%/lib/ldscripts/elf32btsmipn32_fbsd.xdc +%%BUTARGET%%/lib/ldscripts/elf32btsmipn32_fbsd.xdce +%%BUTARGET%%/lib/ldscripts/elf32btsmipn32_fbsd.xde +%%BUTARGET%%/lib/ldscripts/elf32btsmipn32_fbsd.xdw +%%BUTARGET%%/lib/ldscripts/elf32btsmipn32_fbsd.xdwe +%%BUTARGET%%/lib/ldscripts/elf32btsmipn32_fbsd.xe +%%BUTARGET%%/lib/ldscripts/elf32btsmipn32_fbsd.xn +%%BUTARGET%%/lib/ldscripts/elf32btsmipn32_fbsd.xr +%%BUTARGET%%/lib/ldscripts/elf32btsmipn32_fbsd.xs +%%BUTARGET%%/lib/ldscripts/elf32btsmipn32_fbsd.xsc +%%BUTARGET%%/lib/ldscripts/elf32btsmipn32_fbsd.xsce +%%BUTARGET%%/lib/ldscripts/elf32btsmipn32_fbsd.xse +%%BUTARGET%%/lib/ldscripts/elf32btsmipn32_fbsd.xsw +%%BUTARGET%%/lib/ldscripts/elf32btsmipn32_fbsd.xswe +%%BUTARGET%%/lib/ldscripts/elf32btsmipn32_fbsd.xu +%%BUTARGET%%/lib/ldscripts/elf32btsmipn32_fbsd.xw +%%BUTARGET%%/lib/ldscripts/elf32btsmipn32_fbsd.xwe +%%BUTARGET%%/lib/ldscripts/elf32ltsmip.x +%%BUTARGET%%/lib/ldscripts/elf32ltsmip.xbn +%%BUTARGET%%/lib/ldscripts/elf32ltsmip.xc +%%BUTARGET%%/lib/ldscripts/elf32ltsmip.xce +%%BUTARGET%%/lib/ldscripts/elf32ltsmip.xd +%%BUTARGET%%/lib/ldscripts/elf32ltsmip.xdc +%%BUTARGET%%/lib/ldscripts/elf32ltsmip.xdce +%%BUTARGET%%/lib/ldscripts/elf32ltsmip.xde +%%BUTARGET%%/lib/ldscripts/elf32ltsmip.xdw +%%BUTARGET%%/lib/ldscripts/elf32ltsmip.xdwe +%%BUTARGET%%/lib/ldscripts/elf32ltsmip.xe +%%BUTARGET%%/lib/ldscripts/elf32ltsmip.xn +%%BUTARGET%%/lib/ldscripts/elf32ltsmip.xr +%%BUTARGET%%/lib/ldscripts/elf32ltsmip.xs +%%BUTARGET%%/lib/ldscripts/elf32ltsmip.xsc +%%BUTARGET%%/lib/ldscripts/elf32ltsmip.xsce +%%BUTARGET%%/lib/ldscripts/elf32ltsmip.xse +%%BUTARGET%%/lib/ldscripts/elf32ltsmip.xsw +%%BUTARGET%%/lib/ldscripts/elf32ltsmip.xswe +%%BUTARGET%%/lib/ldscripts/elf32ltsmip.xu +%%BUTARGET%%/lib/ldscripts/elf32ltsmip.xw +%%BUTARGET%%/lib/ldscripts/elf32ltsmip.xwe +%%BUTARGET%%/lib/ldscripts/elf32ltsmip_fbsd.x +%%BUTARGET%%/lib/ldscripts/elf32ltsmip_fbsd.xbn +%%BUTARGET%%/lib/ldscripts/elf32ltsmip_fbsd.xc +%%BUTARGET%%/lib/ldscripts/elf32ltsmip_fbsd.xce +%%BUTARGET%%/lib/ldscripts/elf32ltsmip_fbsd.xd +%%BUTARGET%%/lib/ldscripts/elf32ltsmip_fbsd.xdc +%%BUTARGET%%/lib/ldscripts/elf32ltsmip_fbsd.xdce +%%BUTARGET%%/lib/ldscripts/elf32ltsmip_fbsd.xde +%%BUTARGET%%/lib/ldscripts/elf32ltsmip_fbsd.xdw +%%BUTARGET%%/lib/ldscripts/elf32ltsmip_fbsd.xdwe +%%BUTARGET%%/lib/ldscripts/elf32ltsmip_fbsd.xe +%%BUTARGET%%/lib/ldscripts/elf32ltsmip_fbsd.xn +%%BUTARGET%%/lib/ldscripts/elf32ltsmip_fbsd.xr +%%BUTARGET%%/lib/ldscripts/elf32ltsmip_fbsd.xs +%%BUTARGET%%/lib/ldscripts/elf32ltsmip_fbsd.xsc +%%BUTARGET%%/lib/ldscripts/elf32ltsmip_fbsd.xsce +%%BUTARGET%%/lib/ldscripts/elf32ltsmip_fbsd.xse +%%BUTARGET%%/lib/ldscripts/elf32ltsmip_fbsd.xsw +%%BUTARGET%%/lib/ldscripts/elf32ltsmip_fbsd.xswe +%%BUTARGET%%/lib/ldscripts/elf32ltsmip_fbsd.xu +%%BUTARGET%%/lib/ldscripts/elf32ltsmip_fbsd.xw +%%BUTARGET%%/lib/ldscripts/elf32ltsmip_fbsd.xwe +%%BUTARGET%%/lib/ldscripts/elf32ltsmipn32.x +%%BUTARGET%%/lib/ldscripts/elf32ltsmipn32.xbn +%%BUTARGET%%/lib/ldscripts/elf32ltsmipn32.xc +%%BUTARGET%%/lib/ldscripts/elf32ltsmipn32.xce +%%BUTARGET%%/lib/ldscripts/elf32ltsmipn32.xd +%%BUTARGET%%/lib/ldscripts/elf32ltsmipn32.xdc +%%BUTARGET%%/lib/ldscripts/elf32ltsmipn32.xdce +%%BUTARGET%%/lib/ldscripts/elf32ltsmipn32.xde +%%BUTARGET%%/lib/ldscripts/elf32ltsmipn32.xdw +%%BUTARGET%%/lib/ldscripts/elf32ltsmipn32.xdwe +%%BUTARGET%%/lib/ldscripts/elf32ltsmipn32.xe +%%BUTARGET%%/lib/ldscripts/elf32ltsmipn32.xn +%%BUTARGET%%/lib/ldscripts/elf32ltsmipn32.xr +%%BUTARGET%%/lib/ldscripts/elf32ltsmipn32.xs +%%BUTARGET%%/lib/ldscripts/elf32ltsmipn32.xsc +%%BUTARGET%%/lib/ldscripts/elf32ltsmipn32.xsce +%%BUTARGET%%/lib/ldscripts/elf32ltsmipn32.xse +%%BUTARGET%%/lib/ldscripts/elf32ltsmipn32.xsw +%%BUTARGET%%/lib/ldscripts/elf32ltsmipn32.xswe +%%BUTARGET%%/lib/ldscripts/elf32ltsmipn32.xu +%%BUTARGET%%/lib/ldscripts/elf32ltsmipn32.xw +%%BUTARGET%%/lib/ldscripts/elf32ltsmipn32.xwe +%%BUTARGET%%/lib/ldscripts/elf32ltsmipn32_fbsd.x +%%BUTARGET%%/lib/ldscripts/elf32ltsmipn32_fbsd.xbn +%%BUTARGET%%/lib/ldscripts/elf32ltsmipn32_fbsd.xc +%%BUTARGET%%/lib/ldscripts/elf32ltsmipn32_fbsd.xce +%%BUTARGET%%/lib/ldscripts/elf32ltsmipn32_fbsd.xd +%%BUTARGET%%/lib/ldscripts/elf32ltsmipn32_fbsd.xdc +%%BUTARGET%%/lib/ldscripts/elf32ltsmipn32_fbsd.xdce +%%BUTARGET%%/lib/ldscripts/elf32ltsmipn32_fbsd.xde +%%BUTARGET%%/lib/ldscripts/elf32ltsmipn32_fbsd.xdw +%%BUTARGET%%/lib/ldscripts/elf32ltsmipn32_fbsd.xdwe +%%BUTARGET%%/lib/ldscripts/elf32ltsmipn32_fbsd.xe +%%BUTARGET%%/lib/ldscripts/elf32ltsmipn32_fbsd.xn +%%BUTARGET%%/lib/ldscripts/elf32ltsmipn32_fbsd.xr +%%BUTARGET%%/lib/ldscripts/elf32ltsmipn32_fbsd.xs +%%BUTARGET%%/lib/ldscripts/elf32ltsmipn32_fbsd.xsc +%%BUTARGET%%/lib/ldscripts/elf32ltsmipn32_fbsd.xsce +%%BUTARGET%%/lib/ldscripts/elf32ltsmipn32_fbsd.xse +%%BUTARGET%%/lib/ldscripts/elf32ltsmipn32_fbsd.xsw +%%BUTARGET%%/lib/ldscripts/elf32ltsmipn32_fbsd.xswe +%%BUTARGET%%/lib/ldscripts/elf32ltsmipn32_fbsd.xu +%%BUTARGET%%/lib/ldscripts/elf32ltsmipn32_fbsd.xw +%%BUTARGET%%/lib/ldscripts/elf32ltsmipn32_fbsd.xwe +%%BUTARGET%%/lib/ldscripts/elf64btsmip.x +%%BUTARGET%%/lib/ldscripts/elf64btsmip.xbn +%%BUTARGET%%/lib/ldscripts/elf64btsmip.xc +%%BUTARGET%%/lib/ldscripts/elf64btsmip.xce +%%BUTARGET%%/lib/ldscripts/elf64btsmip.xd +%%BUTARGET%%/lib/ldscripts/elf64btsmip.xdc +%%BUTARGET%%/lib/ldscripts/elf64btsmip.xdce +%%BUTARGET%%/lib/ldscripts/elf64btsmip.xde +%%BUTARGET%%/lib/ldscripts/elf64btsmip.xdw +%%BUTARGET%%/lib/ldscripts/elf64btsmip.xdwe +%%BUTARGET%%/lib/ldscripts/elf64btsmip.xe +%%BUTARGET%%/lib/ldscripts/elf64btsmip.xn +%%BUTARGET%%/lib/ldscripts/elf64btsmip.xr +%%BUTARGET%%/lib/ldscripts/elf64btsmip.xs +%%BUTARGET%%/lib/ldscripts/elf64btsmip.xsc +%%BUTARGET%%/lib/ldscripts/elf64btsmip.xsce +%%BUTARGET%%/lib/ldscripts/elf64btsmip.xse +%%BUTARGET%%/lib/ldscripts/elf64btsmip.xsw +%%BUTARGET%%/lib/ldscripts/elf64btsmip.xswe +%%BUTARGET%%/lib/ldscripts/elf64btsmip.xu +%%BUTARGET%%/lib/ldscripts/elf64btsmip.xw +%%BUTARGET%%/lib/ldscripts/elf64btsmip.xwe +%%BUTARGET%%/lib/ldscripts/elf64btsmip_fbsd.x +%%BUTARGET%%/lib/ldscripts/elf64btsmip_fbsd.xbn +%%BUTARGET%%/lib/ldscripts/elf64btsmip_fbsd.xc +%%BUTARGET%%/lib/ldscripts/elf64btsmip_fbsd.xce +%%BUTARGET%%/lib/ldscripts/elf64btsmip_fbsd.xd +%%BUTARGET%%/lib/ldscripts/elf64btsmip_fbsd.xdc +%%BUTARGET%%/lib/ldscripts/elf64btsmip_fbsd.xdce +%%BUTARGET%%/lib/ldscripts/elf64btsmip_fbsd.xde +%%BUTARGET%%/lib/ldscripts/elf64btsmip_fbsd.xdw +%%BUTARGET%%/lib/ldscripts/elf64btsmip_fbsd.xdwe +%%BUTARGET%%/lib/ldscripts/elf64btsmip_fbsd.xe +%%BUTARGET%%/lib/ldscripts/elf64btsmip_fbsd.xn +%%BUTARGET%%/lib/ldscripts/elf64btsmip_fbsd.xr +%%BUTARGET%%/lib/ldscripts/elf64btsmip_fbsd.xs +%%BUTARGET%%/lib/ldscripts/elf64btsmip_fbsd.xsc +%%BUTARGET%%/lib/ldscripts/elf64btsmip_fbsd.xsce +%%BUTARGET%%/lib/ldscripts/elf64btsmip_fbsd.xse +%%BUTARGET%%/lib/ldscripts/elf64btsmip_fbsd.xsw +%%BUTARGET%%/lib/ldscripts/elf64btsmip_fbsd.xswe +%%BUTARGET%%/lib/ldscripts/elf64btsmip_fbsd.xu +%%BUTARGET%%/lib/ldscripts/elf64btsmip_fbsd.xw +%%BUTARGET%%/lib/ldscripts/elf64btsmip_fbsd.xwe +%%BUTARGET%%/lib/ldscripts/elf64ltsmip.x +%%BUTARGET%%/lib/ldscripts/elf64ltsmip.xbn +%%BUTARGET%%/lib/ldscripts/elf64ltsmip.xc +%%BUTARGET%%/lib/ldscripts/elf64ltsmip.xce +%%BUTARGET%%/lib/ldscripts/elf64ltsmip.xd +%%BUTARGET%%/lib/ldscripts/elf64ltsmip.xdc +%%BUTARGET%%/lib/ldscripts/elf64ltsmip.xdce +%%BUTARGET%%/lib/ldscripts/elf64ltsmip.xde +%%BUTARGET%%/lib/ldscripts/elf64ltsmip.xdw +%%BUTARGET%%/lib/ldscripts/elf64ltsmip.xdwe +%%BUTARGET%%/lib/ldscripts/elf64ltsmip.xe +%%BUTARGET%%/lib/ldscripts/elf64ltsmip.xn +%%BUTARGET%%/lib/ldscripts/elf64ltsmip.xr +%%BUTARGET%%/lib/ldscripts/elf64ltsmip.xs +%%BUTARGET%%/lib/ldscripts/elf64ltsmip.xsc +%%BUTARGET%%/lib/ldscripts/elf64ltsmip.xsce +%%BUTARGET%%/lib/ldscripts/elf64ltsmip.xse +%%BUTARGET%%/lib/ldscripts/elf64ltsmip.xsw +%%BUTARGET%%/lib/ldscripts/elf64ltsmip.xswe +%%BUTARGET%%/lib/ldscripts/elf64ltsmip.xu +%%BUTARGET%%/lib/ldscripts/elf64ltsmip.xw +%%BUTARGET%%/lib/ldscripts/elf64ltsmip.xwe +%%BUTARGET%%/lib/ldscripts/elf64ltsmip_fbsd.x +%%BUTARGET%%/lib/ldscripts/elf64ltsmip_fbsd.xbn +%%BUTARGET%%/lib/ldscripts/elf64ltsmip_fbsd.xc +%%BUTARGET%%/lib/ldscripts/elf64ltsmip_fbsd.xce +%%BUTARGET%%/lib/ldscripts/elf64ltsmip_fbsd.xd +%%BUTARGET%%/lib/ldscripts/elf64ltsmip_fbsd.xdc +%%BUTARGET%%/lib/ldscripts/elf64ltsmip_fbsd.xdce +%%BUTARGET%%/lib/ldscripts/elf64ltsmip_fbsd.xde +%%BUTARGET%%/lib/ldscripts/elf64ltsmip_fbsd.xdw +%%BUTARGET%%/lib/ldscripts/elf64ltsmip_fbsd.xdwe +%%BUTARGET%%/lib/ldscripts/elf64ltsmip_fbsd.xe +%%BUTARGET%%/lib/ldscripts/elf64ltsmip_fbsd.xn +%%BUTARGET%%/lib/ldscripts/elf64ltsmip_fbsd.xr +%%BUTARGET%%/lib/ldscripts/elf64ltsmip_fbsd.xs +%%BUTARGET%%/lib/ldscripts/elf64ltsmip_fbsd.xsc +%%BUTARGET%%/lib/ldscripts/elf64ltsmip_fbsd.xsce +%%BUTARGET%%/lib/ldscripts/elf64ltsmip_fbsd.xse +%%BUTARGET%%/lib/ldscripts/elf64ltsmip_fbsd.xsw +%%BUTARGET%%/lib/ldscripts/elf64ltsmip_fbsd.xswe +%%BUTARGET%%/lib/ldscripts/elf64ltsmip_fbsd.xu +%%BUTARGET%%/lib/ldscripts/elf64ltsmip_fbsd.xw +%%BUTARGET%%/lib/ldscripts/elf64ltsmip_fbsd.xwe +share/man/man1/as.1.gz +share/man/man1/ld.1.gz +share/man/man1/objdump.1.gz +share/man/man1/%%BUTARGET%%-as.1.gz +share/man/man1/%%BUTARGET%%-ld.1.gz +share/man/man1/%%BUTARGET%%-objdump.1.gz Index: head/base/gcc/Makefile =================================================================== --- head/base/gcc/Makefile +++ head/base/gcc/Makefile @@ -34,16 +34,15 @@ AS_FOR_TARGET=/usr/bin/as \ LD_FOR_TARGET=/usr/bin/ld \ NM_FOR_TARGET=/usr/bin/nm -TARGET_ARCH= ${CROSS_TOOLCHAIN:C,-.*$,,} -GCC_TARGET= ${TARGET_ARCH}-unknown-${OPSYS:tl}${OSREL} +GCC_TARGET= ${ARCH}-unknown-${OPSYS:tl}${OSREL} USES= gmake libtool tar:bzip2 makeinfo -PLIST_SUB= TARGETARCH=${TARGET_ARCH} \ +PLIST_SUB= TARGETARCH=${ARCH} \ OPSYS=${OPSYS:tl} \ GCC_TARGET=${GCC_TARGET} \ GCC_VERSION=${PORTVERSION} -TARGET_ARCH= ${CROSS_TOOLCHAIN:C,-.*$,,} EXTRA_PATCHES+= ${.CURDIR}/../../devel/powerpc64-gcc/files/freebsd-format-extensions +EXTRA_PATCHES+= ${.CURDIR}/../../devel/powerpc64-gcc/files/patch-gcc-freebsd-mips GNU_CONFIGURE= yes CONFIGURE_OUTSOURCE= yes @@ -52,12 +51,26 @@ --enable-languages=c,c++ \ --disable-nls \ --without-headers \ + --with-gxx-include-dir=/usr/include/c++/v1/ \ --with-build-sysroot=${CROSS_SYSROOT} \ -with-pkgversion="GNU Collection for FreeBSD" ALL_TARGET?= all-gcc INSTALL_TARGET?= install-gcc +.include + +.if ${ARCH:Mmips*} +PLIST_SUB+= MIPS="" +.else +PLIST_SUB+= MIPS="@comment " +.endif +.if ${ARCH:Mpowerpc*} +PLIST_SUB+= POWERPC="" +.else +PLIST_SUB+= POWERPC="@comment " +.endif + post-extract: cd ${WRKSRC}; ${LN} -sf ../mpfr-3.1.6 mpfr ; \ ${LN} -sf ../gmp-6.1.2 gmp ; \ @@ -66,6 +79,8 @@ post-patch: @${REINPLACE_CMD} -e '/LIBSTDCXX/ s/stdc\+\+/c\+\+/g ' \ ${WRKSRC}//gcc/cp/g++spec.c + @${REINPLACE_CMD} -e '/LOCAL_INCLUDE_DIR/ d ' \ + ${WRKSRC}//gcc/Makefile.in post-install: ${MV} ${STAGEDIR}/usr/bin/gcov-tool ${STAGEDIR}/usr/bin/${GCC_TARGET}-gcov-tool ; \ @@ -81,5 +96,6 @@ ${LN} -sf ${GCC_TARGET}-gcc ${STAGEDIR}/usr/bin/cc ; \ ${LN} -sf ${GCC_TARGET}-gcc.1.gz ${STAGEDIR}/${MANDIR}1/cc.1.gz ${RM} -r ${STAGEDIR}/usr/share/info + ${RM} -r ${STAGEDIR}/usr/lib/gcc/${GCC_TARGET}/${PORTVERSION}/include-fixed .include Index: head/base/gcc/files/patch-Makefile.in =================================================================== --- head/base/gcc/files/patch-Makefile.in +++ head/base/gcc/files/patch-Makefile.in @@ -1,72 +0,0 @@ ---- Makefile.in.orig 2016-04-13 11:02:08.000000000 -0700 -+++ Makefile.in 2017-12-08 14:01:46.149339000 -0800 -@@ -2784,7 +2784,8 @@ - esac; \ - module_srcdir=libiberty; \ - rm -f no-such-file || : ; \ -- CONFIG_SITE=no-such-file $(SHELL) \ -+ CONFIG_SITE=no-such-file CFLAGS="${HOST_CFLAGS}" \ -+ CPPFLAGS="${HOST_CPPFLAGS}" CXXFLAGS="${HOST_CXXFLAGS}" $(SHELL) \ - $$s/$$module_srcdir/configure \ - --srcdir=$${topdir}/$$module_srcdir \ - $(BUILD_CONFIGARGS) --build=${build_alias} --host=${build_alias} \ -@@ -2841,7 +2842,8 @@ - esac; \ - module_srcdir=bison; \ - rm -f no-such-file || : ; \ -- CONFIG_SITE=no-such-file $(SHELL) \ -+ CONFIG_SITE=no-such-file CFLAGS="${HOST_CFLAGS}" \ -+ CPPFLAGS="${HOST_CPPFLAGS}" CXXFLAGS="${HOST_CXXFLAGS}" $(SHELL) \ - $$s/$$module_srcdir/configure \ - --srcdir=$${topdir}/$$module_srcdir \ - $(BUILD_CONFIGARGS) --build=${build_alias} --host=${build_alias} \ -@@ -2898,7 +2900,8 @@ - esac; \ - module_srcdir=flex; \ - rm -f no-such-file || : ; \ -- CONFIG_SITE=no-such-file $(SHELL) \ -+ CONFIG_SITE=no-such-file CFLAGS="${HOST_CFLAGS}" \ -+ CPPFLAGS="${HOST_CPPFLAGS}" CXXFLAGS="${HOST_CXXFLAGS}" $(SHELL) \ - $$s/$$module_srcdir/configure \ - --srcdir=$${topdir}/$$module_srcdir \ - $(BUILD_CONFIGARGS) --build=${build_alias} --host=${build_alias} \ -@@ -2955,7 +2958,8 @@ - esac; \ - module_srcdir=m4; \ - rm -f no-such-file || : ; \ -- CONFIG_SITE=no-such-file $(SHELL) \ -+ CONFIG_SITE=no-such-file CFLAGS="${HOST_CFLAGS}" \ -+ CPPFLAGS="${HOST_CPPFLAGS}" CXXFLAGS="${HOST_CXXFLAGS}" $(SHELL) \ - $$s/$$module_srcdir/configure \ - --srcdir=$${topdir}/$$module_srcdir \ - $(BUILD_CONFIGARGS) --build=${build_alias} --host=${build_alias} \ -@@ -3012,7 +3016,8 @@ - esac; \ - module_srcdir=texinfo; \ - rm -f no-such-file || : ; \ -- CONFIG_SITE=no-such-file $(SHELL) \ -+ CONFIG_SITE=no-such-file CFLAGS="${HOST_CFLAGS}" \ -+ CPPFLAGS="${HOST_CPPFLAGS}" CXXFLAGS="${HOST_CXXFLAGS}" $(SHELL) \ - $$s/$$module_srcdir/configure \ - --srcdir=$${topdir}/$$module_srcdir \ - $(BUILD_CONFIGARGS) --build=${build_alias} --host=${build_alias} \ -@@ -3069,7 +3074,8 @@ - esac; \ - module_srcdir=fixincludes; \ - rm -f no-such-file || : ; \ -- CONFIG_SITE=no-such-file $(SHELL) \ -+ CONFIG_SITE=no-such-file CFLAGS="${HOST_CFLAGS}" \ -+ CPPFLAGS="${HOST_CPPFLAGS}" CXXFLAGS="${HOST_CXXFLAGS}" $(SHELL) \ - $$s/$$module_srcdir/configure \ - --srcdir=$${topdir}/$$module_srcdir \ - $(BUILD_CONFIGARGS) --build=${build_alias} --host=${build_alias} \ -@@ -3126,7 +3132,8 @@ - esac; \ - module_srcdir=libcpp; \ - rm -f no-such-file || : ; \ -- CONFIG_SITE=no-such-file $(SHELL) \ -+ CONFIG_SITE=no-such-file CFLAGS="${HOST_CFLAGS}" \ -+ CPPFLAGS="${HOST_CPPFLAGS}" CXXFLAGS="${HOST_CXXFLAGS}" $(SHELL) \ - $$s/$$module_srcdir/configure \ - --srcdir=$${topdir}/$$module_srcdir \ - $(BUILD_CONFIGARGS) --build=${build_alias} --host=${build_alias} \ Index: head/base/gcc/files/patch-gcc-Makefile.in =================================================================== --- head/base/gcc/files/patch-gcc-Makefile.in +++ head/base/gcc/files/patch-gcc-Makefile.in @@ -1,11 +0,0 @@ ---- gcc/Makefile.in.orig 2017-12-09 14:33:56.283411000 -0800 -+++ gcc/Makefile.in 2017-12-09 14:34:16.979742000 -0800 -@@ -779,7 +779,7 @@ - BUILD_NO_PIE_FLAG = @BUILD_NO_PIE_FLAG@ - BUILD_LDFLAGS += $(BUILD_NO_PIE_FLAG) - BUILD_CPPFLAGS= -I. -I$(@D) -I$(srcdir) -I$(srcdir)/$(@D) \ -- -I$(srcdir)/../include @INCINTL@ $(CPPINC) $(CPPFLAGS) -+ -I$(srcdir)/../include @INCINTL@ $(CPPINC) $(CPPFLAGS_FOR_BUILD) - - # Actual name to use when installing a native compiler. - GCC_INSTALL_NAME := $(shell echo gcc|sed '$(program_transform_name)') Index: head/base/gcc/files/patch-gcc-configure =================================================================== --- head/base/gcc/files/patch-gcc-configure +++ head/base/gcc/files/patch-gcc-configure @@ -1,11 +0,0 @@ ---- gcc/configure.orig 2017-12-09 14:33:36.570113000 -0800 -+++ gcc/configure 2017-12-09 14:33:50.647310000 -0800 -@@ -11803,7 +11803,7 @@ - CC="${CC_FOR_BUILD}" CFLAGS="${CFLAGS_FOR_BUILD}" \ - CXX="${CXX_FOR_BUILD}" CXXFLAGS="${CXXFLAGS_FOR_BUILD}" \ - LD="${LD_FOR_BUILD}" LDFLAGS="${LDFLAGS_FOR_BUILD}" \ -- GMPINC="" CPPFLAGS="${CPPFLAGS} -DGENERATOR_FILE" \ -+ GMPINC="" CPPFLAGS="${CPPFLAGS_FOR_BUILD} -DGENERATOR_FILE" \ - ${realsrcdir}/configure \ - --enable-languages=${enable_languages-all} \ - --target=$target_alias --host=$build_alias --build=$build_alias Index: head/base/gcc/pkg-plist =================================================================== --- head/base/gcc/pkg-plist +++ head/base/gcc/pkg-plist @@ -14,33 +14,18 @@ bin/%%GCC_TARGET%%-gcc-ranlib bin/%%GCC_TARGET%%-gcov bin/%%GCC_TARGET%%-gcov-tool -lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/include-fixed/README -lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/include-fixed/libmilter/mfapi.h -lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/include-fixed/limits.h -lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/include-fixed/netinet/ip_fil.h -lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/include-fixed/netinet/ip_lookup.h -lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/include-fixed/netinet/ip_nat.h -lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/include-fixed/netinet/ip_proxy.h -lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/include-fixed/netinet/ip_scan.h -lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/include-fixed/netinet/ip_state.h -lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/include-fixed/stddef.h -lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/include-fixed/stdio.h -lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/include-fixed/stdlib.h -lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/include-fixed/sys/types.h -lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/include-fixed/syslimits.h -lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/include-fixed/unistd.h -lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/include-fixed/wchar.h -lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/include/altivec.h +%%POWERPC%%lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/include/altivec.h lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/include/float.h -lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/include/htmintrin.h -lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/include/htmxlintrin.h +%%POWERPC%%lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/include/htmintrin.h +%%POWERPC%%lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/include/htmxlintrin.h lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/include/iso646.h -lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/include/paired.h -lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/include/ppc-asm.h -lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/include/ppu_intrinsics.h -lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/include/si2vmx.h -lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/include/spe.h -lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/include/spu2vmx.h +%%MIPS%%lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/include/loongson.h +%%POWERPC%%lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/include/paired.h +%%POWERPC%%lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/include/ppc-asm.h +%%POWERPC%%lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/include/ppu_intrinsics.h +%%POWERPC%%lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/include/si2vmx.h +%%POWERPC%%lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/include/spe.h +%%POWERPC%%lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/include/spu2vmx.h lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/include/stdalign.h lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/include/stdarg.h lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/include/stdatomic.h @@ -52,7 +37,7 @@ lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/include/stdnoreturn.h lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/include/tgmath.h lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/include/varargs.h -lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/include/vec_types.h +%%POWERPC%%lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/include/vec_types.h lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/install-tools/fixinc_list lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/install-tools/gsyslimits.h lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/install-tools/include/README @@ -109,21 +94,27 @@ lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/plugin/include/collect2.h lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/plugin/include/conditions.h lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/plugin/include/config.h -lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/plugin/include/config/dbxelf.h +%%POWERPC%%lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/plugin/include/config/dbxelf.h lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/plugin/include/config/elfos.h lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/plugin/include/config/%%OPSYS%%-spec.h lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/plugin/include/config/%%OPSYS%%-stdint.h lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/plugin/include/config/%%OPSYS%%.h lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/plugin/include/config/initfini-array.h -lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/plugin/include/config/rs6000/default64.h -lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/plugin/include/config/rs6000/%%OPSYS%%64.h -lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/plugin/include/config/rs6000/option-defaults.h -lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/plugin/include/config/rs6000/rs6000-builtin.def -lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/plugin/include/config/rs6000/rs6000-cpus.def -lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/plugin/include/config/rs6000/rs6000-opts.h -lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/plugin/include/config/rs6000/rs6000-protos.h -lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/plugin/include/config/rs6000/rs6000.h -lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/plugin/include/config/rs6000/sysv4.h +%%MIPS%%lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/plugin/include/config/mips/elf.h +%%MIPS%%lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/plugin/include/config/mips/%%OPSYS%%.h +%%MIPS%%lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/plugin/include/config/mips/mips-opts.h +%%MIPS%%lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/plugin/include/config/mips/mips-protos.h +%%MIPS%%lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/plugin/include/config/mips/mips.h +%%MIPS%%lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/plugin/include/config/vxworks-dummy.h +%%POWERPC%%lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/plugin/include/config/rs6000/default64.h +%%POWERPC%%lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/plugin/include/config/rs6000/%%OPSYS%%64.h +%%POWERPC%%lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/plugin/include/config/rs6000/option-defaults.h +%%POWERPC%%lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/plugin/include/config/rs6000/rs6000-builtin.def +%%POWERPC%%lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/plugin/include/config/rs6000/rs6000-cpus.def +%%POWERPC%%lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/plugin/include/config/rs6000/rs6000-opts.h +%%POWERPC%%lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/plugin/include/config/rs6000/rs6000-protos.h +%%POWERPC%%lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/plugin/include/config/rs6000/rs6000.h +%%POWERPC%%lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/plugin/include/config/rs6000/sysv4.h lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/plugin/include/configargs.h lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/plugin/include/context.h lib/gcc/%%GCC_TARGET%%/%%GCC_VERSION%%/plugin/include/convert.h