Visitar URL original
Compiled failed in arm64 · Issue #19027 · matplotlib/matplotlib · GitHub
Skip to content

Compiled failed in arm64 #19027

Description

@wanganhong

Compilation problems

Build steps

tar -zxvf matplotlib-3.1.2.tar.gz
cd matplotlib-3.1.2
python setup.py build

Error detail

BUILDING MATPLOTLIB
  matplotlib: yes [3.1.2]
      python: yes [3.6.3 (default, Nov 23 2020, 09:56:24)  [GCC 4.8.5 20150623
                  (Red Hat 4.8.5-44)]]
    platform: yes [linux]

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

OPTIONAL BACKEND EXTENSIONS
         agg: yes [installing]
       tkagg: yes [installing; run-time loading from Python Tcl/Tk]
      macosx: no  [Mac OS-X only]

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

/usr/local/python3.6/lib/python3.6/distutils/dist.py:261: UserWarning: Unknown distribution option: 'project_urls'
  warnings.warn(msg)
running build
running build_py
copying lib/matplotlib/mpl-data/matplotlibrc -> build/lib.linux-aarch64-3.6/matplotlib/mpl-data
UPDATING build/lib.linux-aarch64-3.6/matplotlib/_version.py
set build/lib.linux-aarch64-3.6/matplotlib/_version.py to '3.1.2'
running build_ext
building 'matplotlib._png' extension
gcc -pthread -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -fPIC -DPY_ARRAY_UNIQUE_SYMBOL=MPL_matplotlib__png_ARRAY_API -DNPY_NO_DEPRECATED_API=NPY_1_7_API_VERSION -D__STDC_FORMAT_MACROS=1 -I/home/wah/venv/lib/python3.6/site-packages/numpy/core/include -I/home/wah/venv/include -I/usr/local/python3.6/include/python3.6m -c src/checkdep_libpng.c -o build/temp.linux-aarch64-3.6/src/checkdep_libpng.o -I/usr/include/libpng15
src/checkdep_libpng.c:2:9: note: #pragma message: Compiling with libpng version 1.5.13.
 #pragma message("Compiling with libpng version " PNG_LIBPNG_VER_STRING ".")
         ^
gcc -pthread -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -fPIC -DPY_ARRAY_UNIQUE_SYMBOL=MPL_matplotlib__png_ARRAY_API -DNPY_NO_DEPRECATED_API=NPY_1_7_API_VERSION -D__STDC_FORMAT_MACROS=1 -I/home/wah/venv/lib/python3.6/site-packages/numpy/core/include -I/home/wah/venv/include -I/usr/local/python3.6/include/python3.6m -c src/_png.cpp -o build/temp.linux-aarch64-3.6/src/_png.o -I/usr/include/libpng15
gcc -pthread -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -fPIC -DPY_ARRAY_UNIQUE_SYMBOL=MPL_matplotlib__png_ARRAY_API -DNPY_NO_DEPRECATED_API=NPY_1_7_API_VERSION -D__STDC_FORMAT_MACROS=1 -I/home/wah/venv/lib/python3.6/site-packages/numpy/core/include -I/home/wah/venv/include -I/usr/local/python3.6/include/python3.6m -c src/mplutils.cpp -o build/temp.linux-aarch64-3.6/src/mplutils.o -I/usr/include/libpng15
g++ -pthread -shared build/temp.linux-aarch64-3.6/src/checkdep_libpng.o build/temp.linux-aarch64-3.6/src/_png.o build/temp.linux-aarch64-3.6/src/mplutils.o -L/usr/local/python3.6/lib -lpython3.6m -o build/lib.linux-aarch64-3.6/matplotlib/_png.cpython-36m-aarch64-linux-gnu.so -lpng15
collect2: error: ld terminated with signal 9 [Killed]
error: command 'g++' failed with exit status 1

I've tried to expand virtual memory,it didn't work.

Matplotlib version

  • Operating system: CentOS Linux release 7.9.2009 (AltArch)
  • kernal: Linux ecs-ea1f 4.18.0-193.28.1.el7.aarch64 Fix autofmt_xdate() when using in conjunction with twinx() #1 SMP Wed Oct 21 16:25:35 UTC 2020 aarch64 aarch64 aarch64 GNU/Linux
  • Matplotlib version: 3.1.2
  • Python version: python3.6.3
  • Other libraries: freetype-2.8,gcc-4.8.5,gcc-c++-4.8.5
  • mem: 8G
  • swap: 2G

