2016-09-22 14:17:51 +00:00
|
|
|
############################################################
|
|
|
|
# FlatCAM: 2D Post-processing for Manufacturing #
|
|
|
|
# http://flatcam.org #
|
|
|
|
# Author: Juan Pablo Caram (c) #
|
|
|
|
# Date: 2/5/2014 #
|
|
|
|
# MIT Licence #
|
|
|
|
# #
|
|
|
|
# Creates a portlable copy of FlatCAM, including Python #
|
|
|
|
# itself and all dependencies. #
|
|
|
|
# #
|
|
|
|
# This is not an aid to install FlatCAM from source on #
|
|
|
|
# Windows platforms. It is only useful when FlatCAM is up #
|
|
|
|
# and running and ready to be packaged. #
|
|
|
|
############################################################
|
|
|
|
|
2015-10-18 23:40:48 +00:00
|
|
|
# Files not needed: Qt, tk.dll, tcl.dll, tk/, tcl/, vtk/,
|
|
|
|
# scipy.lib.lapack.flapack.pyd, scipy.lib.blas.fblas.pyd,
|
|
|
|
# numpy.core._dotblas.pyd, scipy.sparse.sparsetools._bsr.pyd,
|
|
|
|
# scipy.sparse.sparsetools._csr.pyd, scipy.sparse.sparsetools._csc.pyd,
|
|
|
|
# scipy.sparse.sparsetools._coo.pyd
|
|
|
|
|
|
|
|
import os, site, sys
|
|
|
|
from cx_Freeze import setup, Executable
|
|
|
|
|
|
|
|
## Get the site-package folder, not everybody will install
|
|
|
|
## Python into C:\PythonXX
|
|
|
|
site_dir = site.getsitepackages()[1]
|
|
|
|
|
|
|
|
include_files = []
|
|
|
|
include_files.append((os.path.join(site_dir, "shapely"), "shapely"))
|
|
|
|
include_files.append((os.path.join(site_dir, "matplotlib"), "matplotlib"))
|
|
|
|
include_files.append(("share", "share"))
|
|
|
|
include_files.append((os.path.join(site_dir, "rtree"), "rtree"))
|
|
|
|
include_files.append(("README.md", "README.md"))
|
|
|
|
include_files.append(("LICENSE", "LICENSE"))
|
|
|
|
|
|
|
|
base = None
|
|
|
|
|
|
|
|
## Lets not open the console while running the app
|
|
|
|
if sys.platform == "win32":
|
|
|
|
base = "Win32GUI"
|
|
|
|
|
|
|
|
buildOptions = dict(
|
|
|
|
compressed=False,
|
|
|
|
include_files=include_files,
|
2017-06-01 11:44:49 +00:00
|
|
|
icon='share:flatcam_icon48.ico',
|
2015-10-18 23:40:48 +00:00
|
|
|
# excludes=['PyQt4', 'tk', 'tcl']
|
|
|
|
excludes=['scipy.lib.lapack.flapack.pyd',
|
|
|
|
'scipy.lib.blas.fblas.pyd',
|
|
|
|
'QtOpenGL4.dll']
|
|
|
|
)
|
|
|
|
|
|
|
|
print "INCLUDE_FILES", include_files
|
|
|
|
|
|
|
|
execfile('clean.py')
|
|
|
|
|
|
|
|
setup(
|
|
|
|
name="FlatCAM",
|
|
|
|
author="Juan Pablo Caram",
|
2016-09-22 14:17:51 +00:00
|
|
|
version="8.5",
|
2015-10-18 23:40:48 +00:00
|
|
|
description="FlatCAM: 2D Computer Aided PCB Manufacturing",
|
|
|
|
options=dict(build_exe=buildOptions),
|
|
|
|
executables=[Executable("FlatCAM.py", base=base)]
|
|
|
|
)
|