-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcx_setup.py
More file actions
44 lines (35 loc) · 1.36 KB
/
Copy pathcx_setup.py
File metadata and controls
44 lines (35 loc) · 1.36 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
from cx_Freeze import setup, Executable
import sys
# Dependencies are automatically detected, but it might need
# fine tuning.
# Pygame default font
import os
import pygame
font_path = os.path.dirname(pygame.__file__)
font = [p for p in os.listdir(font_path) if p[-4:] == '.ttf'][0]
font_path = os.path.join(font_path, font)
# font_path = 'freesansbold.ttf'
lib_files = ['holes_operations.dll', 'preflop.pkl', font_path]
assets_files = [os.path.join('assets', f) for f in os.listdir('assets')]
assets_files = [(f, f) for f in assets_files]
# If using , you need to include the following files
# PYTHON_INSTALL_DIR = os.path.dirname(os.path.dirname(os.__file__))
# MKL_BUG_DIR = os.path.join(PYTHON_INSTALL_DIR, 'Library', 'bin')
# lib_files += ([os.path.join(MKL_BUG_DIR, f) for f in os.listdir(MKL_BUG_DIR)
# if f [:4] == 'mkl_'] +
# [os.path.join(MKL_BUG_DIR, 'libiomp5md.dll')])
buildOptions = dict(
packages = [],
excludes = [],
include_files = lib_files + assets_files
)
# base = 'Console'
base = 'Win32GUI' if sys.platform=='win32' else None
executables = [
Executable('StackTheDeck.py', base=base, targetName = 'StackTheDeck')
]
setup(name='StackTheDeck',
version = '0.1',
description = '',
options = dict(build_exe = buildOptions),
executables = executables)