-
Notifications
You must be signed in to change notification settings - Fork 287
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
03d7a7f
commit 51b0bc4
Showing
4 changed files
with
492 additions
and
250 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
# Adopted from pillow and pycapnp | ||
|
||
import sys | ||
|
||
from setuptools.build_meta import build_wheel | ||
|
||
backend_class = build_wheel.__self__.__class__ | ||
|
||
|
||
class _CustomBuildMetaBackend(backend_class): | ||
def run_setup(self, setup_script="setup.py"): | ||
if self.config_settings: | ||
flags = [ | ||
f"--{k}={v}" | ||
for k, v in self.config_settings.items() | ||
] | ||
sys.argv = sys.argv[:1] + ["build_ext"] + flags + sys.argv[1:] | ||
return super().run_setup(setup_script) | ||
|
||
def build_wheel( | ||
self, wheel_directory, config_settings=None, metadata_directory=None | ||
): | ||
self.config_settings = config_settings | ||
return super().build_wheel(wheel_directory, config_settings, metadata_directory) | ||
|
||
def build_editable( | ||
self, wheel_directory, config_settings=None, metadata_directory=None | ||
): | ||
self.config_settings = config_settings | ||
return super().build_editable( | ||
wheel_directory, config_settings, metadata_directory | ||
) | ||
|
||
_backend = _CustomBuildMetaBackend() | ||
build_wheel = _backend.build_wheel | ||
build_editable = _backend.build_editable |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
[project] | ||
name = "pymol" | ||
readme = "README.md" | ||
requires-python = ">=3.9" | ||
dynamic=["version"] | ||
license = {file = "LICENSE"} | ||
description = """ | ||
PyMOL is a Python-enhanced molecular graphics tool. | ||
It excels at 3D visualization of proteins, small molecules, density, | ||
surfaces, and trajectories. It also includes molecular editing, | ||
ray tracing, and movies. Open Source PyMOL is free to everyone! | ||
""" | ||
authors = [ | ||
{name = "Schrodinger", email = "[email protected]"}, | ||
] | ||
dependencies = [ | ||
"numpy>=1.26.4,<2", | ||
] | ||
|
||
[build-system] | ||
build-backend = "backend" | ||
backend-path = ["_custom_build"] | ||
requires = [ | ||
"numpy>=1.26.4,<2", | ||
"setuptools>=69.2.0", | ||
] | ||
|
||
[project.optional-dependencies] | ||
test = [ | ||
"pillow==10.3.0", | ||
"pytest==8.2.2", | ||
] | ||
|
||
[project.urls] | ||
Homepage = "https://pymol.org" | ||
Documentation = "https://pymol.org/dokuwiki" | ||
Repository = "https://github.com/schrodinger/pymol-open-source" | ||
"Bug Tracker" = "https://github.com/schrodinger/pymol-open-source/issues" | ||
Changelog = "https://github.com/schrodinger/pymol-open-source/blob/master/ChangeLog" | ||
|
||
[project.scripts] | ||
pymol = "pymol:launch" | ||
|
||
[tool.setuptools.packages.find] | ||
where = ["modules"] | ||
|
||
[tool.setuptools.package-data] | ||
pmg_qt = ["forms/*.ui"] | ||
|
Oops, something went wrong.