Third Party Libraries: Difference between revisions
(These are libraries which FreeCAD uses as unmodified dependencies, that is, as dynamically linked libraries.) |
(Marked this version for translation) |
||
(60 intermediate revisions by 9 users not shown) | |||
Line 1: | Line 1: | ||
<languages/> |
<languages/> |
||
<translate> |
<translate> |
||
<!--T:72--> |
<!--T:72--> |
||
{{Docnav |
|||
{{docnav|Compiling (Speeding up)|Third Party Tools}} |
|||
|[[Compiling_(Speeding_up)|Compiling (Speeding up)]] |
|||
|[[Third_Party_Tools|Third Party Tools]] |
|||
}} |
|||
</translate> |
|||
== Overview == <!--T:1--> |
|||
{{TOCright}} |
|||
These are libraries which FreeCAD uses as unmodified dependencies, that is, as [https://en.wikipedia.org/wiki/Dynamic_loading dynamically linked libraries]; they are files with an extension {{incode|.so}} in Linux/MacOS and {{incode|.dll}} in Windows. If a modified library is necessary, or a wrapper class is needed, the code of the modified library, or the wrapper, has to become part of the FreeCAD source code, and compiled together with it. |
|||
<translate> |
|||
== Overview == <!--T:117--> |
|||
<!--T:1--> |
|||
These are libraries which FreeCAD uses as third party dependencies during compilation. They are usually [https://en.wikipedia.org/wiki/Dynamic_loading dynamically linked libraries] and have an extension {{incode|.so}} in Linux/MacOS and {{incode|.dll}} in Windows, and are accompanied by their header files {{incode|.h}} or {{incode|.hpp}} or similar. If a modified library is necessary, or a wrapper class is needed, the code of the modified library, or the wrapper, has to become part of the FreeCAD source code, and compiled together with it. |
|||
<!--T:78--> |
|||
The dependencies need to be installed in the system before proceeding with compilation; see [[Compile_on_Linux|compile on Linux]], [[Compile_on_Windows|compile on Windows]], and [[Compile_on_MacOS|compile on MacOS]] for more information. |
|||
<!--T:2--> |
<!--T:2--> |
||
If you are using Windows, consider using the [[#LibPack|LibPack]] instead of trying to install the |
If you are compiling using Windows, consider using the [[#LibPack|LibPack]] instead of trying to install the libraries individually. |
||
== Links == <!--T:3--> |
== Links == <!--T:3--> |
||
Line 15: | Line 28: | ||
{| class="wikitable" style="text-align:left" |
{| class="wikitable" style="text-align:left" |
||
|- |
|- |
||
! Library name !! Version needed !! Link to get it |
! Library name !! Version needed !! Link to get it |
||
|- |
|||
|- |
|||
| Python || >= |
| Python || >= 3.6 || http://www.python.org/ |
||
|- |
|||
|- |
|||
| |
| Boost || >= 1.33 || http://www.boost.org/ |
||
|- |
|||
|- |
|||
| |
| OpenCASCADE || >= 7.3 || http://www.opencascade.org |
||
|- |
|||
|- |
|||
| |
| Qt || >= 5.4 || https://www.qt.io/ |
||
|- |
|||
|- |
|||
| |
| Shiboken2 || {{Emphasis|same as Qt}} || https://wiki.qt.io/Qt_for_Python/Shiboken |
||
|- |
|||
| PySide2 || {{Emphasis|same as Qt}} || https://wiki.qt.io/Qt_for_Python/Shiboken |
|||
|- |
|||
| Coin3D || >= 3.x || https://github.com/coin3d/coin |
|||
|- |
|||
| SoQt (deprecated) || >= 1.2 || https://github.com/coin3d/soqt |
|||
|- |
|||
| Quarter || >= 1.0 || https://github.com/coin3d/quarter |
|||
|- |
|||
| Pivy || >= 0.6.5 || https://github.com/coin3d/pivy/ |
|||
|- |
|||
| FreeType || >= XXX || XXX |
|||
|- |
|||
| PyCXX || >= XXX || XXX |
|||
|- |
|||
| KDL || >= XXX || https://orocos.org/wiki/orocos/kdl-wiki.html |
|||
|- |
|||
| Point Cloud Library || >= XXX || XXX |
|||
|- |
|||
| Salome SMESH || >= XXX || XXX |
|||
|- |
|||
| VTK || >= 6.0 || XXX |
|||
|- |
|||
| Ply || >= 3.11 || https://www.dabeaz.com/ply/ |
|||
|- |
|||
| Xerces-C++ || >= 3.0 || https://xerces.apache.org/xerces-c/ |
|||
|- |
|||
| Eigen3 || >= 3.0 || http://eigen.tuxfamily.org/index.php?title=Main_Page |
|||
|- |
|||
| Zipios++ || >= 0.1.5 || https://snapwebsites.org/project/zipios, https://github.com/Zipios/Zipios |
|||
|- |
|- |
||
| |
| Zlib || >= 1.0 || http://www.zlib.net/, https://github.com/madler/zlib |
||
|- |
|||
| Xerces-C++ || >= 2.7.x < 3.0 || http://xml.apache.org/xerces-c/ |
|||
|- |
|||
| Zlib || >= 1.x.x || http://www.zlib.net/ |
|||
|- |
|||
| Boost || >= 1.33.x || http://www.boost.org/ |
|||
|- |
|||
| Eigen3 || >= 3.0.1 || http://eigen.tuxfamily.org/index.php?title=Main_Page |
|||
|- |
|||
| Shiboken || >= 1.1.2 || http://shiboken.readthedocs.org/en/latest/ |
|||
|- |
|- |
||
| libarea || |
| libarea || >= 0.0.20140514-1 || https://github.com/danielfalck/libarea |
||
|- |
|- |
||
|} |
|} |
||
Line 45: | Line 78: | ||
== Details == <!--T:5--> |
== Details == <!--T:5--> |
||
=== Python === <!--T: |
=== Python === <!--T:118--> |
||
<!--T:6--> |
|||
'''Version:''' 3.3 or higher |
'''Version:''' 3.3 or higher |
||
<!--T:7--> |
<!--T:7--> |
||
'''License:''' Python 3.3 license |
'''License:''' Python 3.3 license |
||
<!--T:74--> |
|||
{{VeryImportantMessage|Python 2 became obsolete in 2019. Further development of FreeCAD will use exclusively Python 3; compatibility with Python 2 won't be tested, so old workbenches and macros that use this version will have to be updated or they may stop working. Please post on the [https://forum.freecadweb.org/ FreeCAD forum] if you encounter problems with Python 3.}} |
|||
<!--T:79--> |
|||
Python is a popular all-purpose scripting language that is widely used in Linux and open source software. In FreeCAD, Python is used during compilation and also at runtime in different ways. It is used |
|||
* to write test scripts to test for different conditions, such as memory leaks, to ensure functionality of the software after changes, for post build checks, and test coverage tests, |
|||
* to write [[macros|macros]] and macro recording, |
|||
* to implement application logic for standard packages, |
|||
* to implement auxiliary tools such as the [[Std_AddonMgr|Addon Manager]], |
|||
* to implement entire workbenches like [[Draft Workbench|Draft]] and [[Arch Workbench|Arch]], |
|||
* to dynamically load packages, |
|||
* to implement rules for design (knowledge engineering), |
|||
* to do fancy Internet interactions like work groups and PDM |
|||
<!--T:8--> |
<!--T:8--> |
||
On Linux, Python is usually already installed in your distribution. For Windows you can |
On Linux, Python is usually already installed in your distribution. For Windows you can get a precompiled binary from [http://www.python.org/ Python.org] or use [http://www.activestate.com/ ActiveState Python], though it is harder to get the debug libraries from the latter one. |
||
<!--T: |
<!--T:80--> |
||
Python was chosen as the scripting language for FreeCAD for different reasons: |
|||
Python 2 became obsolete in 2019. Further development of FreeCAD will use exclusively Python 3; compatibility with Python 2 won't be explicitly added, so old workbenches and macros that use that version will have to be migrated or they may stop working. |
|||
* It is more object oriented than Perl and Tcl. |
|||
* The code is more readable than Perl and Visual Basic. |
|||
* It is easier to embed in another application, unlike, say, Java. |
|||
<!--T:81--> |
|||
In summary, Python is well documented, and it's easy to embed and extend in a C++ application. It is also well tested and has strong support from the open source community. Read more about Python and browse the official documentation at [http://www.python.org Python.org]. |
|||
Python is the primary scripting language and is used throughout the application. |
|||
For example: |
|||
* Implement test scripts for testing on: |
|||
** memory leaks |
|||
** ensure presents of functionality after changes |
|||
** post build checks |
|||
** test coverage tests |
|||
* Macros and macro recording |
|||
* Implement application logic for standard packages |
|||
* Implementation of whole workbenches |
|||
* Dynamic loading of packages |
|||
* Implementing rules for design (knowledge engineering) |
|||
* Doing some fancy Internet stuff like work groups and PDM |
|||
<!--T: |
=== Boost === <!--T:55--> |
||
Especially the dynamic package loading of Python is used to load at run time additional functionality and workbenches needed for the actual tasks. For a closer look to Python see: www.python.org Why Python you may ask. There are some reasons: So far I used different scripting languages in my professional life: |
|||
* Perl |
|||
* Tcl/Tk |
|||
* VB |
|||
* Java |
|||
Python is more OO then Perl and Tcl, the code is not a mess like in Perl and VB. Java isn't a script language in the first place and hard (or impossible) to embed. Python is well documented and easy to embed and extend. It is also well tested and has a strong back hold in the open source community. |
|||
<!--T:56--> |
|||
'''Version:''' 1.33 or higher |
|||
Goes to Guido van Rossum and a lot of people made Python such a success! |
|||
<!--T:57--> |
|||
'''License:''' Boost Software License - Version 1.0 |
|||
<!--T:58--> |
|||
The Boost C++ libraries are collections of peer-reviewed, open source libraries that extend the functionality of C++. They are intended to be widely useful across a broad spectrum of applications, and to work well with the C++ Standard Library. The Boost license is designed to encourage their use in both open source and closed source projects. |
|||
<!--T:82--> |
|||
Due to their popularity and stability, many Boost libraries have been accepted for incorporation into the C++11 standard, and more are planned for inclusion in subsequent C++ standards. |
|||
<!--T:60--> |
|||
In order to ensure efficiency and flexibility, Boost makes extensive use of templates. Boost has been a source of extensive work and research into generic programming and meta-programming in C++. Read more about Boost by visiting the [http://www.boost.org/ Boost homepage]. |
|||
=== OpenCASCADE Technology === <!--T:12--> |
=== OpenCASCADE Technology === <!--T:12--> |
||
<!--T:13--> |
<!--T:13--> |
||
'''Version:''' |
'''Version:''' 6.7 or higher |
||
<!--T:14--> |
<!--T:14--> |
||
'''License:''' |
'''License:''' version 6.7.0 and later are governed by the [https://www.opencascade.com/content/licensing GNU Lesser General Public License (LGPL) version 2.1 with additional exception]. Earlier versions use the [https://www.opencascade.com/content/occt-public-license Open CASCADE Technology Public License]. |
||
<!--T:15--> |
<!--T:15--> |
||
OpenCASCADE Technology (OCCT) is a full-featured, professional grade CAD kernel. It was developed in 1993 and originally called CAS.CADE, by Matra Datavision in France for the Strim (Styler) and Euclid Quantum applications. In 1999 it was released as open source software, and since then it's been called OpenCASCADE. |
|||
* A complete STEP compliant geometry kernel |
|||
<!--T:83--> |
|||
* A topological data model and all needed functions to work on (cut, fuse, extrude, and so on. . . ) |
|||
OCCT is a big and complex set of C++ libraries that provide functionality required by a CAD application: |
|||
* Standard Import- / Export processors like STEP, IGES, VRML |
|||
* A complete STEP compliant geometry kernel. |
|||
* 3D and 2D viewer with selection support |
|||
* A topological data model and needed functions to work with shapes (cut, fuse, extrude, and many others). |
|||
* A document and project data structure with support for save and restore, external linking of documents, recalculation of design history (parametric modeling) and a facility to load new data types as an extension package dynamically |
|||
* Standard import and export processors for files like STEP, IGES, VRML. |
|||
* A 2D and 3D viewer with selection support. |
|||
* A document and project data structure with support for save and restore, external linking of documents, recalculation of design history (parametric modeling) and a facility to load new data types as an extension package dynamically. |
|||
<!--T:84--> |
|||
There are two main versions of OpenCASCADE in existence in different Linux distributions. One is distributed by the original developers; it is known as OCCT, and is packaged under the names {{incode|occ}} or {{incode|occt}}. The other version is the "community edition", abbreviated OCE, and is normally found with the {{incode|oce}} name. FreeCAD can compile against either version, however, since 2016 FreeCAD recommends compiling against the official OCCT libraries rather than the OCE ones. The reason is that the community edition lacks important bug fixes and functions that make using FreeCAD better. |
|||
<!--T:16--> |
<!--T:16--> |
||
To learn more |
To learn more visit the [http://www.opencascade.org OpenCASCADE website]. |
||
=== Qt === <!--T:17--> |
=== Qt === <!--T:17--> |
||
<!--T:18--> |
<!--T:18--> |
||
'''Version:''' 4.1 |
'''Version:''' 4.1 or higher |
||
<!--T:19--> |
<!--T:19--> |
||
'''License:''' GPL v2.0/v3.0 or Commercial |
'''License:''' GPL v2.0/v3.0 or Commercial; from version 4.5 on also LPGL v2.1. |
||
<!--T:20--> |
<!--T:20--> |
||
Qt is one of the most popular graphical user interface (GUI) toolkits available in the open source world. FreeCAD uses this toolkit to draw the interface of the program. For this, the Qt Designer application is very useful as it allows developers to quickly draw the dialogs and windows, export them as XML resource files, and then load these interfaces at runtime. |
|||
I don't think I need to tell a lot about Qt. It's one of the most often used GUI toolkits in Open Source projects. For me the most important point to use Qt is the Qt Designer and the possibility to load whole dialog boxes as a (XML) resource and incorporate specialized widgets. In a CAX application the user interaction and dialog boxes are by far the biggest part of the code and a good dialog designer is very important to easily extend FreeCAD with new functionality. Further information and a very good online documentation you'll find on http://www.qtsoftware.com. |
|||
<!--T:85--> |
|||
Further information about Qt libraries and their programming documentation are available at [https://doc.qt.io/?hsCtaTracking=f641fd1a-772b-4957-964b-dad954b8d702%7C46c97dac-f1f6-49b3-ae46-8070fc35ea13 Qt Documentation]. |
|||
'''Shiboken''' (''Shi bō ken'', 死某剣) is the Python binding generator that Qt for Python uses to create the PySide module, in other words, is the system we use to expose the Qt C++ API to Python. |
|||
==== Shiboken2 and Pyside2 ==== <!--T:119--> |
|||
<!--T:70--> |
|||
Shiboken is the Python binding generator that Qt for Python uses to create the PySide module, in other words, it is the system that is used to expose the Qt C++ API to the Python language. |
|||
<!--T:71--> |
<!--T:71--> |
||
The original Shiboken and PySide packages were meant to be used with Python 2 and Qt4; since these two versions are considered obsolete in 2019, please use Shiboken2 and PySide2, which work with Python 3 and Qt5. New development of FreeCAD is done with Python 3 and Qt5, so compatibility with Python 2 and Qt4 is not guaranteed after FreeCAD 0.18. |
|||
The name '''Shiboken2''' and '''PySide2''' make reference to the Qt 5 compatibility, since the previous versions (without the '''2''') refer to Qt 4. Read more about Shiboken and Pyside on [https://wiki.qt.io/Qt_for_Python/Shiboken Qt for Python wiki page] |
|||
<!--T:86--> |
|||
Read more about Shiboken and Pyside on [https://wiki.qt.io/Qt_for_Python/Shiboken Qt for Python]. |
|||
=== Coin3D === <!--T:21--> |
=== Coin3D === <!--T:21--> |
||
<!--T:22--> |
<!--T:22--> |
||
'''Version:''' |
'''Version:''' 3.0 or higher |
||
<!--T:23--> |
<!--T:23--> |
||
'''License:''' |
'''License:''' BSD 3-clause license |
||
<!--T:24--> |
<!--T:24--> |
||
Coin3D is a high-level 3D graphics library with a C++ application programming interface. It uses scenegraph data structures to render real-time graphics suitable for all kinds of scientific and engineering visualization applications. |
|||
<!--T:25--> |
|||
Coin is portable over a wide range of platforms: UNIX, Linux, BSD, MacOS X, and Microsoft Windows operating system. |
|||
<!--T:26--> |
<!--T:26--> |
||
Coin3D is built on the industry-standard OpenGL immediate mode rendering library, and adds abstractions for higher-level primitives, provides 3D interactivity, and contains many complex optimization features for fast rendering that are transparent for the application programmer. |
|||
<!--T:27--> |
<!--T:27--> |
||
Coin3D is compatible with SGI's Open Inventor 2.1 API. This API has become the de facto standard graphics interface for 3D visualization in the scientific and engineering community. It has proved its worth since the year 2000 as a major building block in thousands of engineering applications around the world. |
|||
<!--T:28--> |
<!--T:28--> |
||
Coin3D (Open Inventor) is used as the 3D viewer in FreeCAD because the OpenCASCADE viewer (AIS and Graphics3D) has limitations and performance bottlenecks, especially with large-scale engineering rendering; other things like textures or volumetric rendering are not entirely supported by the OpenCASCADE viewer. |
|||
<!--T: |
<!--T:25--> |
||
Coin3D is portable over a wide range of platforms: UNIX, Linux, BSD, macOS, and Microsoft Windows operating systems. To read more about this library visit [https://github.com/coin3d/coin Coin3D homepage]. |
|||
Since 2011, Coin has been licenced under the OSI approved 3-clause BSD licence. |
|||
=== SoQt (deprecated) === <!--T:35--> |
==== SoQt (deprecated) ==== <!--T:35--> |
||
<!--T:36--> |
<!--T:36--> |
||
Line 151: | Line 208: | ||
<!--T:37--> |
<!--T:37--> |
||
'''License:''' |
'''License:''' BSD 3-clause license |
||
<!--T:38--> |
<!--T:38--> |
||
SoQt is the Coin3D (Open Inventor) binding to the Qt GUI toolkit. |
|||
SoQt is the Inventor binding to the Qt Gui Toolkit. Unfortunately, it's not longer LGPL so we have to remove it from the code base of FreeCAD and link it as a library. It has the same licence model like Coin. And you have to compile it with your version of Qt. |
|||
<!--T:75--> |
<!--T:75--> |
||
SoQt is no longer used in FreeCAD, it was replaced by Quarter which is a more recent binding. |
SoQt is no longer used in FreeCAD, it was replaced by Quarter which is a more recent Qt binding. |
||
=== Quarter === <!--T: |
==== Quarter ==== <!--T:120--> |
||
<!--T:76--> |
|||
'''Version:''' 1.0 or higher |
'''Version:''' 1.0 or higher |
||
<!--T:87--> |
|||
'''License:''' BSD 3-clause license |
|||
<!--T:77--> |
<!--T:77--> |
||
Quarter is a |
Quarter is a newer Coin3D binding to the Qt toolkit. A version of it is included in the source code of FreeCAD so it is compiled together with it. |
||
==== Pivy ==== <!--T:107--> |
|||
<!--T:108--> |
|||
'''Version:''' 0.6.3 or higher |
|||
<!--T:109--> |
|||
'''License:''' BSD 3-clause license |
|||
<!--T:110--> |
|||
[[Pivy|Pivy]] is a library that wraps the Coin3d library for use in [[Python|Python]]. It is not needed to build FreeCAD or to start it, but it is needed as a runtime dependency by the [[Draft_Workbench|Draft Workbench]], and by other workbenches that use it internally, like [[Arch_Workbench|Arch]] and [[BIM_Workbench|BIM]]. |
|||
<!--T:111--> |
|||
If you are not going to use these workbenches, you won't need Pivy. |
|||
=== Ply === <!--T:112--> |
|||
<!--T:113--> |
|||
'''Version:''' 3.11 or higher |
|||
<!--T:114--> |
|||
'''License:''' BSD 3-clause license |
|||
<!--T:115--> |
|||
Ply is the Python-Lex-Yacc parser. It is used as a runtime dependency by the [[OpenSCAD Workbench|OpenSCAD Workbench]]. If you don't use this workbench, you may not need this package. |
|||
<!--T:116--> |
|||
For more information see [https://www.dabeaz.com/ply/ Ply homepage] |
|||
=== Xerces-C++ === <!--T:39--> |
=== Xerces-C++ === <!--T:39--> |
||
<!--T:40--> |
<!--T:40--> |
||
'''Version:''' |
'''Version:''' 3.0 or higher |
||
<!--T:41--> |
<!--T:41--> |
||
Line 174: | Line 264: | ||
<!--T:42--> |
<!--T:42--> |
||
Xerces-C++ is a validating XML parser written in a portable subset of C++. Xerces-C++ makes it easy to give your application the ability to read and write XML data. A shared library is provided for parsing, generating, manipulating, and validating XML documents. |
Xerces-C++ is a validating XML parser written in a portable subset of C++. Xerces-C++ makes it easy to give your application the ability to read and write XML data. A shared library is provided for parsing, generating, manipulating, and validating XML documents. Xerces-C++ is faithful to the XML 1.0 recommendation and associated standards. |
||
<!--T: |
<!--T:45--> |
||
The parser is used for saving and restoring parameters in FreeCAD. For more information see [https://xerces.apache.org/xerces-c/ Xerces-C++ homepage]. |
|||
Xerces-C++ is faithful to the XML 1.0 recommendation and many associated standards (see Features below). |
|||
<!--T: |
=== Eigen3 === <!--T:88--> |
||
The parser provides high performance, modularity, and scalability. Source code, samples and API documentation are provided with the parser. For portability, care has been taken to make minimal use of templates, no RTTI, and minimal use of #ifdefs. |
|||
<!--T: |
<!--T:89--> |
||
'''Version:''' 3.0 or higher |
|||
The parser is used for saving and restoring parameters in FreeCAD. |
|||
<!--T:90--> |
|||
'''License:''' Starting from the 3.1.1 version, it is licensed under the [http://www.mozilla.org/MPL/2.0 Mozilla Public License 2.0]. Earlier versions were licensed under the [https://www.gnu.org/licenses/lgpl-3.0.en.html GNU Lesser General Public License 3]. |
|||
<!--T: |
<!--T:91--> |
||
Eigen is a C++ template library for linear algebra: matrices, vectors, numerical solvers, and related algorithms. |
|||
'''Version:''' 1.x.x |
|||
<!--T: |
<!--T:92--> |
||
If you just want to use Eigen, you can use the header files right away. There is no binary library to link to, and no configured header file. Eigen is a pure template library defined in the headers. |
|||
'''License:''' zlib License |
|||
<!--T: |
<!--T:93--> |
||
Eigen is used in FreeCAD for many vector operations in 3D space. To learn more, visit [http://eigen.tuxfamily.org/index.php?title=Main_Page Eigen homepage]. |
|||
zlib is designed to be a free, general-purpose, legally unencumbered -- that is, not covered by any patents -- lossless data-compression library for use on virtually any computer hardware and operating system. The zlib data format is itself portable across platforms. Unlike the LZW compression method used in Unix compress(1) and in the GIF image format, the compression method currently used in zlib essentially never expands the data. (LZW can double or triple the file size in extreme cases.) zlib's memory footprint is also independent of the input data and can be reduced, if necessary, at some cost in compression. |
|||
=== |
=== Zipios++ === <!--T:94--> |
||
<!--T: |
<!--T:95--> |
||
'''Version:''' |
'''Version:''' 0.1.5 or higher |
||
<!--T: |
<!--T:96--> |
||
'''License:''' |
'''License:''' GNU Lesser General Public License 2.1 |
||
<!--T: |
<!--T:97--> |
||
Zipios++ is a C++ library for reading and writing {{incode|.zip}} files. Access to individual entries is provided through standard C++ iostreams. A simple read-only virtual file system that mounts regular directories and {{incode|.zip}} files is also provided. The structure and public interface of Zipios++ are loosely based on the {{incode|java.util.zip}} package of Java. |
|||
The Boost C++ libraries are a collection of peer-reviewed, open source libraries that extend the functionality of C++. The libraries are licensed under the Boost Software License, designed to allow Boost to be used with both open and closed source projects. Many of Boost's founders are on the C++ standard committee and several Boost libraries have been accepted for incorporation into the Technical Report 1 of C++0x. |
|||
<!--T: |
<!--T:98--> |
||
FreeCAD's native file format {{incode|.FCstd}} is in reality a {{incode|.zip}} file that stores and compresses other types of data within it, such as BREP and XML files. Therefore, Zipios++ is used to save and open compressed archives, including FreeCAD files. |
|||
The libraries are aimed at a wide range of C++ users and application domains. They range from general-purpose libraries like SmartPtr, to OS Abstractions like FileSystem, to libraries primarily aimed at other library developers and advanced C++ users, like MPL. |
|||
<!--T: |
<!--T:99--> |
||
A copy of Zipios++ is included in the source code of FreeCAD so it is compiled together with it. If you want to use an external Zipios++ library, provided by your operating system, you may set <code>-DFREECAD_USE_EXTERNAL_ZIPIOS=ON</code> with {{incode|cmake}}. |
|||
In order to ensure efficiency and flexibility, Boost makes extensive use of templates. Boost has been a source of extensive work and research into generic programming and meta-programming in C++. |
|||
<!--T: |
<!--T:100--> |
||
Zipios++ uses the Zlib library to perform the actual decompression of files. |
|||
See: http://www.boost.org/ for details. |
|||
==== Zlib ==== <!--T:51--> |
|||
<!--T:52--> |
|||
'''Version:''' 1.0 or higher |
|||
<!--T:53--> |
|||
'''License:''' zlib license |
|||
<!--T:54--> |
|||
Zlib is designed to be a free, general-purpose, lossless data-compression library for use on any computer hardware and operating system. It implements the {{incode|DEFLATE}} compression algorithm commonly used in {{incode|.zip}} and {{incode|.gzip}} files. |
|||
<!--T:101--> |
|||
A copy of this library is included in the source code of FreeCAD so it is compiled together with it. |
|||
=== libarea === <!--T:66--> |
=== libarea === <!--T:66--> |
||
<!--T:67--> |
<!--T:67--> |
||
'''Version:''' |
'''Version:''' 0.0.20140514-1 or higher |
||
<!--T:68--> |
<!--T:68--> |
||
'''License:''' |
'''License:''' BSD 3-clause license |
||
<!--T:69--> |
<!--T:69--> |
||
Libarea is a software library to compute profile and pocket operations which are used in computer aided manufacturing (CAM) software. It was created by Dan Heeks for his HeeksCNC project. |
|||
Area is a piece of software created by Dan Heeks for HeeksCNC. It is employed as a library for generation of CAM related operations in the Path Workbench. |
|||
<!--T:102--> |
|||
A copy of the library is included with the source code of the [[CAM_Workbench|CAM Workbench]], so it is compiled together with it. |
|||
LibPack is a convenient package with all the above libraries packed together. It is only needed if you are building on the Windows Platform and you can find it at https://github.com/FreeCAD/FreeCAD-ports-cache/releases. If you're working under Linux you have to use the package repositories of your Linux distribution, i.e. no libPack needed and offered for Linux. |
|||
== LibPack == <!--T:121--> |
|||
* Using QT 4.5.x and Coin 3.1.x |
|||
* Eigen template lib for Robot added |
|||
* SMESH experimental |
|||
<!--T:62--> |
|||
LibPack is a convenient package with FreeCAD's build dependencies collected together. It is only needed if you are compiling FreeCAD on Windows with Visual Studio 2015 and above. You can find the latest LibPack on the [https://github.com/FreeCAD/FreeCAD/releases releases page]. |
|||
<!--T: |
<!--T:103--> |
||
If you're working under Linux, you don't need the LibPack, as you can get the dependencies from your distribution's repositories as mentioned in the [[Compile_on_Linux|compile on Linux]] page. |
|||
{{docnav|Compiling (Speeding up)|Third Party Tools}} |
|||
<!--T: |
=== FreeCAD 12.1.2 === <!--T:104--> |
||
{{Userdocnavi}} |
|||
<!--T: |
<!--T:105--> |
||
See the announcement in the forum: [https://forum.freecadweb.org/viewtopic.php?f=4&t=35789 New libpacks for Windows with Qt5.12, OCC7.3 and Python 3.6 by apeltauer] |
|||
[[Category:Developer Documentation]] |
|||
<!--T:106--> |
|||
It includes among other things: Boost 1.67, Coin3D 4.0.0a, Eigen3, Open CASCADE Technology 7.3.0, Python 3.6.8, PySide2, Qt 5.12.1, Salome SMESH, Shiboken2, vtk7, Xerces-C, Zipios++, zlib 1.2.11 |
|||
<!--T:64--> |
|||
{{Docnav |
|||
|[[Compiling_(Speeding_up)|Compiling (Speeding up)]] |
|||
|[[Third_Party_Tools|Third Party Tools]] |
|||
}} |
|||
</translate> |
</translate> |
||
{{Userdocnavi{{#translation:}}}} |
|||
[[Category:Developer Documentation{{#translation:}}]] |
|||
{{clear}} |
{{clear}} |
Latest revision as of 16:49, 18 April 2024
Overview
These are libraries which FreeCAD uses as third party dependencies during compilation. They are usually dynamically linked libraries and have an extension .so
in Linux/MacOS and .dll
in Windows, and are accompanied by their header files .h
or .hpp
or similar. If a modified library is necessary, or a wrapper class is needed, the code of the modified library, or the wrapper, has to become part of the FreeCAD source code, and compiled together with it.
The dependencies need to be installed in the system before proceeding with compilation; see compile on Linux, compile on Windows, and compile on MacOS for more information.
If you are compiling using Windows, consider using the LibPack instead of trying to install the libraries individually.
Links
Details
Python
Version: 3.3 or higher
License: Python 3.3 license
Python is a popular all-purpose scripting language that is widely used in Linux and open source software. In FreeCAD, Python is used during compilation and also at runtime in different ways. It is used
- to write test scripts to test for different conditions, such as memory leaks, to ensure functionality of the software after changes, for post build checks, and test coverage tests,
- to write macros and macro recording,
- to implement application logic for standard packages,
- to implement auxiliary tools such as the Addon Manager,
- to implement entire workbenches like Draft and Arch,
- to dynamically load packages,
- to implement rules for design (knowledge engineering),
- to do fancy Internet interactions like work groups and PDM
On Linux, Python is usually already installed in your distribution. For Windows you can get a precompiled binary from Python.org or use ActiveState Python, though it is harder to get the debug libraries from the latter one.
Python was chosen as the scripting language for FreeCAD for different reasons:
- It is more object oriented than Perl and Tcl.
- The code is more readable than Perl and Visual Basic.
- It is easier to embed in another application, unlike, say, Java.
In summary, Python is well documented, and it's easy to embed and extend in a C++ application. It is also well tested and has strong support from the open source community. Read more about Python and browse the official documentation at Python.org.
Boost
Version: 1.33 or higher
License: Boost Software License - Version 1.0
The Boost C++ libraries are collections of peer-reviewed, open source libraries that extend the functionality of C++. They are intended to be widely useful across a broad spectrum of applications, and to work well with the C++ Standard Library. The Boost license is designed to encourage their use in both open source and closed source projects.
Due to their popularity and stability, many Boost libraries have been accepted for incorporation into the C++11 standard, and more are planned for inclusion in subsequent C++ standards.
In order to ensure efficiency and flexibility, Boost makes extensive use of templates. Boost has been a source of extensive work and research into generic programming and meta-programming in C++. Read more about Boost by visiting the Boost homepage.
OpenCASCADE Technology
Version: 6.7 or higher
License: version 6.7.0 and later are governed by the GNU Lesser General Public License (LGPL) version 2.1 with additional exception. Earlier versions use the Open CASCADE Technology Public License.
OpenCASCADE Technology (OCCT) is a full-featured, professional grade CAD kernel. It was developed in 1993 and originally called CAS.CADE, by Matra Datavision in France for the Strim (Styler) and Euclid Quantum applications. In 1999 it was released as open source software, and since then it's been called OpenCASCADE.
OCCT is a big and complex set of C++ libraries that provide functionality required by a CAD application:
- A complete STEP compliant geometry kernel.
- A topological data model and needed functions to work with shapes (cut, fuse, extrude, and many others).
- Standard import and export processors for files like STEP, IGES, VRML.
- A 2D and 3D viewer with selection support.
- A document and project data structure with support for save and restore, external linking of documents, recalculation of design history (parametric modeling) and a facility to load new data types as an extension package dynamically.
There are two main versions of OpenCASCADE in existence in different Linux distributions. One is distributed by the original developers; it is known as OCCT, and is packaged under the names occ
or occt
. The other version is the "community edition", abbreviated OCE, and is normally found with the oce
name. FreeCAD can compile against either version, however, since 2016 FreeCAD recommends compiling against the official OCCT libraries rather than the OCE ones. The reason is that the community edition lacks important bug fixes and functions that make using FreeCAD better.
To learn more visit the OpenCASCADE website.
Qt
Version: 4.1 or higher
License: GPL v2.0/v3.0 or Commercial; from version 4.5 on also LPGL v2.1.
Qt is one of the most popular graphical user interface (GUI) toolkits available in the open source world. FreeCAD uses this toolkit to draw the interface of the program. For this, the Qt Designer application is very useful as it allows developers to quickly draw the dialogs and windows, export them as XML resource files, and then load these interfaces at runtime.
Further information about Qt libraries and their programming documentation are available at Qt Documentation.
Shiboken2 and Pyside2
Shiboken is the Python binding generator that Qt for Python uses to create the PySide module, in other words, it is the system that is used to expose the Qt C++ API to the Python language.
The original Shiboken and PySide packages were meant to be used with Python 2 and Qt4; since these two versions are considered obsolete in 2019, please use Shiboken2 and PySide2, which work with Python 3 and Qt5. New development of FreeCAD is done with Python 3 and Qt5, so compatibility with Python 2 and Qt4 is not guaranteed after FreeCAD 0.18.
Read more about Shiboken and Pyside on Qt for Python.
Coin3D
Version: 3.0 or higher
License: BSD 3-clause license
Coin3D is a high-level 3D graphics library with a C++ application programming interface. It uses scenegraph data structures to render real-time graphics suitable for all kinds of scientific and engineering visualization applications.
Coin3D is built on the industry-standard OpenGL immediate mode rendering library, and adds abstractions for higher-level primitives, provides 3D interactivity, and contains many complex optimization features for fast rendering that are transparent for the application programmer.
Coin3D is compatible with SGI's Open Inventor 2.1 API. This API has become the de facto standard graphics interface for 3D visualization in the scientific and engineering community. It has proved its worth since the year 2000 as a major building block in thousands of engineering applications around the world.
Coin3D (Open Inventor) is used as the 3D viewer in FreeCAD because the OpenCASCADE viewer (AIS and Graphics3D) has limitations and performance bottlenecks, especially with large-scale engineering rendering; other things like textures or volumetric rendering are not entirely supported by the OpenCASCADE viewer.
Coin3D is portable over a wide range of platforms: UNIX, Linux, BSD, macOS, and Microsoft Windows operating systems. To read more about this library visit Coin3D homepage.
SoQt (deprecated)
Version: 1.2.0 or higher
License: BSD 3-clause license
SoQt is the Coin3D (Open Inventor) binding to the Qt GUI toolkit.
SoQt is no longer used in FreeCAD, it was replaced by Quarter which is a more recent Qt binding.
Quarter
Version: 1.0 or higher
License: BSD 3-clause license
Quarter is a newer Coin3D binding to the Qt toolkit. A version of it is included in the source code of FreeCAD so it is compiled together with it.
Pivy
Version: 0.6.3 or higher
License: BSD 3-clause license
Pivy is a library that wraps the Coin3d library for use in Python. It is not needed to build FreeCAD or to start it, but it is needed as a runtime dependency by the Draft Workbench, and by other workbenches that use it internally, like Arch and BIM.
If you are not going to use these workbenches, you won't need Pivy.
Ply
Version: 3.11 or higher
License: BSD 3-clause license
Ply is the Python-Lex-Yacc parser. It is used as a runtime dependency by the OpenSCAD Workbench. If you don't use this workbench, you may not need this package.
For more information see Ply homepage
Xerces-C++
Version: 3.0 or higher
License: Apache Software License Version 2.0
Xerces-C++ is a validating XML parser written in a portable subset of C++. Xerces-C++ makes it easy to give your application the ability to read and write XML data. A shared library is provided for parsing, generating, manipulating, and validating XML documents. Xerces-C++ is faithful to the XML 1.0 recommendation and associated standards.
The parser is used for saving and restoring parameters in FreeCAD. For more information see Xerces-C++ homepage.
Eigen3
Version: 3.0 or higher
License: Starting from the 3.1.1 version, it is licensed under the Mozilla Public License 2.0. Earlier versions were licensed under the GNU Lesser General Public License 3.
Eigen is a C++ template library for linear algebra: matrices, vectors, numerical solvers, and related algorithms.
If you just want to use Eigen, you can use the header files right away. There is no binary library to link to, and no configured header file. Eigen is a pure template library defined in the headers.
Eigen is used in FreeCAD for many vector operations in 3D space. To learn more, visit Eigen homepage.
Zipios++
Version: 0.1.5 or higher
License: GNU Lesser General Public License 2.1
Zipios++ is a C++ library for reading and writing .zip
files. Access to individual entries is provided through standard C++ iostreams. A simple read-only virtual file system that mounts regular directories and .zip
files is also provided. The structure and public interface of Zipios++ are loosely based on the java.util.zip
package of Java.
FreeCAD's native file format .FCstd
is in reality a .zip
file that stores and compresses other types of data within it, such as BREP and XML files. Therefore, Zipios++ is used to save and open compressed archives, including FreeCAD files.
A copy of Zipios++ is included in the source code of FreeCAD so it is compiled together with it. If you want to use an external Zipios++ library, provided by your operating system, you may set -DFREECAD_USE_EXTERNAL_ZIPIOS=ON
with cmake
.
Zipios++ uses the Zlib library to perform the actual decompression of files.
Zlib
Version: 1.0 or higher
License: zlib license
Zlib is designed to be a free, general-purpose, lossless data-compression library for use on any computer hardware and operating system. It implements the DEFLATE
compression algorithm commonly used in .zip
and .gzip
files.
A copy of this library is included in the source code of FreeCAD so it is compiled together with it.
libarea
Version: 0.0.20140514-1 or higher
License: BSD 3-clause license
Libarea is a software library to compute profile and pocket operations which are used in computer aided manufacturing (CAM) software. It was created by Dan Heeks for his HeeksCNC project.
A copy of the library is included with the source code of the CAM Workbench, so it is compiled together with it.
LibPack
LibPack is a convenient package with FreeCAD's build dependencies collected together. It is only needed if you are compiling FreeCAD on Windows with Visual Studio 2015 and above. You can find the latest LibPack on the releases page.
If you're working under Linux, you don't need the LibPack, as you can get the dependencies from your distribution's repositories as mentioned in the compile on Linux page.
FreeCAD 12.1.2
See the announcement in the forum: New libpacks for Windows with Qt5.12, OCC7.3 and Python 3.6 by apeltauer
It includes among other things: Boost 1.67, Coin3D 4.0.0a, Eigen3, Open CASCADE Technology 7.3.0, Python 3.6.8, PySide2, Qt 5.12.1, Salome SMESH, Shiboken2, vtk7, Xerces-C, Zipios++, zlib 1.2.11
![](/images/thumb/9/94/User_hub.png/24px-User_hub.png)
- Getting started
- Installation: Download, Windows, Linux, Mac, Additional components, Docker, AppImage, Ubuntu Snap
- Basics: About FreeCAD, Interface, Mouse navigation, Selection methods, Object name, Preferences, Workbenches, Document structure, Properties, Help FreeCAD, Donate
- Help: Tutorials, Video tutorials
- Workbenches: Std Base, Assembly, BIM, CAM, Draft, FEM, Inspection, Mesh, OpenSCAD, Part, PartDesign, Points, Reverse Engineering, Robot, Sketcher, Spreadsheet, Surface, TechDraw, Test Framework
- Hubs: User hub, Power users hub, Developer hub