public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
From: "Justin Lecher" <jlec@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] proj/sci:master commit in: sci-mathematics/netgen/files/, sci-mathematics/netgen/
Date: Mon, 22 Feb 2016 08:38:07 +0000 (UTC)	[thread overview]
Message-ID: <1456130191.3addb11abe96717bdd72e01ee5dff2a47aa3f9e7.jlec@gentoo> (raw)

commit:     3addb11abe96717bdd72e01ee5dff2a47aa3f9e7
Author:     Grégory Salvan <apieum <AT> gmail <DOT> com>
AuthorDate: Sat Feb 13 11:40:48 2016 +0000
Commit:     Justin Lecher <jlec <AT> gentoo <DOT> org>
CommitDate: Mon Feb 22 08:36:31 2016 +0000
URL:        https://gitweb.gentoo.org/proj/sci.git/commit/?id=3addb11a

patch netgen for occ to integrate version 5.3.1 see #436

 .../files/netgen-5.x-occ-stl-api-change.patch      | 94 ++++++++++++++++++++++
 sci-mathematics/netgen/netgen-5.3.1.ebuild         | 16 +++-
 2 files changed, 109 insertions(+), 1 deletion(-)

diff --git a/sci-mathematics/netgen/files/netgen-5.x-occ-stl-api-change.patch b/sci-mathematics/netgen/files/netgen-5.x-occ-stl-api-change.patch
new file mode 100644
index 0000000..05f3a54
--- /dev/null
+++ b/sci-mathematics/netgen/files/netgen-5.x-occ-stl-api-change.patch
@@ -0,0 +1,94 @@
+--- libsrc/occ/occgeom.cpp	2014-08-29 11:54:03.000000000 +0200
++++ libsrc/occ/occgeom.cpp	2016-02-12 21:14:49.258982206 +0100
+@@ -149,7 +149,7 @@
+ 
+          for (exp0.Init (shape, TopAbs_FACE); exp0.More(); exp0.Next())
+          {
+-            // Variable to hold the colour (if there exists one) of 
++            // Variable to hold the colour (if there exists one) of
+             // the current face being processed
+             Quantity_Color face_colour;
+ 
+@@ -190,7 +190,7 @@
+                rebuild->Replace(face, newface, Standard_False);
+             }
+ 
+-            // Set the original colour of the face to the newly created 
++            // Set the original colour of the face to the newly created
+             // face (after the healing process)
+             face = TopoDS::Face (exp0.Current());
+             face_colours->SetColor(face,face_colour,XCAFDoc_ColorSurf);
+@@ -815,11 +815,11 @@
+       face_maxh.SetSize (fmap.Extent());
+       face_maxh = mparam.maxh;
+ 
+-      // Philippose - 15/01/2010      
+-      face_maxh_modified.DeleteAll();      
+-      face_maxh_modified.SetSize(fmap.Extent());      
++      // Philippose - 15/01/2010
++      face_maxh_modified.DeleteAll();
++      face_maxh_modified.SetSize(fmap.Extent());
+       face_maxh_modified = 0;
+-      
++
+ 
+       // Philippose - 17/01/2009
+       face_sel_status.DeleteAll();
+@@ -845,7 +845,7 @@
+       cout << "Trying to sew faces ..." << flush;
+ 
+       BRepOffsetAPI_Sewing sewedObj(1);
+- 
++
+       for (int i = 1; i <= fmap.Extent(); i++)
+       {
+          TopoDS_Face face = TopoDS::Face (fmap(i));
+@@ -1038,9 +1038,6 @@
+    {
+       cout << "writing stl..."; cout.flush();
+       StlAPI_Writer writer;
+-      writer.RelativeMode() = Standard_False;
+-
+-      writer.SetDeflection(0.02);
+       writer.Write(shape,filename);
+ 
+       cout << "done" << endl;
+@@ -1109,7 +1106,7 @@
+       }
+ 
+ 
+-      // For the IGES Reader, all the shapes can be exported as one compund shape 
++      // For the IGES Reader, all the shapes can be exported as one compund shape
+       // using the "OneShape" member
+       occgeo->shape = reader.OneShape();
+       occgeo->face_colours = iges_colour_contents;
+@@ -1187,7 +1184,7 @@
+       }
+ 
+ 
+-      // For the STEP File Reader in OCC, the 1st Shape contains the entire 
++      // For the STEP File Reader in OCC, the 1st Shape contains the entire
+       // compound geometry as one shape
+       occgeo->shape = step_shape_contents->GetShape(step_shapes.Value(1));
+       occgeo->face_colours = step_colour_contents;
+@@ -1218,7 +1215,7 @@
+       }
+ 
+       // Philippose - 23/02/2009
+-      // Fixed a bug in the OpenCascade XDE Colour handling when 
++      // Fixed a bug in the OpenCascade XDE Colour handling when
+       // opening BREP Files, since BREP Files have no colour data.
+       // Hence, the face_colours Handle needs to be created as a NULL handle.
+       occgeo->face_colours = Handle_XCAFDoc_ColorTool();
+@@ -1236,9 +1233,9 @@
+   void OCCGeometry :: Save (string sfilename) const
+   {
+     const char * filename = sfilename.c_str();
+-    if (strlen(filename) < 4) 
++    if (strlen(filename) < 4)
+       throw NgException ("illegal filename");
+-    
++
+     if (strcmp (&filename[strlen(filename)-3], "igs") == 0)
+       {
+ 	IGESControl_Writer writer("millimeters", 1);

diff --git a/sci-mathematics/netgen/netgen-5.3.1.ebuild b/sci-mathematics/netgen/netgen-5.3.1.ebuild
index 8a2f60b..16441ff 100644
--- a/sci-mathematics/netgen/netgen-5.3.1.ebuild
+++ b/sci-mathematics/netgen/netgen-5.3.1.ebuild
@@ -25,7 +25,7 @@ DEPEND="
 	opencascade? ( sci-libs/opencascade:* )
 	ffmpeg? ( media-video/ffmpeg )
 	jpeg? ( virtual/jpeg:0= )
-	mpi? ( virtual/mpi ( || ( sci-libs/parmetis sci-libs/metis ) ) ) "
+	mpi? ( virtual/mpi ( || ( sci-libs/parmetis <sci-libs/metis-5.0 ) ) sci-libs/hdf5[mpi] ) "
 RDEPEND="${DEPEND}"
 # Note, MPI has not be tested.
 
@@ -33,6 +33,14 @@ src_prepare() {
 	# Adapted from http://sourceforge.net/projects/netgen-mesher/forums/forum/905307/topic/5422824
 	epatch "${FILESDIR}/${PN}-5.x-missing-define.patch"
 	epatch "${FILESDIR}/${PN}-5.x-metis-numflag.patch"
+	epatch "${FILESDIR}/${PN}-5.x-occ-stl-api-change.patch"
+	if use mpi; then
+		export CC=mpicc
+		export CXX=mpic++
+		export FC=mpif90
+		export F90=mpif90
+		export F77=mpif77
+	fi
 	eautoreconf
 }
 
@@ -47,8 +55,14 @@ src_configure() {
 		append-ldflags -L$CASROOT/lin/$(get_libdir)
 	fi
 	if use mpi; then
+		ewarn "*************************************************************************"
+		ewarn ""
+		ewarn "MPI has not been tested, you should probably deactivate the mpi use flag"
+		ewarn ""
+		ewarn "*************************************************************************"
 		myconf="${myconf} --enable-parallel"
 		append-cppflags -I/usr/include/metis
+		append-ldflags -L/usr/$(get_libdir)/openmpi/
 	fi
 	use ffmpeg && myconf="${myconf} --enable-ffmpeg"
 	use jpeg && myconf="${myconf} --enable-jpeglib"


             reply	other threads:[~2016-02-22  8:38 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-02-22  8:38 Justin Lecher [this message]
  -- strict thread matches above, loose matches on Subject: below --
2022-01-13 14:19 [gentoo-commits] proj/sci:master commit in: sci-mathematics/netgen/files/, sci-mathematics/netgen/ Andrew Ammerlaan
2016-02-22  8:38 Justin Lecher
2016-02-22  8:38 Justin Lecher
2016-02-22  8:38 Justin Lecher
2016-02-22  8:38 Justin Lecher
2016-02-22  8:38 Justin Lecher
2013-12-03 14:53 Justin Lecher

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1456130191.3addb11abe96717bdd72e01ee5dff2a47aa3f9e7.jlec@gentoo \
    --to=jlec@gentoo.org \
    --cc=gentoo-commits@lists.gentoo.org \
    --cc=gentoo-dev@lists.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox