8000 Build errors with existing qhull · Issue #8872 · matplotlib/matplotlib · GitHub
[go: up one dir, main page]

Skip to content
Build errors with existing qhull #8872
Closed
@eric-wieser

Description

@eric-wieser

Having trouble building matplotlib from source. It seems that QHULL_LIB_CHECK is not defined for me, which causes a chain of useless errors. My guess is that the problem is I already have a system Qhull package (for ROS), which is conflicting with the bundled one. Here's the output I get:

python setup.py build
============================================================================
Edit setup.cfg to change the build options

BUILDING MATPLOTLIB
            matplotlib: yes [2.0.2+4383.g4690576]
                python: yes [2.7.6 (default, Oct 26 2016, 20:30:19)  [GCC
                        4.8.4]]
              platform: yes [linux2]

REQUIRED DEPENDENCIES AND EXTENSIONS
                 numpy: yes [version 1.8.2]
                   six: yes [using six version 1.10.0]
              dateutil: yes [using dateutil version 1.5]
backports.functools_lru_cache: yes [backports.functools_lru_cache was not
                        found. It is required forPython versions prior to
                        3.2]
          subprocess32: yes [subprocess32 was not found. It used  for Python
                        versions prior to 3.2 to improves functionality on
                        Linux and OSX]
                  pytz: yes [using pytz version 2012c]
                cycler: yes [cycler was not found. pip/easy_install may
                        attempt to install it after matplotlib.]
               tornado: yes [tornado was not found. It is required for the
                        WebAgg backend. pip/easy_install may attempt to
                        install it after matplotlib.]
             pyparsing: yes [using pyparsing version 2.1.10]
                libagg: yes [pkg-config information for 'libagg' could not
                        be found. Using local copy.]
              freetype: yes [Using local version for testing]
                   png: yes [version 1.2.50]
                 qhull: yes [Using system Qhull (version unknown, no pkg-
                        config info)]

OPTIONAL SUBPACKAGES
           sample_data: yes [installing]
              toolkits: yes [installing]
                 tests: no  [skipping due to configuration]
        toolkits_tests: no  [skipping due to configuration]

OPTIONAL BACKEND EXTENSIONS
                macosx: no  [Mac OS-X only]
                qt5agg: no  [PySide2 not found; PyQt5 not found]
                qt4agg: yes [installing, Qt: 4.8.6, PySide: 1.2.1; Qt:
                        4.8.6, PyQt: 4.8.6]
               gtk3agg: no  [Requires gtk3 development files to be
                        installed.]
             gtk3cairo: no  [Requires gtk3 development files to be
                        installed.]
/usr/lib/python2.7/dist-packages/gtk-2.0/gtk/__init__.py:57: GtkWarning: could not open display
  warnings.warn(str(e), _gtk.Warning)
                gtkagg: no  [The C/C++ header for pygtk (pygtk/pygtk.h)
                        could not be found.  You may need to install the
                        development package.]
                 tkagg: yes [installing; run-time loading from Python Tcl /
                        Tk]
                 wxagg: yes [installing, version 2.8.12.1]
                   gtk: no  [The C/C++ header for pygtk (pygtk/pygtk.h)
                        could not be found.  You may need to install the
                        development package.]
                   agg: yes [installing]
                 cairo: yes [installing, pycairo version 1.8.8]
             windowing: no  [Microsoft Windows only]

OPTIONAL LATEX DEPENDENCIES
                dvipng: no
           ghostscript: yes [version 9.10]
                 latex: yes [version 3.1415926]
               pdftops: no

OPTIONAL PACKAGE DATA
                  dlls: no  [skipping due to configuration]

