diff options
author | Niels Horn <niels.horn@gmail.com> | 2012-01-13 07:00:40 -0500 |
---|---|---|
committer | Erik Hanson <erik@slackbuilds.org> | 2012-01-13 14:43:12 -0600 |
commit | b422475cbb3f32d9b0bb8abb9b257b4c7a7c30c8 (patch) | |
tree | 8dd729d942ecb8d36e8d414cc7d6d210caf4e529 | |
parent | 7a3a2c91539571f8f136eedf4f2f1264fae807e6 (diff) | |
download | slackbuilds-b422475cbb3f32d9b0bb8abb9b257b4c7a7c30c8.tar.gz |
graphics/FreeCAD: Updated for version 0.12.5284.
Signed-off-by: dsomero <xgizzmo@slackbuilds.org>
-rw-r--r-- | graphics/FreeCAD/FreeCAD.SlackBuild | 41 | ||||
-rw-r--r-- | graphics/FreeCAD/FreeCAD.info | 6 | ||||
-rw-r--r-- | graphics/FreeCAD/OpenCASCADE65.patch | 49 | ||||
-rw-r--r-- | graphics/FreeCAD/OpenCASCADE652.patch | 84 | ||||
-rw-r--r-- | graphics/FreeCAD/README | 2 |
5 files changed, 123 insertions, 59 deletions
diff --git a/graphics/FreeCAD/FreeCAD.SlackBuild b/graphics/FreeCAD/FreeCAD.SlackBuild index 75b816f84e..f893ef1a6a 100644 --- a/graphics/FreeCAD/FreeCAD.SlackBuild +++ b/graphics/FreeCAD/FreeCAD.SlackBuild @@ -2,7 +2,7 @@ # Slackware build script for FreeCAD -# Copyright 2010-2011 Niels Horn, Rio de Janeiro, RJ, Brazil +# Copyright 2010-2012 Niels Horn, Rio de Janeiro, RJ, Brazil # All rights reserved. # # Redistribution and use of this script, with or without modification, is @@ -22,10 +22,10 @@ # OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF # ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -# revision date: 2011/08/10 +# revision date: 2012/01/04 PRGNAM=FreeCAD -VERSION=${VERSION:-0.11.3729} +VERSION=${VERSION:-0.12.5284} BUILD=${BUILD:-1} TAG=${TAG:-_SBo} @@ -64,13 +64,15 @@ rm -rf $PKG mkdir -p $TMP $PKG $OUTPUT cd $TMP rm -rf $PRGNAM-$VERSION -tar xvf $CWD/$SRCNAM-$VERSION.tar.gz +tar xvf $CWD/$SRCNAM-$VERSION.tar.xz cd $PRGNAM-$VERSION chown -R root:root . chmod -R u+w,go+r-w,a-s . -# Patch for OpenCASCADE-6.5.x -patch -p1 < $CWD/OpenCASCADE65.patch +# FreeCAD is ready for OpenCASCADE 6.5.{0,1} - patch for 6.5.2 +patch -p1 < $CWD/OpenCASCADE652.patch + +./autogen.sh # Fix references to old boost_*-mt libs sed -i "/-lboost/s/-mt\"/\"/g" configure @@ -92,9 +94,36 @@ CXXFLAGS="$SLKCFLAGS" \ make make install DESTDIR=$PKG +### This is for future use. FreeCAD is switching to cmake, but is is not +### 100% operational yet. +### These are the options that *should* do it: + +#mkdir build +#cd build +# cmake \ +# -DCMAKE_C_FLAGS:STRING="$SLKCFLAGS" \ +# -DCMAKE_CXX_FLAGS:STRING="$SLKCFLAGS" \ +# -DCMAKE_INSTALL_PREFIX=/opt/$PRGNAM \ +# -DRESOURCEDIR=/opt/$PRGNAM/share/data \ +# -DLIB_SUFFIX=${LIBDIRSUFFIX} \ +# -DMAN_INSTALL_DIR=/usr/man \ +# -DDOCDIR=/usr/doc/$PRGNAM-$VERSION \ +# -DOCC_INCLUDE_DIR=/usr/include/OpenCASCADE \ +# -DOCC_LIBRARY=/usr/lib${LIBDIRSUFFIX} \ +# -DCMAKE_BUILD_TYPE=Release .. +# +# make V=1 +# make install DESTDIR=$PKG +#cd .. + find $PKG | xargs file | grep -e "executable" -e "shared object" | grep ELF \ | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true +# Get man page from debian +mkdir -p $PKG/usr/man/man1 +cat package/debian/freecad.1 > $PKG/usr/man/man1/FreeCAD.1 +gzip -9 $PKG/usr/man/man1/FreeCAD.1 + # Copy icon & desktop file mkdir -p $PKG/usr/share/{applications,pixmaps} cp $PKG/opt/$PRGNAM/share/freecad.xpm $PKG/usr/share/pixmaps/ diff --git a/graphics/FreeCAD/FreeCAD.info b/graphics/FreeCAD/FreeCAD.info index c34e180b7b..57e0d6e2be 100644 --- a/graphics/FreeCAD/FreeCAD.info +++ b/graphics/FreeCAD/FreeCAD.info @@ -1,8 +1,8 @@ PRGNAM="FreeCAD" -VERSION="0.11.3729" +VERSION="0.12.5284" HOMEPAGE="http://free-cad.sourceforge.net/" -DOWNLOAD="http://downloads.sourceforge.net/free-cad/freecad-0.11.3729.tar.gz" -MD5SUM="cd68f52ee201c49a83a400b87686b9b9" +DOWNLOAD="http://www.nielshorn.net/_download/slackware/source/freecad-0.12.5284.tar.xz" +MD5SUM="3b6efa9d97de093e7bb42aabd3bcbc54" DOWNLOAD_x86_64="" MD5SUM_x86_64="" MAINTAINER="Niels Horn" diff --git a/graphics/FreeCAD/OpenCASCADE65.patch b/graphics/FreeCAD/OpenCASCADE65.patch deleted file mode 100644 index 8fcc40842e..0000000000 --- a/graphics/FreeCAD/OpenCASCADE65.patch +++ /dev/null @@ -1,49 +0,0 @@ ---- FreeCAD-0.11.3729/src/3rdParty/salomesmesh/src/SMESH/SMESH_MeshEditor.cpp 2010-10-17 05:59:46.000000000 -0200 -+++ FreeCAD-0.11.3729_patched/src/3rdParty/salomesmesh/src/SMESH/SMESH_MeshEditor.cpp 2011-08-10 20:04:59.000000000 -0300 -@@ -2205,8 +2205,8 @@ - if ( projector.IsDone() ) { - double u, v, minVal = DBL_MAX; - for ( int i = projector.NbExt(); i > 0; i-- ) -- if ( projector.Value( i ) < minVal ) { -- minVal = projector.Value( i ); -+ if ( projector.SquareDistance( i ) < minVal ) { -+ minVal = projector.SquareDistance( i ); - projector.Point( i ).Parameter( u, v ); - } - result.SetCoord( u, v ); ---- FreeCAD-0.11.3729/src/3rdParty/salomesmesh/src/SMESH/SMESH_Pattern.cpp 2010-10-17 05:59:46.000000000 -0200 -+++ FreeCAD-0.11.3729_patched/src/3rdParty/salomesmesh/src/SMESH/SMESH_Pattern.cpp 2011-08-10 20:06:21.000000000 -0300 -@@ -436,8 +436,8 @@ - } - double u, v, minVal = DBL_MAX; - for ( int i = theProjectorPS.NbExt(); i > 0; i-- ) -- if ( theProjectorPS.Value( i ) < minVal ) { -- minVal = theProjectorPS.Value( i ); -+ if ( theProjectorPS.SquareDistance( i ) < minVal ) { -+ minVal = theProjectorPS.SquareDistance( i ); - theProjectorPS.Point( i ).Parameter( u, v ); - } - return gp_XY( u, v ); ---- FreeCAD-0.11.3729/src/Mod/Part/App/PrimitiveFeature.cpp 2010-08-27 11:22:14.000000000 -0300 -+++ FreeCAD-0.11.3729_patched/src/Mod/Part/App/PrimitiveFeature.cpp 2011-08-10 20:41:35.000000000 -0300 -@@ -141,9 +141,6 @@ - case BRepBuilderAPI_ParametersOutOfRange:
- error = "parameters out of range";
- break;
-- case BRepBuilderAPI_SurfaceNotC2:
-- error = "surface not C2";
-- break;
- default:
- error = "unknown error";
- break;
---- FreeCAD-0.11.3729/src/Mod/Part/App/TopoShape.cpp 2010-11-14 06:53:08.000000000 -0200 -+++ FreeCAD-0.11.3729_patched/src/Mod/Part/App/TopoShape.cpp 2011-08-10 20:43:03.000000000 -0300 -@@ -139,8 +139,6 @@ - return "Curve projection failed";
- case BRepBuilderAPI_ParametersOutOfRange:
- return "Parameters out of range";
-- case BRepBuilderAPI_SurfaceNotC2:
-- return "Surface not C2-continous";
- default:
- return "Unknown creation error";
- }
diff --git a/graphics/FreeCAD/OpenCASCADE652.patch b/graphics/FreeCAD/OpenCASCADE652.patch new file mode 100644 index 0000000000..874392c19b --- /dev/null +++ b/graphics/FreeCAD/OpenCASCADE652.patch @@ -0,0 +1,84 @@ +--- FreeCAD-0.12.5284/src/Mod/Part/App/AppPartPy.cpp 2012-01-02 16:32:09.000000000 -0200 ++++ FreeCAD-0.12.5284_patched/src/Mod/Part/App/AppPartPy.cpp 2012-01-02 21:36:18.000000000 -0200 +@@ -492,7 +492,7 @@ + d.SetCoord(vec.x, vec.y, vec.z);
+ }
+ Handle_Geom_Plane aPlane = new Geom_Plane(p, d);
+- BRepBuilderAPI_MakeFace Face(aPlane, 0.0, length, 0.0, width);
++ BRepBuilderAPI_MakeFace Face(aPlane, 0.0, length, 0.0, width, Precision::Confusion());
+ return new TopoShapeFacePy(new TopoShape((Face.Face())));
+ }
+ catch (Standard_DomainError) {
+--- FreeCAD-0.12.5284/src/Mod/Part/App/GeometrySurfacePyImp.cpp 2012-01-02 16:32:09.000000000 -0200 ++++ FreeCAD-0.12.5284_patched/src/Mod/Part/App/GeometrySurfacePyImp.cpp 2012-01-02 22:08:47.000000000 -0200 +@@ -79,7 +79,7 @@ + s->Bounds(u1,u2,v1,v2);
+ if (!PyArg_ParseTuple(args, "|dddd", &u1,&u2,&v1,&v2))
+ return 0;
+- BRepBuilderAPI_MakeFace mkBuilder(s, u1, u2, v1, v2);
++ BRepBuilderAPI_MakeFace mkBuilder(s, u1, u2, v1, v2, Precision::Confusion());
+ TopoDS_Shape sh = mkBuilder.Shape();
+ return new TopoShapeFacePy(new TopoShape(sh));
+ }
+--- FreeCAD-0.12.5284/src/Mod/Part/App/Geometry.cpp 2012-01-02 16:32:09.000000000 -0200 ++++ FreeCAD-0.12.5284_patched/src/Mod/Part/App/Geometry.cpp 2012-01-02 22:37:08.000000000 -0200 +@@ -1252,7 +1252,7 @@ + Handle_Geom_Surface s = Handle_Geom_Surface::DownCast(handle());
+ Standard_Real u1,u2,v1,v2;
+ s->Bounds(u1,u2,v1,v2);
+- BRepBuilderAPI_MakeFace mkBuilder(s, u1, u2, v1, v2);
++ BRepBuilderAPI_MakeFace mkBuilder(s, u1, u2, v1, v2, Precision::Confusion());
+ return mkBuilder.Shape();
+ }
+
+--- FreeCAD-0.12.5284/src/Mod/Part/App/PrimitiveFeature.cpp 2012-01-02 16:32:09.000000000 -0200 ++++ FreeCAD-0.12.5284_patched/src/Mod/Part/App/PrimitiveFeature.cpp 2012-01-02 22:40:21.000000000 -0200 +@@ -191,7 +191,7 @@ + gp_Pnt pnt(0.0,0.0,0.0);
+ gp_Dir dir(0.0,0.0,1.0);
+ Handle_Geom_Plane aPlane = new Geom_Plane(pnt, dir);
+- BRepBuilderAPI_MakeFace mkFace(aPlane, 0.0, L, 0.0, W);
++ BRepBuilderAPI_MakeFace mkFace(aPlane, 0.0, L, 0.0, W, Precision::Confusion());
+
+ const char *error=0;
+ switch (mkFace.Error())
+--- FreeCAD-0.12.5284/src/Mod/Part/App/TopoShape.cpp 2012-01-02 16:32:09.000000000 -0200 ++++ FreeCAD-0.12.5284_patched/src/Mod/Part/App/TopoShape.cpp 2012-01-03 00:19:12.000000000 -0200 +@@ -1338,7 +1338,7 @@ + double u1,u2,v1,v2;
+ surf->Bounds(u1,u2,v1,v2);
+
+- BRepBuilderAPI_MakeFace mkBuilder(surf, umin, umax, v1, v2);
++ BRepBuilderAPI_MakeFace mkBuilder(surf, umin, umax, v1, v2, Precision::Confusion());
+ return mkBuilder.Face();
+ }
+
+@@ -1391,7 +1391,7 @@ +
+ Standard_Real u1,u2,v1,v2;
+ mySurface->Bounds(u1,u2,v1,v2);
+- BRepBuilderAPI_MakeFace mkBuilder(mySurface, u1, u2, v1, v2);
++ BRepBuilderAPI_MakeFace mkBuilder(mySurface, u1, u2, v1, v2, Precision::Confusion());
+ return mkBuilder.Shape();
+ }
+
+@@ -1443,7 +1443,7 @@ + mkSweep.Perform(tol, Standard_False, GeomAbs_C1, BSplCLib::MaxDegree(), 1000);
+
+ const Handle_Geom_Surface& surf = mkSweep.Surface();
+- BRepBuilderAPI_MakeFace mkBuilder(surf, umin, umax, vmin, vmax);
++ BRepBuilderAPI_MakeFace mkBuilder(surf, umin, umax, vmin, vmax, Precision::Confusion());
+ return mkBuilder.Face();
+ }
+
+--- FreeCAD-0.12.5284/src/Mod/Part/App/TopoShapeFacePyImp.cpp 2012-01-02 16:32:09.000000000 -0200 ++++ FreeCAD-0.12.5284_patched/src/Mod/Part/App/TopoShapeFacePyImp.cpp 2012-01-03 00:24:40.000000000 -0200 +@@ -135,7 +135,7 @@ + return -1;
+ }
+
+- BRepBuilderAPI_MakeFace mkFace(S);
++ BRepBuilderAPI_MakeFace mkFace(S, Precision::Confusion());
+ if (bound) {
+ Py::List list(bound);
+ for (Py::List::iterator it = list.begin(); it != list.end(); ++it) {
diff --git a/graphics/FreeCAD/README b/graphics/FreeCAD/README index e824ded5ab..15f06eea44 100644 --- a/graphics/FreeCAD/README +++ b/graphics/FreeCAD/README @@ -2,4 +2,4 @@ FreeCAD is a general purpose 3D CAD modeler, aimed at mechanical engineering and product design, but also fits in a wider range of uses around engineering, such as architecture or other engineering specialties. -FreeCAD requires xerces-c, Coin, SoQt, Pivy, and OpenCASCADE. +FreeCAD requires xerces-c, Pivy, and OpenCASCADE. |