Activity

  1. QuLogic commented on Nov 27, 2020

    @QuLogic
    Member

    Try a newer version?

  2. wanganhong commented on Nov 30, 2020

    @wanganhong
    Author

    Also failed in version 3.3.3, got the following error

    BUILDING MATPLOTLIB
      matplotlib: yes [3.3.3]
          python: yes [3.6.3 (default, Nov 23 2020, 09:56:24)  [GCC 4.8.5 20150623
                      (Red Hat 4.8.5-44)]]
        platform: yes [linux]
     sample_data: yes [installing]
           tests: no  [skipping due to configuration]
          macosx: no  [Mac OS-X only]
    
    /usr/local/python3.6/lib/python3.6/distutils/dist.py:261: UserWarning: Unknown distribution option: 'project_urls'
      warnings.warn(msg)
    /usr/local/python3.6/lib/python3.6/distutils/dist.py:261: UserWarning: Unknown distribution option: 'long_description_content_type'
      warnings.warn(msg)
    running build
    running build_py
    copying lib/matplotlib/mpl-data/matplotlibrc -> build/lib.linux-aarch64-3.6/matplotlib/mpl-data
    UPDATING build/lib.linux-aarch64-3.6/matplotlib/_version.py
    set build/lib.linux-aarch64-3.6/matplotlib/_version.py to '3.3.3'
    running build_ext
    gcc -pthread -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -fPIC -I/home/wah/venv/include -I/usr/local/python3.6/include/python3.6m -c /tmp/tmpfivdp3xz.cpp -o tmp/tmpfivdp3xz.o -fvisibility=hidden
    gcc -pthread -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -fPIC -I/home/wah/venv/include -I/usr/local/python3.6/include/python3.6m -c /tmp/tmpro9uhhjw.cpp -o tmp/tmpro9uhhjw.o -fvisibility-inlines-hidden
    gcc -pthread -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -fPIC -I/home/wah/venv/include -I/usr/local/python3.6/include/python3.6m -c /tmp/tmp62mkdrxe.cpp -o tmp/tmp62mkdrxe.o -flto
    building 'matplotlib._contour' extension
    gcc -pthread -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -fPIC -DPY_ARRAY_UNIQUE_SYMBOL=MPL_matplotlib__contour_ARRAY_API -DNPY_NO_DEPRECATED_API=NPY_1_7_API_VERSION -D__STDC_FORMAT_MACROS=1 -Iextern/agg24-svn/include -I/home/wah/venv/lib/python3.6/site-packages/numpy/core/include -I/home/wah/venv/include -I/usr/local/python3.6/include/python3.6m -c src/_contour.cpp -o build/temp.linux-aarch64-3.6/src/_contour.o -fvisibility=hidden -flto
    gcc -pthread -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -fPIC -DPY_ARRAY_UNIQUE_SYMBOL=MPL_matplotlib__contour_ARRAY_API -DNPY_NO_DEPRECATED_API=NPY_1_7_API_VERSION -D__STDC_FORMAT_MACROS=1 -Iextern/agg24-svn/include -I/home/wah/venv/lib/python3.6/site-packages/numpy/core/include -I/home/wah/venv/include -I/usr/local/python3.6/include/python3.6m -c src/_contour_wrapper.cpp -o build/temp.linux-aarch64-3.6/src/_contour_wrapper.o -fvisibility=hidden -flto
    gcc -pthread -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -fPIC -DPY_ARRAY_UNIQUE_SYMBOL=MPL_matplotlib__contour_ARRAY_API -DNPY_NO_DEPRECATED_API=NPY_1_7_API_VERSION -D__STDC_FORMAT_MACROS=1 -Iextern/agg24-svn/include -I/home/wah/venv/lib/python3.6/site-packages/numpy/core/include -I/home/wah/venv/include -I/usr/local/python3.6/include/python3.6m -c src/py_converters.cpp -o build/temp.linux-aarch64-3.6/src/py_converters.o -fvisibility=hidden -flto
    g++ -pthread -shared build/temp.linux-aarch64-3.6/src/_contour.o build/temp.linux-aarch64-3.6/src/_contour_wrapper.o build/temp.linux-aarch64-3.6/src/py_converters.o -L/usr/local/python3.6/lib -lpython3.6m -o build/lib.linux-aarch64-3.6/matplotlib/_contour.cpython-36m-aarch64-linux-gnu.so
    collect2: error: ld terminated with signal 9 [Killed]
    error: command 'g++' failed with exit status 1
    
  3. QuLogic commented on Nov 30, 2020

    @QuLogic
    Member

    Well, the process is getting killed; that's not something that Matplotlib's setup is doing. You'll have to figure out why that is happening.

  4. QuLogic commented on Apr 5, 2021

    @QuLogic
    Member

    Closing, because this is a compiler crashing, not Matplotlib, but also, we now have aarch64 wheels that can be installed without compiling at all.

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions