Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Symbol not found: _CGAffineTransformIdentity on MacOS 10.6#1791

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
mdboom merged 1 commit intomatplotlib:masterfrommdboom:fix-macosx-build
Feb 27, 2013

Conversation

mdboom
Copy link
Member

On MacOS 10.6, Matplotlib installs without error, but is then not importable:

Python 3.2.3 (default, Apr 13 2012, 00:15:25) [GCC 4.2.1 (Apple Inc. build 5666) (dot 3)] on darwinType "help", "copyright", "credits" or "license" for more information.>>> import matplotlib.pyplot as pltTraceback (most recent call last):  File "<stdin>", line 1, in <module>  File "/Users/tom/Library/Python/3.2/lib/python/site-packages/matplotlib-1.3.x-py3.2-macosx-10.6-x86_64.egg/matplotlib/pyplot.py", line 98, in <module>    _backend_mod, new_figure_manager, draw_if_interactive, _show = pylab_setup()  File "/Users/tom/Library/Python/3.2/lib/python/site-packages/matplotlib-1.3.x-py3.2-macosx-10.6-x86_64.egg/matplotlib/backends/__init__.py", line 25, in pylab_setup    globals(),locals(),[backend_name])  File "/Users/tom/Library/Python/3.2/lib/python/site-packages/matplotlib-1.3.x-py3.2-macosx-10.6-x86_64.egg/matplotlib/backends/backend_macosx.py", line 21, in <module>    from matplotlib.backends import _macosxImportError: dlopen(/Users/tom/Library/Python/3.2/lib/python/site-packages/matplotlib-1.3.x-py3.2-macosx-10.6-x86_64.egg/matplotlib/backends/_macosx.so, 2): Symbol not found: _CGAffineTransformIdentity  Referenced from: /Users/tom/Library/Python/3.2/lib/python/site-packages/matplotlib-1.3.x-py3.2-macosx-10.6-x86_64.egg/matplotlib/backends/_macosx.so  Expected in: flat namespace in /Users/tom/Library/Python/3.2/lib/python/site-packages/matplotlib-1.3.x-py3.2-macosx-10.6-x86_64.egg/matplotlib/backends/_macosx.so

On Python 2.7, pyparsing doesn't even work:

>>> import matplotlib.pyplot as pltTraceback (most recent call last):  File "<stdin>", line 1, in <module>  File "/Users/tom/Library/Python/2.7/lib/python/site-packages/matplotlib-1.3.x-py2.7-macosx-10.6-x86_64.egg/matplotlib/__init__.py", line 113, in <module>    import pyparsing  File "/Users/tom/Library/Python/2.7/lib/python/site-packages/pyparsing-1.5.3-py2.7.egg/pyparsing.py", line 629    nonlocal limit,foundArity                 ^SyntaxError: invalid syntax

but I'll report that to the pyparsing developers.

@astrofrog
Copy link
ContributorAuthor

Regarding the pyparsing bug, the reason it's using 1.5.3 is because 2.0.0 fails to install during the matplotlib install:

Processing pyparsing-2.0.0.zipWriting /var/folders/8L/8L-R-5PbEh0ef6pKH-3E5k+++TI/-Tmp-/easy_install-VocUxa/pyparsing-2.0.0/setup.cfgRunning pyparsing-2.0.0/setup.py -q bdist_egg --dist-dir /var/folders/8L/8L-R-5PbEh0ef6pKH-3E5k+++TI/-Tmp-/easy_install-VocUxa/pyparsing-2.0.0/egg-dist-tmp-XdiKmpSyntaxError: ('invalid syntax', ('build/bdist.macosx-10.6-x86_64/egg/pyparsing.py', 629, 22, '        nonlocal limit,foundArity\n'))zip_safe flag not set; analyzing archive contents...SyntaxError: ('invalid syntax', ('/Users/tom/Library/Python/2.7/lib/python/site-packages/pyparsing-1.5.3-py2.7.egg/pyparsing.py', 629, 22, '        nonlocal limit,foundArity\n'))Adding pyparsing 1.5.3 to easy-install.pth fileInstalled /Users/tom/Library/Python/2.7/lib/python/site-packages/pyparsing-1.5.3-py2.7.eggerror: Could not find required distribution pyparsing>=1.5.6

But in any case, that's a separate issue.

@pelson
Copy link
Member

Thanks@astrofrog - I'm guessing this is new in the last day or so and this is a result of the change in#1454?

