forked from SteveDoyle2/pyNastran
-
Notifications
You must be signed in to change notification settings - Fork 0
/
setup_no_reqs.py
90 lines (79 loc) · 3.26 KB
/
setup_no_reqs.py
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
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
#!/usr/bin/env python
import os
from setuptools import setup, find_packages
import pyNastran
from packages import (check_python_version, get_package_requirements,
update_version_file, PYTHON_REQUIRES,
LONG_DESCRIPTION, CLASSIFIERS)
check_python_version()
all_reqs, install_requires = get_package_requirements(is_gui=True)
packages = find_packages() + ['gui/icons/*.*']
# set up all icons
icon_path = os.path.join('pyNastran', 'gui', 'icons')
icon_files = os.listdir(icon_path)
icon_files2 = []
for icon_file in icon_files:
if icon_file.endswith('.png'):
icon_files2.append(os.path.join(icon_path, icon_file))
exclude_words = [
'pyNastran.dev.bdf_vectorized', 'pyNastran.dev.bdf_vectorized.cards',
'pyNastran.f06.dev',
'pyNastran.op2.dev', 'pyNastran.op2.dev.original',
'pyNastran.converters.dev', 'pyNastran.xdb',]
packages = find_packages(exclude=['ez_setup', 'examples', 'tests'] + exclude_words)
for exclude_word in exclude_words:
packages = [package for package in packages if exclude_word not in package]
#print(packages, len(packages)) # 83
#revision = get_git_revision_short_hash()
#__version__ = '1.3.0+%s' % revision
#__releaseDate__ = '2019/6/xx'
#__releaseDate2__ = 'JUNE xx, 2019'
update_version_file()
setup(
name='pyNastran',
version=pyNastran.__version__,
description=pyNastran.__desc__,
long_description=LONG_DESCRIPTION,
long_description_content_type='text/x-rst',
classifiers=CLASSIFIERS,
keywords='',
python_requires=PYTHON_REQUIRES,
author=pyNastran.__author__,
author_email=pyNastran.__email__,
url=pyNastran.__website__,
license=pyNastran.__license__,
packages=packages,
include_package_data=True,
zip_safe=False,
#{'': ['license.txt']}
#package_data={'': ['*.png']},
#data_files=[(icon_path, icon_files2)],
package_data={
# https://pythonhosted.org/setuptools/setuptools.html#including-data-files
# If any package contains *.png files, include them:
'': ['*.png'],
#'mypkg': ['data/*.dat'],
},
entry_points={
'console_scripts': [
#'run_nastran_double_precision = pyNastran.bdf.test.run_nastran_double_precision:cmd_line',
'test_bdf = pyNastran.bdf.test.test_bdf:main',
'test_op2 = pyNastran.op2.test.test_op2:main',
'test_op4 = pyNastran.op4.test.test_op4:main',
#'test_abaqus = pyNastran.converters.abaqus.test_abaqus:main',
'test_pynastrangui = pyNastran.gui.test.test_gui:main',
'format_converter = pyNastran.converters.format_converter:cmd_line_format_converter',
'pyNastranGUI = pyNastran.gui.gui:cmd_line',
'bdf = pyNastran.bdf.mesh_utils.utils:cmd_line',
'f06 = pyNastran.f06.utils:cmd_line',
#'pyNastranv = pyNastran.dev.bdf_vectorized.solver.solver:main',
#'test_bdfv = pyNastran.dev.bdf_vectorized.test.test_bdf_vectorized2:main',
#'test_bdfv = pyNastran.dev.bdf_vectorized2.test.test_bdf:main',
#'nastran_to_code_aster = pyNastran.converters.dev.code_aster.nastran_to_code_aster:main',
]
},
test_suite='pyNastran.all_tests',
)
print()
for package in install_requires:
print('did not install %s' % package)