svn commit: r494220 - head/lang/gcc6

Gerald Pfeifer gerald at FreeBSD.org
Fri Mar 1 01:11:02 UTC 2019


Author: gerald
Date: Fri Mar  1 01:11:01 2019
New Revision: 494220
URL: https://svnweb.freebsd.org/changeset/ports/494220

Log:
  Backport r488673 | andreast | 2018-12-29 from lang/gcc7:
  
    Fix build of GCC on powerpc64.
  
    While building GCC itself we have to use the built GCC libraries to
    configure additional parts of GCC and not the libraires from the host.
  
    Install the built 32-bit libraries. This was not done up to now.
  
  And no longer required GCC 5 to build on powerpc64, making this port a
  natural choice of a "base" for newer members of the lang/gcc* family.
  
  PR:		235964, 231804
  Submitted by:	Piotr Kubaj <pkubaj at anongoth.pl>

Modified:
  head/lang/gcc6/Makefile

Modified: head/lang/gcc6/Makefile
==============================================================================
--- head/lang/gcc6/Makefile	Fri Mar  1 00:52:44 2019	(r494219)
+++ head/lang/gcc6/Makefile	Fri Mar  1 01:11:01 2019	(r494220)
@@ -79,9 +79,6 @@ MAKE_ARGS+=STAGE1_CXXFLAGS=-fbracket-depth=512
 
 .elif ${ARCH} == powerpc64
 CONFIGURE_ENV+=	UNAME_m="powerpc64"
-USE_GCC=	5	# This port requires at least GCC 4.9, and we need
-			# to ensure not to cause a dependency on itself (so
-			# USE_GCC=yes or USE_GCC=X+ are not an option).
 
 .elif ${ARCH} == powerpcspe
 CONFIGURE_ARGS+=	--with-cpu=8548 --enable-e500_double --without-fp
@@ -89,6 +86,7 @@ CONFIGURE_ARGS+=	--with-cpu=8548 --enable-e500_double 
 
 LANGUAGES:=	c,c++,objc,fortran
 TARGLIB=	${PREFIX}/lib/gcc${SUFFIX}
+TARGLIB32=	${PREFIX}/lib32	# The version information is added later
 LIBEXEC=	${PREFIX}/libexec/gcc${SUFFIX}
 GNU_CONFIGURE=	yes
 CONFIGURE_OUTSOURCE=	yes
@@ -174,7 +172,14 @@ post-stage:
 	${RM} -r ${STAGEDIR}${TARGLIB}/gcc/*/${GCC_VERSION}/include-fixed/
 	# Add target libraries and include files to packaging list.
 	${RM} ${WRKDIR}/PLIST.lib
-.for d in ${TARGLIB:S/^${PREFIX}\///} ${LIBEXEC:S/^${PREFIX}\///} include/gcj include/gnu include/java include/javax
+
+.if ${ARCH} == powerpc64 && ${PORT_OPTIONS:MMULTILIB}
+	${MKDIR} ${STAGEDIR}${TARGLIB32}/gcc${SUFFIX}
+	${MV} ${STAGEDIR}${PREFIX}/lib/lib32/* ${STAGEDIR}${TARGLIB32}/gcc${SUFFIX}
+	${RMDIR} ${STAGEDIR}${PREFIX}/lib/lib32
+.endif
+
+.for d in ${TARGLIB:S/^${PREFIX}\///} ${TARGLIB32:S/^${PREFIX}\///} ${LIBEXEC:S/^${PREFIX}\///} include/gcj include/gnu include/java include/javax
 	cd ${STAGEDIR}${PREFIX} ; if [ -d $d ]; then \
 	    ${FIND} $d -type f -o -type l >>${WRKDIR}/PLIST.lib ;\
 	fi


More information about the svn-ports-all mailing list