deploy-ng: Add plugins option to specify which plugins to copy

NOTE: pandagl is no longer automatically copied and a graphics plugin
must be specified.

TODO: Per-platform overrides
This commit is contained in:
Mitchell Stokes 2017-07-06 19:33:16 -07:00
parent d2d76c8a75
commit 09eb22b61e
2 changed files with 7 additions and 1 deletions

View File

@ -34,6 +34,7 @@ class build_apps(distutils.core.Command):
self.include_modules = {}
self.exclude_modules = {}
self.deploy_platforms = []
self.plugins = []
self.requirements_path = './requirements.txt'
self.pypi_extra_indexes = []
self.build_scripts= {
@ -186,8 +187,10 @@ class build_apps(distutils.core.Command):
freezer_extras.add((mod, None))
#FIXME: this is a temporary hack to pick up libpandagl.
plugin_list = ['panda3d/lib{}'.format(i) for i in self.plugins]
for lib in p3dwhl.namelist():
if lib.startswith('panda3d/libpandagl.'):
plugname = os.path.splitext(lib)[0]
if plugname in plugin_list:
source_path = os.path.join(p3dwhlfn, lib)
target_path = os.path.join(builddir, os.path.basename(lib))
search_path = [os.path.dirname(source_path)]

View File

@ -9,6 +9,9 @@ setup(
'gui_apps': {
'asteroids': 'main.py',
},
'plugins': [
'pandagl',
],
'deploy_platforms': [
'manylinux1_x86_64',
'macosx_10_6_x86_64',