2. Installation¶
This section provides instructions for the following platforms:
See also:
2.1. Microsoft Windows¶
Download the installer from the repository and run it in your machine. It includes everything you need.
2.1.1. Installing from source in Windows¶
An easy way to get the requirements in your system is to install WinPython. This is a standalone distribution of Python which includes all of FlatCAM’s dependencies, except for Shapely and RTree. These can be found here: Unofficial Windows Binaries for Python Extension Packages.
Once the dependencies are installed, download the latest .zip release (or the latest source as described in Installing the Latest Source, although it is not garanteed to work), unpack it, change into the created folder and run:
python FlatCAM.py
2.2. Linux¶
FlatCAM should work on most Linux distributions but Ubuntu has been chosen as the test platform.
FlatCAM must be installed from source in Linux. You can download a release .zip file from the repository or the latest source as described in Installing the Latest Source.
There are several dependencies required to run FlatCAM. These are
listed in Requirements below. Before attempting a manual installation,
try running the provided setup script setup_ubuntu.sh
that will
download and install required packages.
2.2.1. Manual Installation in Linux¶
Under Linux, most modern package installers like yum or apt-get
will attempt to locate and install the whole tree of dependencies for a
specified package automatically. Refer to the provided setup script
setup_ubuntu.sh
for the names and installation order.
Once the dependencies are installed, download the latest .zip release (or the latest source, although it is not garanteed to work), unpack it, change into the created folder and run:
Python FlatCAM.py
2.3. OS-X¶
FlatCAM must be installed from source in OS-X. All dependencies (see Requirements) must be installed manually.
Start by installing binary packages: pyqt, geos, spatialindex. One way to do this is using Homebrew:
brew install name_of_package
Now you can install all Python packages (numpy, matplotlib, rtree, scipy, shapely, simplejson) using pip:
pip install name_of_package
Finally, download the latest FlatCAM .zip package or source code. Change into its directory and launch it by running:
python FlatCAM.py
2.4. Requirements¶
FlatCAM is written in Python, uses the Python standard library and and some 3rd-party libraries listed below.
- Python 2.7 32-bit
- PyQt 4
- Matplotlib 1.3.1
- Numpy 1.8
- Shapely 1.3
- GEOS (Binary package required by Shapely)
- RTree
- SpatialIndex (Binary package required by RTree)
These packages might have their own dependencies.
2.5. Diagnostics Script¶
The script sandbox/diagnose.py
is provided along with the source code.
It attempts to import the Python libraries that FlatCAM requires and prints their
version numbers. This is useful when communicating with other users and
determining differences in the environments.
2.6. Installing the Latest Source¶
The source code of FlatCAM is maintained through a revision control system called Git. Revision control allows us to keep track of every change ever made to the code and makes it possible for users across the world to work together.
A public respository is kept on the web at https://bitbucket.org/jpcgt/flatcam
.
On any Unix-like platform with Git installed, you can clone the repository in your local machine with the following command:
git clone https://bitbucket.org/jpcgt/flatcam
This will create a folder (directory) named flatcam
in the folder
where the command was run.
FlatCAM can be run directly from this folder (after installing all the dependencies):
cd flatcam
python FlatCAM.py
In addition, there is a folder named .git
which contains the whole
history of the project.
To learn more about contributing code to FlatCAM go to http://flatcam.org/development
.
To learn more about revision control with Git, visit: