Date: Thu, 24 Mar 2016 16:31:21 -0700 From: Bryan Drewery <bdrewery@FreeBSD.org> To: toolchain@FreeBSD.org Subject: Re: CXXSTD=c++11 Message-ID: <56F478C9.7030900@FreeBSD.org> In-Reply-To: <635A0A5E-63F2-4D42-B6D5-0E841AA713FE@bsdimp.com> References: <56F46BE0.7080909@FreeBSD.org> <635A0A5E-63F2-4D42-B6D5-0E841AA713FE@bsdimp.com>
next in thread | previous in thread | raw e-mail | index | archive | help
This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --jdNKOdfMUajEje00hgDu9PC6wkvHd4IGB Content-Type: multipart/mixed; boundary="VhfWhj4rpRG4bAB9ad7AIoorXdBskCoal" From: Bryan Drewery <bdrewery@FreeBSD.org> To: toolchain@FreeBSD.org Message-ID: <56F478C9.7030900@FreeBSD.org> Subject: Re: CXXSTD=c++11 References: <56F46BE0.7080909@FreeBSD.org> <635A0A5E-63F2-4D42-B6D5-0E841AA713FE@bsdimp.com> In-Reply-To: <635A0A5E-63F2-4D42-B6D5-0E841AA713FE@bsdimp.com> --VhfWhj4rpRG4bAB9ad7AIoorXdBskCoal Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable On 3/24/2016 3:39 PM, Warner Losh wrote: >=20 >> On Mar 24, 2016, at 4:36 PM, Bryan Drewery <bdrewery@freebsd.org> wrot= e: >> >> Is there any problem with forcing -std=3Dc++11 for all CXX/LIB_CXX bui= lds >> now? We do this when using an external GCC since it doesn't default t= o >> the c++11 standard quite yet. As far as I understand, we require c++1= 1 >> to build clang/libc++. >> >> It seems to be the problem at >> https://lists.freebsd.org/pipermail/freebsd-toolchain/2015-October/001= 757.html >> which I've fixed in an upcoming commit to properly pass -std=3Dc++11 t= o >> the lib32 build in CXXFLAGS. >=20 > Wouldn=E2=80=99t that break the spark and mips builds if we did it alwa= ys? They are the > last stragglers to not have a working, fully vetted clang in the tree. >=20 When building with external GCC we're forcing it to use libc++ which uses static_assert which doesn't work without -std=3Dc++11. The external= GCC support now always forces -std=3Dgnu++11 but I was testing with removing it. libatf blows up: > In file included from /usr/obj/powerpc.powerpc64/root/git/freebsd/tmp/u= sr/include/c++/v1/ostream:137:0, > from /root/git/freebsd/contrib/atf/atf-c++/detail/appl= ication.hpp:29, > from /root/git/freebsd/contrib/atf/atf-c++/detail/appl= ication.cpp:26: > /usr/obj/powerpc.powerpc64/root/git/freebsd/tmp/usr/include/c++/v1/memo= ry: In member function 'void std::__1::default_delete<_Tp>::operator()(_T= p*) const': > /usr/obj/powerpc.powerpc64/root/git/freebsd/tmp/usr/include/c++/v1/memo= ry:2514:13: error: typedef '__t2514' locally defined but not used [-Werro= r=3Dunused-local-typedefs] > static_assert(sizeof(_Tp) > 0, "default_delete can not del= ete incomplete type"); I stopped testing at this point. We've fixed it by always passing -std=3Dgnu++11 to the entire build but then that ends up hiding other issues like that Static_assert in libcxxrt being misused. Not passing -std=3Dc++11 to the lib32 build just happens to work because we don't normally build c++ libraries in it that don't otherwise force -std=3Dc++11 (such as libc++ does now). --=20 Regards, Bryan Drewery --VhfWhj4rpRG4bAB9ad7AIoorXdBskCoal-- --jdNKOdfMUajEje00hgDu9PC6wkvHd4IGB Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQEcBAEBAgAGBQJW9HjJAAoJEDXXcbtuRpfPQA8H/iC/m9HfZEG7usLq9OLmwoGo R4ybm6Z3rdZIaNQ/L1pLSjmlg/OxaqWhUGV1UnNkfyMoGhr5KuB7e1eOnlNZdg5B ou8BxpdyttpQowfzI2Okf9rLUdGm1el6PnOR+EdJfuG6shHKsIiFjfHNWZuT7Qx1 Mo3Vx7SSIytQc0bwVlGsHhfFA5SbKdgpYo7Q9gM30hPPd+nfPMetIldegZExBP85 XgO+Y/RoJeaSq/59AlVGmUDb6FLflyFCj5HlTb+oaL+8lkOC+lBT34+JslSnj0+A 2YJvl3AIm14HwoNzA+ZDNLJQFI4w+q2/1Pgg/AMWrHLkOnOx9gAxH1DE4F5fSq8= =2I2h -----END PGP SIGNATURE----- --jdNKOdfMUajEje00hgDu9PC6wkvHd4IGB--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?56F478C9.7030900>