From owner-svn-ports-all@freebsd.org Thu Feb 25 22:21:39 2016 Return-Path: Delivered-To: svn-ports-all@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 579A7AB410C; Thu, 25 Feb 2016 22:21:39 +0000 (UTC) (envelope-from rakuco@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 330C081A; Thu, 25 Feb 2016 22:21:39 +0000 (UTC) (envelope-from rakuco@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id u1PMLc5J007302; Thu, 25 Feb 2016 22:21:38 GMT (envelope-from rakuco@FreeBSD.org) Received: (from rakuco@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id u1PMLb6C007298; Thu, 25 Feb 2016 22:21:37 GMT (envelope-from rakuco@FreeBSD.org) Message-Id: <201602252221.u1PMLb6C007298@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: rakuco set sender to rakuco@FreeBSD.org using -f From: Raphael Kubo da Costa Date: Thu, 25 Feb 2016 22:21:37 +0000 (UTC) To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r409563 - head/cad/openvsp/files X-SVN-Group: ports-head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-ports-all@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: SVN commit messages for the ports tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 25 Feb 2016 22:21:39 -0000 Author: rakuco Date: Thu Feb 25 22:21:37 2016 New Revision: 409563 URL: https://svnweb.freebsd.org/changeset/ports/409563 Log: Add patches to fix the build on FreeBSD 11 with libc++. OpenVSP does something like this: using namespace std; class array { ... }; Which causes the build to fail with HEAD's libc++. Even though the port does not use -std=c++11, libc++ still declares an array class that conflicts with the one OpenVSP has. Enclose OpenVSP's array declaration in a namespace to avoid these conflicts. PR: 207253 Approved by: fernando.apesteguia@gmail.com (maintainer) Added: head/cad/openvsp/files/patch-src_util__code_array.h (contents, props changed) head/cad/openvsp/files/patch-src_vsp_af.cpp (contents, props changed) head/cad/openvsp/files/patch-src_vsp_havoc__geom.cpp (contents, props changed) head/cad/openvsp/files/patch-src_vsp_havoc__geom.h (contents, props changed) Added: head/cad/openvsp/files/patch-src_util__code_array.h ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/cad/openvsp/files/patch-src_util__code_array.h Thu Feb 25 22:21:37 2016 (r409563) @@ -0,0 +1,25 @@ +Workaround for libc++, which declares std::array even if not in C++11 mode (see +ports/207253 for a bigger discussion). +--- src/util_code/array.h.orig 2016-02-25 10:29:49 UTC ++++ src/util_code/array.h +@@ -20,11 +20,12 @@ + #include + using namespace std; + ++namespace openvsp { ++ + // Define Error Flags // + #define BELOW_BOUNDS 0 + #define ABOVE_BOUNDS 1 + +- + template + + class array +@@ -328,5 +331,6 @@ void array::print_error_messa + + } + ++} // namespace openvsp + + #endif Added: head/cad/openvsp/files/patch-src_vsp_af.cpp ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/cad/openvsp/files/patch-src_vsp_af.cpp Thu Feb 25 22:21:37 2016 (r409563) @@ -0,0 +1,13 @@ +Workaround for libc++, which declares std::array even if not in C++11 mode (see +ports/207253 for a bigger discussion). +--- src/vsp/af.cpp.orig 2016-02-25 10:34:17 UTC ++++ src/vsp/af.cpp +@@ -1744,7 +1744,7 @@ vec3d Af::get_rounded_end_cap(int index) + void Af::invert_airfoil() + { + int i; +- array z; ++ openvsp::array z; + z.init(num_pnts); + + //===== Switch Upper and Lower Z values ===== Added: head/cad/openvsp/files/patch-src_vsp_havoc__geom.cpp ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/cad/openvsp/files/patch-src_vsp_havoc__geom.cpp Thu Feb 25 22:21:37 2016 (r409563) @@ -0,0 +1,13 @@ +Workaround for libc++, which declares std::array even if not in C++11 mode (see +ports/207253 for a bigger discussion). +--- src/vsp/havoc_geom.cpp.orig 2016-02-25 10:35:42 UTC ++++ src/vsp/havoc_geom.cpp +@@ -428,7 +428,7 @@ void Havoc_geom::generate_planform_curve + + //==== Find Xsec Locations ====// + int num_xsecs = havoc_num_xsecs - 3; +- array< double > tmp_x; ++ openvsp::array< double > tmp_x; + tmp_x.init ( num_xsecs ); + + for ( i = 0 ; i < num_xsecs ; i++ ) Added: head/cad/openvsp/files/patch-src_vsp_havoc__geom.h ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/cad/openvsp/files/patch-src_vsp_havoc__geom.h Thu Feb 25 22:21:37 2016 (r409563) @@ -0,0 +1,21 @@ +Workaround for libc++, which declares std::array even if not in C++11 mode (see +ports/207253 for a bigger discussion). +--- src/vsp/havoc_geom.h.orig 2016-02-25 10:33:52 UTC ++++ src/vsp/havoc_geom.h +@@ -88,11 +88,11 @@ class Havoc_geom : public Geom + int havoc_num_xsecs; + int havoc_num_pnts; + +- array< double > x_locs; +- array< double > left; +- array< double > right; +- array< double > upper; +- array< double > lower; ++ openvsp::array< double > x_locs; ++ openvsp::array< double > left; ++ openvsp::array< double > right; ++ openvsp::array< double > upper; ++ openvsp::array< double > lower; + + Parm length; +