From owner-freebsd-ppc@FreeBSD.ORG Fri Jun 27 14:24:54 2014 Return-Path: Delivered-To: freebsd-ppc@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 3C99D66E for ; Fri, 27 Jun 2014 14:24:54 +0000 (UTC) Received: from asp.reflexion.net (outbound-245.asp.reflexion.net [69.84.129.245]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id BC25C2548 for ; Fri, 27 Jun 2014 14:24:53 +0000 (UTC) Received: (qmail 435 invoked from network); 27 Jun 2014 14:24:46 -0000 Received: from unknown (HELO mail-cs-02.app.dca.reflexion.local) (10.81.19.2) by 0 (rfx-qmail) with SMTP; 27 Jun 2014 14:24:46 -0000 Received: by mail-cs-02.app.dca.reflexion.local (Reflexion email security v7.30.3) with SMTP; Fri, 27 Jun 2014 10:24:46 -0400 (EDT) Received: (qmail 21125 invoked from network); 27 Jun 2014 14:24:45 -0000 Received: from unknown (HELO iron2.pdx.net) (69.64.224.71) by 0 (rfx-qmail) with (DHE-RSA-AES256-SHA encrypted) SMTP; 27 Jun 2014 14:24:45 -0000 X-No-Relay: not in my network Received: from [192.168.1.8] (c-98-246-178-138.hsd1.or.comcast.net [98.246.178.138]) by iron2.pdx.net (Postfix) with ESMTPSA id 470A01C437E for ; Fri, 27 Jun 2014 07:24:42 -0700 (PDT) From: Mark Millard Subject: powerpc 10.0-STABLE's clang 3.4.1: successfully built devel/libcxxrt , devel/libc++ , and nearly devel/boost-all Message-Id: <5E467F62-3CED-4255-B3F7-02877AE4FB37@dsl-only.net> Date: Fri, 27 Jun 2014 07:24:43 -0700 To: freebsd-ppc@freebsd.org Mime-Version: 1.0 (Mac OS X Mail 7.3 \(1878.2\)) X-Mailer: Apple Mail (2.1878.2) Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.18 X-BeenThere: freebsd-ppc@freebsd.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Porting FreeBSD to the PowerPC List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 27 Jun 2014 14:24:54 -0000 [The following does not deal with libboost_locale.* issues: boost warns = up front that - iconv (libc) : no - iconv (separate) : no - icu : no - icu (lib64) : no - Boost.Locale needs either iconv or ICU library to be built. But the 10849 attempted boost targets all built and it got to Installing for boost-libs-1.55.0_3 before the first error: various .../stage/usr/local/lib/libboost_locale.* not being found. I did not select to build Boost-Python.] The /usr/ports/Mk/Uses/compiler.mk is from before the recent changes = (so that clang would still be used like it was before). This test build got all the way to installing boost-libs-1.55.0_3 before = libboost_locale finally stopped it. devel/libcxxrt and devel/libc++ were installed. See = below. root@FBSDG41466M0:~ # portmaster -t devel/libcxxrt devel/libc++ = devel/boost-all =3D=3D=3D>>> Working on: devel/libcxxrt devel/libc++ devel/boost-all ... (Much omitted) ... =3D=3D=3D>>> Installation of devel/libcxxrt (libcxxrt-20131225_1) = succeeded ... (Much omitted) ... =3D=3D=3D>>> Installation of devel/libc++ (libc++-208080) succeeded ... (Much omitted) ... common.copy = /usr/ports/devel/boost-libs/work/stage/usr/local/lib/libboost_wave.a ...updated 10849 targets... =3D=3D=3D=3D> Compressing man pages (compress-man) =3D=3D=3D> Installing for boost-libs-1.55.0_3 =3D=3D=3D> Checking if devel/boost-libs already installed =3D=3D=3D> Registering installation for boost-libs-1.55.0_3 as = automatic pkg-static: = lstat(/usr/ports/devel/boost-libs/work/stage/usr/local/lib/libboost_locale= .a): No such file or directory pkg-static: = lstat(/usr/ports/devel/boost-libs/work/stage/usr/local/lib/libboost_locale= .so): No such file or directory pkg-static: = lstat(/usr/ports/devel/boost-libs/work/stage/usr/local/lib/libboost_locale= .so.1.55.0): No such file or directory pkg-static: = lstat(/usr/ports/devel/boost-libs/work/stage/usr/local/lib/libboost_locale= .so.5): No such file or directory *** Error code 74 Stop. make[1]: stopped in /usr/ports/devel/boost-libs *** Error code 1 Stop. make: stopped in /usr/ports/devel/boost-libs =3D=3D=3D>>> Installation of boost-libs-1.55.0_3 (devel/boost-libs) = failed =3D=3D=3D>>> Aborting update =3D=3D=3D>>> Update for devel/boost-libs failed =3D=3D=3D>>> Aborting update =3D=3D=3D>>> Update for devel/boost-all failed =3D=3D=3D>>> Aborting update =3D=3D=3D>>> The following actions were performed: Installation of devel/libcxxrt (libcxxrt-20131225_1) Installation of devel/libc++ (libc++-208080) It appears that I did not have the usual compiler/linker problems for built devel/libcxxrt , devel/libc++ , and devel/boost-all on powerpc using 10.0-STABLE's clang 3.4.1 --up to the boost-locale.* issues. The point of this was to see if compiling and linking could work. The = minor changes to devel/libc++/Makefile and devel/boost-all/compiled.mk , while very = small, were only intended to enable the test in my local environment: I do not claim wide = enough knowledge of freebsd for general updates. For devel/libc++/Makefile: --- Makefile.original 2014-06-27 06:17:19.000000000 -0700 +++ Makefile 2014-06-27 06:28:34.000000000 -0700 @@ -21,6 +21,7 @@ LIB_DEPENDS=3D libcxxrt.so:${PORTSDIR}/devel/libcxxrt =20 USES+=3D cmake:outsource compiler:c++11-lang +CXXFLAGS+=3D -nostdlib USE_LDCONFIG=3D yes LDFLAGS+=3D -L${LOCALBASE}/lib =20 For devel/boost-all/compiled.mk: --- compiled.mk.original 2014-06-27 01:03:06.000000000 -0700 +++ compiled.mk 2014-06-27 01:10:34.000000000 -0700 @@ -20,7 +20,9 @@ # Our compiler-flags will be added AFTER those set by bjam. We remove # the optimization level, because Boost sets it itself (to -O3 in case # of gcc/g++): -BJAM_ARGS+=3D cxxflags=3D"${CXXFLAGS:N-O*}" cflags=3D"${CFLAGS:N-O*}" +BJAM_ARGS+=3D cxxflags=3D"${CXXFLAGS:N-O*} = -I${LOCALBASE}/include/c++/v1" cflags=3D"${CFLAGS:N-O*}" + +BJAM_ARGS+=3D linkflags=3D"${LINKFLAGS} -L${LOCALBASE}/lib" =20 BOOST_TOOLSET=3D ${CHOSEN_COMPILER_TYPE} =20 @@ -52,7 +54,7 @@ =20 post-patch: .if defined(USE_BINUTILS) - @${ECHO} "using ${BOOST_TOOLSET} : : ${CXX} : = -B${LOCALBASE}/bin ;" >> = ${WRKSRC}/tools/build/v2/user-config.jam + @${ECHO} "using ${BOOST_TOOLSET} : : ${CXX} : = "-B${LOCALBASE}/bin -L${LOCALBASE}/lib ;" >> = ${WRKSRC}/tools/build/v2/user-config.jam .else @${ECHO} "using ${BOOST_TOOLSET} : : ${CXX} ;" >> = ${WRKSRC}/tools/build/v2/user-config.jam .endif Context & sequence leading to the "success": I did a fresh install from a CD of FreeBSD FBSDG41466M0 10.0-STABLE FreeBSD 10.0-STABLE #0 r267746: Mon Jun 23 08:52:41 UTC 2014 root@grind.freebsd.org:/usr/obj/powerpc.powerpc/usr/src/sys/GENERIC = powerpc This does not have libcxxrt or libc++ prebuilt but does have clang 3.4.1 providing a "freestanding implementation" of C++11. This was to a = PowerMac3,6 (G4 FW800), 2 GB RAM. /usr/ports/... without the recent changes to = /usr/ports/Mk/Uses/compiler.mk . This last is so that clang will be used like it used to be used. Then I got the following in place so the interesting stuff could be done = together without these mixed in: configure for pkg, /usr/sbin/pkg, pkg portmaster, portsnap fetch = extract, portmaster pkg (an update), pkg icu gettext gmake binutils bisdon m4 perl5 gmp mpfr cmake cmake-modules mpc boost-docs boost-jam, portmaster devel/icu (an update) print/texinfo-lite devel/perl5.16 (an update) (I've not looked into why icu is not found and used despite being = present and even built if missing. May be icu needs to be built with clang? I've no = clue.) Then I updated devel/libc++/Makefile and devel/boost-all/compiled.mk and = did portmaster devel/libcxxrt devel/libc++ devel/boost-all (I did not select to have Boost.Python built.) About the Makefile and compiled.mk adjustments: On another powermac I had tried the sequence (before the /usr/ports/Mk/Uses/compiler.mk changes): portmaster devel/libcxxrt portmaster devel/libc++ cmake refused during the last because it tried to pre-test the c++11 = environment for being a valid hosted c++ implementation (i.e., standard library present = and working to some extent), including testing use of -lc++ notation for linking. Such = testing failed, of course: clang is not yet a hosted implementation at this stage. devel/libcxxrt did not complain but it has CXXFLAGS that includes = -nostdlib and that avoids the test of the hosted implementation status: free standing = implementation only. So I manually added -nostdlib into CXXFLAGS for devel/libc++/Makefile = and then devel/libc++ built when I tried portmaster again. devel/boost-all did not automatically look in /usr/local/include/c++/v1/ = and /usr/local/lib/ where devel/libc++'s build put things. So for devel/boost-all I then added -I${LOCALBASE}/include/c++/v1 to = cxxflags in BJAM_ARGS and =20 added linkflags=3D-L${LOCALBASE}/lib to BJAM_ARGS and also added = -L${LOCALBASE}/lib to (just in case). =3D=3D=3D Mark Millard markmi@dsl-only.net