New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Patches Python to remove global OSX packages #831

Merged
merged 3 commits into from Oct 22, 2014

Conversation

Projects
None yet
3 participants
@remram44
Contributor

remram44 commented Oct 21, 2014

On Mac OS X only, if Python is built as a framework, site.py loads packages from /Library/... into sys.path. This is not what we want, UV-CDAT builds and uses its own libraries.

This disables it by patching Python's site.py before installation.

(needs testing)

@remram44 remram44 added this to the 2.1 milestone Oct 21, 2014

@remram44 remram44 self-assigned this Oct 21, 2014

Fixes Python patch step failing on OSX
Path to cmake command might include spaces.

@remram44 remram44 force-pushed the remram44:fixes-osx-global-pkgs branch from ed84a27 to 77f6e33 Oct 21, 2014

remram44 added some commits Oct 21, 2014

Patches Python to remove global OSX packages
On Mac OS X only, if Python is built as a framework, site.py loads
packages from /Library/... into sys.path.

This disables it by patching site.py before installation.

@remram44 remram44 force-pushed the remram44:fixes-osx-global-pkgs branch from 77f6e33 to 70299d2 Oct 21, 2014

@remram44

This comment has been minimized.

Contributor

remram44 commented Oct 21, 2014

The patch step for setup.py didn't work at all on OS X, because the @CMAKE_COMMAND@ contains spaces (/Applications/CMake 2.8-12.app/...). c3c799d fixes that.

@remram44

This comment has been minimized.

Contributor

remram44 commented Oct 21, 2014

Tested, works.

@remram44 remram44 added the gatekeeper label Oct 21, 2014

@aashish24

This comment has been minimized.

Contributor

aashish24 commented Oct 22, 2014

Thanks @remram44 what lined you changed in site.py?

@remram44

This comment has been minimized.

Contributor

remram44 commented Oct 22, 2014

I just commented out the special case for OS X and frameworks in getsitepackages():

https://gist.github.com/remram44/ddad605c91744df91ac7/revisions

@remram44

This comment has been minimized.

Contributor

remram44 commented Oct 22, 2014

Looks like this would fix #269 and #341

@doutriaux1

This comment has been minimized.

Member

doutriaux1 commented Oct 22, 2014

ok i will ask sam to test it here it will merge upon success. Thanks!

doutriaux1 added a commit that referenced this pull request Oct 22, 2014

Merge pull request #831 from remram44/fixes-osx-global-pkgs
Patches Python to remove global OSX packages
Ok Sam confirmed it works for him.

@doutriaux1 doutriaux1 merged commit aadef57 into CDAT:master Oct 22, 2014

1 check passed

continuous-integration/travis-ci The Travis CI build passed
Details

@remram44 remram44 deleted the remram44:fixes-osx-global-pkgs branch Nov 20, 2014

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment