Make VMD easyblock Python 3 compatible#2083
Merged
boegel merged 1 commit intoeasybuilders:developfrom Jul 4, 2020
Merged
Conversation
boegel
approved these changes
Jul 4, 2020
Member
boegel
left a comment
There was a problem hiding this comment.
lgtm
Tested with existing VMD easyconfigs, still works like a charm.
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Besides the fix for getting the Numpy include path (which didn't work in Python 3), I'm also adding two additional environment variables. The first sets the path to the Python include dir (Python 3 versions have something like include/python3.7m/python.h), for which I use the sysconfig package in Python. The second holds the linker flags (-lpython3.7m) for linking the Python libraries. For the latter I call python-config, e.g.:
Since this only adds two environment variables (which my patch for new VMD versions will pick up), older VMD version should still work fine (they seem to have some hardcoded stuff in the configure script for, for instance, the name of the Python library).