From owner-svn-src-head@freebsd.org Sun Mar 27 00:37:55 2016 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id EA4F4AD585B; Sun, 27 Mar 2016 00:37:55 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id AF48E1223; Sun, 27 Mar 2016 00:37:55 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id u2R0bsIZ002106; Sun, 27 Mar 2016 00:37:54 GMT (envelope-from dim@FreeBSD.org) Received: (from dim@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id u2R0bsQH002104; Sun, 27 Mar 2016 00:37:54 GMT (envelope-from dim@FreeBSD.org) Message-Id: <201603270037.u2R0bsQH002104@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: dim set sender to dim@FreeBSD.org using -f From: Dimitry Andric Date: Sun, 27 Mar 2016 00:37:54 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r297299 - in head: contrib/libcxxrt lib/libcxxrt X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 27 Mar 2016 00:37:56 -0000 Author: dim Date: Sun Mar 27 00:37:54 2016 New Revision: 297299 URL: https://svnweb.freebsd.org/changeset/base/297299 Log: Compile libcxxrt as C++11, since it is only really used in combination with libc++, which is also C++11. Also change one _Static_assert (which is really C11) back into static_assert, like upstream. This should help when compiling libcxxrt with newer versions of gcc, which refuse to recognize any form of static assertions, if not compiling for C++11 or higher. While here, add -nostdinc++ to CFLAGS, to prevent picking up any C++ headers outside the source tree. Modified: head/contrib/libcxxrt/guard.cc head/lib/libcxxrt/Makefile Modified: head/contrib/libcxxrt/guard.cc ============================================================================== --- head/contrib/libcxxrt/guard.cc Sat Mar 26 23:39:53 2016 (r297298) +++ head/contrib/libcxxrt/guard.cc Sun Mar 27 00:37:54 2016 (r297299) @@ -101,7 +101,7 @@ typedef struct { uint32_t init_half; uint32_t lock_half; } guard_t; -_Static_assert(sizeof(guard_t) == sizeof(uint64_t), ""); +static_assert(sizeof(guard_t) == sizeof(uint64_t), ""); static const uint32_t LOCKED = 1; static const uint32_t INITIALISED = static_cast(1) << 24; # endif Modified: head/lib/libcxxrt/Makefile ============================================================================== --- head/lib/libcxxrt/Makefile Sat Mar 26 23:39:53 2016 (r297298) +++ head/lib/libcxxrt/Makefile Sun Mar 27 00:37:54 2016 (r297299) @@ -20,7 +20,10 @@ SRCS+= libelftc_dem_gnu3.c\ guard.cc WARNS= 0 -CFLAGS+= -I${SRCDIR} +CFLAGS+= -I${SRCDIR} -nostdinc++ +.if empty(CXXFLAGS:M-std=*) +CXXFLAGS+= -std=c++11 +.endif VERSION_MAP= ${.CURDIR}/Version.map .include