I don't think you're after a workaround, but if you were (or somebody else who finds this is) it is probably possible to change the backend inmatplotlibrc and avoid this message.

@astrofrog
Copy link
ContributorAuthor

@pelson - thanks - just to confirm, I also see this on Python 2.

I opened a separate issue for the pyparsing issue (#1792).

@mdboom
Copy link
Member

Just a note to someone trying to track down this bug -- I would compare the compiler arguments when building the_macosx.so extension prior to commit7940245 vs. now. Something is probably missing in the new version -- and the setup rework probably did not get enough mac testing. I might be able to get on a Mac later this afternoon...

@astrofrog
Copy link
ContributorAuthor

I can try and provide you with the compiler arguments - let me check.

@astrofrog
Copy link
ContributorAuthor

At7940245 (after):

/usr/bin/g++-4.2 -bundle -undefined dynamic_lookup -L/opt/local/lib build/temp.macosx-10.6-x86_64-2.7/src/_macosx.o build/temp.macosx-10.6-x86_64-2.7/src/agg_py_transforms.o build/temp.macosx-10.6-x86_64-2.7/src/path_cleanup.o build/temp.macosx-10.6-x86_64-2.7/agg24/src/agg_bezier_arc.o build/temp.macosx-10.6-x86_64-2.7/agg24/src/agg_curves.o build/temp.macosx-10.6-x86_64-2.7/agg24/src/agg_image_filters.o build/temp.macosx-10.6-x86_64-2.7/agg24/src/agg_trans_affine.o build/temp.macosx-10.6-x86_64-2.7/agg24/src/agg_vcgen_contour.o build/temp.macosx-10.6-x86_64-2.7/agg24/src/agg_vcgen_dash.o build/temp.macosx-10.6-x86_64-2.7/agg24/src/agg_vcgen_stroke.o build/temp.macosx-10.6-x86_64-2.7/CXX/cxx_extensions.o build/temp.macosx-10.6-x86_64-2.7/CXX/cxxsupport.o build/temp.macosx-10.6-x86_64-2.7/CXX/IndirectPythonInterface.o build/temp.macosx-10.6-x86_64-2.7/CXX/cxxextensions.o -L/usr/local/lib -L/usr/lib -L/usr/X11/lib -L/opt/local/lib -lstdc++ -lm -o build/lib.macosx-10.6-x86_64-2.7/matplotlib/backends/_macosx.so

At1cc6507 (before):

/usr/bin/g++-4.2 -bundle -undefined dynamic_lookup -L/opt/local/lib build/temp.macosx-10.6-x86_64-2.7/src/_macosx.o build/temp.macosx-10.6-x86_64-2.7/CXX/cxx_extensions.o build/temp.macosx-10.6-x86_64-2.7/CXX/cxxextensions.o build/temp.macosx-10.6-x86_64-2.7/CXX/cxxsupport.o build/temp.macosx-10.6-x86_64-2.7/CXX/IndirectPythonInterface.o build/temp.macosx-10.6-x86_64-2.7/src/agg_py_transforms.o build/temp.macosx-10.6-x86_64-2.7/src/path_cleanup.o -L/usr/local/lib -L/usr/lib -L/usr/X11/lib -L/opt/local/lib -lstdc++ -lm -o build/lib.macosx-10.6-x86_64-2.7/matplotlib/backends/_macosx.so -framework Cocoa

That's quite a big difference!

@astrofrog
Copy link
ContributorAuthor

It looks like

-framework Cocoa

is now missing - could it be that?

@mdboom
Copy link
Member

I think that's exactly it. Would you mind testing the attached patch?

@astrofrog
Copy link
ContributorAuthor

This fixes the issue - thanks!

By the way, any luck with getting Matplotlib on Shining Panda? I could set up a build on my local Jenkins Mac and publish to a remote Jenkins to catch this kind of issue early.

@mdboom
Copy link
Member

We're in the process of setting up the funding for Shining Panda for matplotlib. Stay tuned!

mdboom added a commit that referenced this pull requestFeb 27, 2013
Symbol not found: _CGAffineTransformIdentity on MacOS 10.6
@mdboommdboom merged commit54b9e76 intomatplotlib:masterFeb 27, 2013
@mdboommdboom deleted the fix-macosx-build branchAugust 7, 2014 13:50
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers
No reviews
Assignees
No one assigned
Labels
None yet
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

3 participants
@mdboom@astrofrog@pelson

[8]ページ先頭

©2009-2025 Movatter.jp