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
matplotlib 1.3.0 doesn't compile with Solaris Studio 12.1 CC #2375
Comments
Shot in the dark, since I don't have access to a Solaris box anymore. Does diff --git a/src/ft2font.h b/src/ft2font.h
index 813a554..2d2c997 100644
--- a/src/ft2font.h
+++ b/src/ft2font.h
@@ -81,7 +81,7 @@ class Glyph : public Py::PythonClass<Glyph>
{
public:
Glyph(Py::PythonClassInstance *self, Py::Tuple &args, Py::Dict &kwds) :
- Py::PythonClass<Glyph>::PythonClass(self, args, kwds) { }
+ Py::PythonClass<Glyph>(self, args, kwds) { }
virtual ~Glyph();
static Py::PythonClassObject<Glyph> factory(const FT_Face&, const FT_Glyph&, size_t, long);
int setattro(const Py::String &name, const Py::Object &value); help? |
Yes, this help little. Now I get: "src/ft2font.cpp", line 849: Warning: error hides FT2Font::error. ..... Any new idea? |
The second is due to:
which is common enough of a construction that any compiler should handle it, but you could try:
instead. |
This didn't help: building 'matplotlib._tri' extension Borut |
Then I'm at a loss, unfortunately. |
At this point, I would go with my personal rule of "work from the top" when Which indicates to me a possible issue with something in numpy. Now, in my |
BUILDING MATPLOTLIB REQUIRED DEPENDENCIES AND EXTENSIONS |
So, the line in question refers to this enum definition:
This is completely a shot in the dark, but perhaps that incredibly long enum identifier might be tripping up the compiler? |
After removing the last comma in typedef enum, warning disappear: typedef enum { in file /usr/lib/python2.6/site-packages/numpy/core/include/numpy/ndarraytypes.h The first errors are coming from this part in lib/matplotlib/tri/_tri.h: "lib/matplotlib/tri/_tri.h", line 823: Error: A declaration does not specify a tag or an identifier. Any idea? |
Looks like one of the problems are _M, _A, _C in lib/matplotlib/tri/_tri.cpp: RandomNumberGenerator::RandomNumberGenerator(unsigned long seed) unsigned long Is underscore a problem? |
Or, maybe specifically, "_C" is a problem, as in it might be treated as a |
I just replaced "M","A","C" with "M","A","C" and this works! However, there are many warnings: Exist any test routine to see if everything is working? |
Running basic_example.py failed:
|
At this point, I am just not sure anymore. As a complete guess, I would @mdboom, a coworker passed along a link that might be useful for us: It isn't solaris 12, but who knows? |
I am wondering what libgcc_s.so.1 is doing here when I am compiling with sunstudio12.1 |
I am starting from fresh... Why do I get /usr/sfw/lib instead of /opt/sunstudio12.1/lib here: /usr/lib/python2.6/pyCC -L. -L/usr/sfw/lib -R/usr/sfw/lib -G build/temp.solaris-2.10-i86pc-2.6/src/mplutils.o build/temp.solaris-2.10-i86pc-2.6/src/agg_py_transforms.o build/temp.solaris-2.10-i86pc-2.6/src/_backend_agg.o build/temp.solaris-2.10-i86pc-2.6/agg24/src/agg_bezier_arc.o build/temp.solaris-2.10-i86pc-2.6/agg24/src/agg_curves.o build/temp.solaris-2.10-i86pc-2.6/agg24/src/agg_image_filters.o build/temp.solaris-2.10-i86pc-2.6/agg24/src/agg_trans_affine.o build/temp.solaris-2.10-i86pc-2.6/agg24/src/agg_vcgen_contour.o build/temp.solaris-2.10-i86pc-2.6/agg24/src/agg_vcgen_dash.o build/temp.solaris-2.10-i86pc-2.6/agg24/src/agg_vcgen_stroke.o build/temp.solaris-2.10-i86pc-2.6/agg24/src/agg_vpgen_segmentator.o build/temp.solaris-2.10-i86pc-2.6/CXX/cxxsupport.o build/temp.solaris-2.10-i86pc-2.6/CXX/IndirectPythonInterface.o build/temp.solaris-2.10-i86pc-2.6/CXX/cxx_extensions.o build/temp.solaris-2.10-i86pc-2.6/CXX/cxxextensions.o -L/usr/local/lib -L/usr/sfw/lib -L. -lfreetype -lstdc++ -lm -lpython2.6 -o build/lib.solaris-2.10-i86pc-2.6/matplotlib/backends/_backend_agg.so This enviroment variables are set: |
How do I control which libraries should be linked? I am compiling with Solaris Studio and not with g++! As we can see "-lstdc++" from /usr/local/lib/libstdc++* is used instead of /opt/sunstudio12.1/lib/libCstd.so I tried to compile matplotlib on Solaris 11 where I have only Solaris Studio installed. This failed because libstdc++ is not installed! Removing "-lstdc++" lead to successful build. Looks like "-lstdc++" is hard coded library to use. How do I tell build process to use Solaris Studio and their libraries? |
I don't think we have any developers on Solaris, and I wouldn't stick my neck out to say it's officially supported. However, we do use Python distutils as our build system, so anything that applies to that would also apply here. You may want to look through the distutils documentation for ways that the compiler can be forced or for Solaris Studio-specific information. |
@podlipnik Did you ever get this sorted out? |
Never! On Tue, Feb 25, 2014 at 2:01 AM, Thomas A Caswell
++++++++++++++++++++++++++++++++++++ |
Too bad, I'm hitting this identically. Have other folks had success installing matplotlib on other versions of solaris recently? |
@podlipnik @joan-smith Have you tried with more current version of matplotlib? |
I didn't. On Sun, Aug 17, 2014 at 11:39 PM, Thomas A Caswell <notifications@github.com
|
Has anyone with a solaris box tried to recompile with 1.5.0? There were some pretty major refactoring of the c++ wrapping layer and minor refactoring it |
I used to have access to Solaris at STScI, but even they were phasing it out. |
I'm no longer working on Solaris machines, so haven't tried with a more recent version. Sorry! |
This looks like a case of "can't fix it", and declining importance as Solaris machines become less common. Closing. |
python setup.py build
Edit setup.cfg to change the build options
BUILDING MATPLOTLIB
matplotlib: yes [1.3.0]
python: yes [2.6.4 (r264:75706, Jun 26 2012, 21:27:36) [C]]
platform: yes [sunos5]
REQUIRED DEPENDENCIES AND EXTENSIONS
numpy: yes [version 1.7.1]
dateutil: yes [using dateutil version 2.1]
tornado: yes [using tornado version 3.1.1]
pyparsing: yes [using pyparsing version 2.0.1]
pycxx: yes [Couldn't import. Using local copy.]
libagg: yes [pkg-config information for 'libagg' could not
be found. Using local copy.]
freetype: yes [version 14.1.8]
png: yes [version 1.2.49]
OPTIONAL SUBPACKAGES
sample_data: yes [installing]
toolkits: yes [installing]
tests: yes [nose 0.11.1 or later is required to run the
matplotlib test suite]
OPTIONAL BACKEND EXTENSIONS
macosx: no [Mac OS-X only]
qt4agg: no [PyQt4 not found]
gtk3agg: no [Requires pygobject to be installed.]
gtk3cairo: no [Requires cairo to be installed.]
gtkagg: no [Requires pygtk]
tkagg: yes [version 73770]
wxagg: no [requires wxPython]
gtk: no [Requires pygtk]
agg: yes [installing]
cairo: no [cairo not found]
windowing: no [Microsoft Windows only]
OPTIONAL LATEX DEPENDENCIES
dvipng: no
ghostscript: yes [version 9.00]
latex: no
pdftops: yes [version 0.14.4]
/usr/lib/python2.6/distutils/dist.py:266: UserWarning: Unknown distribution option: 'use_2to3'
warnings.warn(msg)
running build
running build_py
copying lib/matplotlib/mpl-data/matplotlibrc -> build/lib.solaris-2.10-i86pc-2.6/matplotlib/mpl-data
running build_ext
building 'matplotlib.ft2font' extension
/usr/lib/python2.6/pycc -DNDEBUG -KPIC -DPY_ARRAY_UNIQUE_SYMBOL=MPL_matplotlib_ft2font_ARRAY_API -DPYCXX_ISO_CPP_LIB=1 -I/usr/local/include -I. -I/usr/sfw/include -I/usr/sfw/include/freetype2 -I/usr/lib/python2.6/site-packages/numpy/core/include -I/usr/include/python2.6 -c src/ft2font.cpp -o build/temp.solaris-2.10-i86pc-2.6/src/ft2font.o
CC: Warning: Option -fPIC passed to ld, if ld is invoked, ignored otherwise
"/usr/sfw/include/freetype2/freetype/config/ftconfig.h", line 83: Warning (Anachronism): Attempt to redefine SIZEOF_LONG without using #undef.
"src/ft2font.h", line 84: Error: PythonClass may not have a type qualifier.
"src/ft2font.h", line 84: Error: Py::PythonClassPy::T cannot be initialized in a constructor.
"src/ft2font.h", line 84: Error: Could not find Py::PythonClass::PythonClass() to initialize base class.
"/usr/lib/python2.6/site-packages/numpy/core/include/numpy/ndarraytypes.h", line 209: Warning: Identifier expected instead of "}".
"src/ft2font.cpp", line 849: Warning: error hides FT2Font::error.
"src/ft2font.cpp", line 1021: Warning: ptsize hides FT2Font::ptsize.
"src/ft2font.cpp", line 1022: Warning: dpi hides FT2Font::dpi.
"src/ft2font.cpp", line 1024: Warning: error hides FT2Font::error.
"src/ft2font.cpp", line 1328: Warning: error hides FT2Font::error.
"src/ft2font.cpp", line 1378: Warning: error hides FT2Font::error.
"src/ft2font.cpp", line 1738: Warning: error hides FT2Font::error.
"src/ft2font.cpp", line 1789: Warning: error hides FT2Font::error.
"src/ft2font.cpp", line 1992: Warning: angle hides FT2Font::angle.
"src/ft2font.cpp", line 2070: Warning: error hides FT2Font::error.
3 Error(s) and 12 Warning(s) detected.
error: command '/usr/lib/python2.6/pycc' failed with exit status 3
Looks like this is still not fixed. Any idea how to get matplotlib compiled on Solaris 10 x86?
Borut
The text was updated successfully, but these errors were encountered: