From 93555a134e59101aa32dee07b9be248bbd88c52c Mon Sep 17 00:00:00 2001 From: Marius Stanciu Date: Sat, 7 Nov 2020 09:12:47 +0200 Subject: [PATCH] - set the app to "Unstable" status --- CHANGELOG.md | 1 + app_Main.py | 6 +-- make_freezed.py | 120 ++++++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 124 insertions(+), 3 deletions(-) create mode 100644 make_freezed.py diff --git a/CHANGELOG.md b/CHANGELOG.md index 5ab81e66..952f50c5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -10,6 +10,7 @@ CHANGELOG for FlatCAM beta 7.11.2020 - fixed some issues with not finding the methods when treating the startup arguments +- set the app to "Unstable" status 7.11.2020 diff --git a/app_Main.py b/app_Main.py index 6e277907..80c2ba14 100644 --- a/app_Main.py +++ b/app_Main.py @@ -164,9 +164,9 @@ class App(QtCore.QObject): # ############################################################################################################### # ################################### Version and VERSION DATE ################################################## # ############################################################################################################### - # version = "Unstable Version" - version = 8.994 - version_date = "2020/11/7" + version = "Unstable Version" + # version = 8.994 + version_date = "2020/12/7" beta = True engine = '3D' diff --git a/make_freezed.py b/make_freezed.py new file mode 100644 index 00000000..f2686fde --- /dev/null +++ b/make_freezed.py @@ -0,0 +1,120 @@ +# ########################################################## +# FlatCAM: 2D Post-processing for Manufacturing # +# http://flatcam.org # +# Author: Juan Pablo Caram (c) # +# Date: 12/20/2018 # +# MIT Licence # +# # +# Creates a portable 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. # +# ########################################################## + +# ########################################################## +# File Modified: Marius Adrian Stanciu # +# Date: 3/10/2019 # +# ########################################################## + + +# 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 +import site +import sys +import platform +from cx_Freeze import setup, Executable + +# this is done to solve the tkinter not being found +PYTHON_INSTALL_DIR = os.path.dirname(os.path.dirname(os.__file__)) +os.environ['TCL_LIBRARY'] = os.path.join(PYTHON_INSTALL_DIR, 'tcl', 'tcl8.6') +os.environ['TK_LIBRARY'] = os.path.join(PYTHON_INSTALL_DIR, 'tcl', 'tk8.6') + +# 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, "svg"), "svg")) +include_files.append((os.path.join(site_dir, "svg/path"), "svg")) +include_files.append((os.path.join(site_dir, "vispy"), "vispy")) +include_files.append((os.path.join(site_dir, "vispy/app"), "vispy/app")) +include_files.append((os.path.join(site_dir, "vispy/app/backends"), "vispy/app/backends")) +# include_files.append((os.path.join(site_dir, "matplotlib"), "matplotlib")) +include_files.append((os.path.join(site_dir, "rtree"), "rtree")) + +if platform.architecture()[0] == '64bit': + include_files.append((os.path.join(site_dir, "google"), "google")) + include_files.append((os.path.join(site_dir, "google/protobuf"), "google/protobuf")) + include_files.append((os.path.join(site_dir, "ortools"), "ortools")) + +include_files.append(("locale", "lib/locale")) +include_files.append(("preprocessors", "lib/preprocessors")) +# include_files.append(("assets", "lib/assets")) +include_files.append(("assets/examples", "lib/assets/examples")) +include_files.append(("assets/linux", "lib/assets/linux")) +include_files.append(("assets/resources", "lib/assets/resources")) +# include_files.append(("share", "lib/share")) +include_files.append(("appGUI/VisPyData", "lib/vispy")) +include_files.append(("config", "lib/config")) + +include_files.append(("README.md", "README.md")) +include_files.append(("LICENSE", "LICENSE")) +include_files.append(("CHANGELOG.md", "CHANGELOG.md")) +base = None + +# Lets not open the console while running the app +if sys.platform == "win32": + base = "Win32GUI" + +if platform.architecture()[0] == '64bit': + buildOptions = dict( + include_files=include_files, + excludes=['scipy', 'pytz', "matplotlib.tests", "numpy.random._examples"], + # packages=['OpenGL','numpy','vispy','ortools','google'] + # packages=['numpy','google', 'rasterio'] # works for Python 3.7 + packages=['opengl', 'numpy', 'google', 'rasterio'], # works for Python 3.6.5 and Python 3.7.1 + ) +else: + buildOptions = dict( + include_files=include_files, + excludes=['scipy', 'pytz'], + # packages=['OpenGL','numpy','vispy','ortools','google'] + # packages=['numpy', 'rasterio'] # works for Python 3.7 + packages=['opengl', 'numpy', 'rasterio'], # works for Python 3.6.5 and Python 3.7.1 + ) + +if sys.platform == "win32": + buildOptions["include_msvcr"] = True + +print("INCLUDE_FILES", include_files) + + +def getTargetName(): + my_OS = platform.system() + if my_OS == 'Linux': + return "FlatCAM" + elif my_OS == 'Windows': + return "FlatCAM.exe" + else: + return "FlatCAM.dmg" + + +exe = Executable("FlatCAM.py", icon='assets/resources/flatcam_icon48.ico', base=base, targetName=getTargetName()) + +setup( + name="FlatCAM", + author="Community effort", + version="8.9", + description="FlatCAM Evo: 2D Computer Aided PCB Manufacturing", + options=dict(build_exe=buildOptions), + executables=[exe] +)