running build
running build_py
copying lib/matplotlib/mpl-data/matplotlibrc -> build/lib.linux-x86_64-2.7/matplotlib/mpl-data
UPDATING build/lib.linux-x86_64-2.7/matplotlib/_version.py
set build/lib.linux-x86_64-2.7/matplotlib/_version.py to '2.0.2+4383.g4690576'
running build_ext
building 'matplotlib._qhull' extension
x86_64-linux-gnu-gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -fPIC -DMPL_DEVNULL=/dev/null -DPY_ARRAY_UNIQUE_SYMBOL=MPL_matplotlib__qhull_ARRAY_API -DNPY_NO_DEPRECATED_API=NPY_1_7_API_VERSION -D__STDC_FORMAT_MACROS=1 -I/usr/lib/python2.7/dist-packages/numpy/core/include -I/usr/local/include -I/usr/include -I. -I/usr/include/python2.7 -c src/qhull_wrap.c -o build/temp.linux-x86_64-2.7/src/qhull_wrap.o
src/qhull_wrap.c: In function ‘delaunay_impl’:
src/qhull_wrap.c:112:5: error: unknown type name ‘QHULL_LIB_CHECK’
     QHULL_LIB_CHECK
     ^
src/qhull_wrap.c:115:5: error: conflicting types for ‘points’
     points = (coordT*)malloc(npoints*ndim*sizeof(coordT));
     ^
src/qhull_wrap.c:96:13: note: previous definition of ‘points’ was here
     coordT* points = NULL;
             ^
src/qhull_wrap.c:115:14: warning: initialization makes integer from pointer without a cast [enabled by default]
     points = (coordT*)malloc(npoints*ndim*sizeof(coordT));
              ^
src/qhull_wrap.c:116:16: warning: comparison between pointer and integer [enabled by default]
     if (points == NULL) {
                ^
src/qhull_wrap.c:124:15: error: subscripted value is neither array nor pointer nor vector
         points[2*i  ] = x[i];
               ^
src/qhull_wrap.c:125:15: error: subscripted value is neither array nor pointer nor vector
         points[2*i+1] = y[i];
               ^
src/qhull_wrap.c:147:29: warning: passing argument 3 of ‘qh_new_qhull’ makes pointer from integer without a cast [enabled by default]
                             "qhull d Qt Qbb Qc Qz", NULL, error_file);
                             ^
In file included from /usr/include/libqhull/qhull_a.h:27:0,
                 from src/qhull_wrap.c:10:
/usr/include/libqhull/libqhull.h:1002:9: note: expected ‘double *’ but argument is of type ‘int’
 int     qh_new_qhull(int dim, int numpoints, coordT *points, boolT ismalloc,
         ^
src/qhull_wrap.c:230:5: warning: passing argument 1 of ‘free’ makes pointer from integer without a cast [enabled by default]
     free(points);
     ^
In file included from /usr/include/python2.7/Python.h:42:0,
                 from src/qhull_wrap.c:8:
/usr/include/stdlib.h:483:13: note: expected ‘void *’ but argument is of type ‘int’
 extern void free (void *__ptr) __THROW;
             ^
src/qhull_wrap.c:249:5: warning: passing argument 1 of ‘free’ makes pointer from integer without a cast [enabled by default]
     free(points);
     ^
In file included from /usr/include/python2.7/Python.h:42:0,
                 from src/qhull_wrap.c:8:
/usr/include/stdlib.h:483:13: note: expected ‘void *’ but argument is of type ‘int’
 extern void free (void *__ptr) __THROW;
             ^
error: command 'x86_64-linux-gnu-gcc' failed with exit status 1

In case it's relevant, here's some info about my installed qhull

dpkg -s libqhull-dev
Package: libqhull-dev
Status: install ok installed
Priority: optional
Section: libdevel
Installed-Size: 1092
Maintainer: Ubuntu Developers <ubuntu-devel-discuss@lists.ubuntu.com>
Architecture: amd64
Multi-Arch: same
Source: qhull
Version: 2012.1-4
Depends: libqhull6 (= 2012.1-4)
Description: calculate convex hulls and related structures (development files)
 Qhull computes convex hulls, Delaunay triangulations, halfspace
 intersections about a point, Voronoi diagrams, furthest-site
 Delaunay triangulations, and furthest-site Voronoi diagrams. It
 runs in 2-d, 3-d, 4-d, and higher dimensions.
 .
 This package contains the files necessary for development (headers and
 libraries), as well as the library documentation in HTML format.
Original-Maintainer: Debian Science Maintainers <debian-science-maintainers@lists.alioth.debian.org>
Homepage: http://www.qhull.org

I'm doing this on WSL.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0