Unable to install scipy

Hi community!

I am not able to install scipy on Jetson AGX Xavier.

sudo su

and

pip install scipy

returns the following

Collecting scipy
  Using cached https://files.pythonhosted.org/packages/ee/5b/5afcd1c46f97b3c2ac3489dbc95d6ca28eacf8e3634e51f495da68d97f0f/scipy-1.3.1.tar.gz
  Installing build dependencies ... done
  Getting requirements to build wheel ... done
    Preparing wheel metadata ... done
Building wheels for collected packages: scipy
  Building wheel for scipy (PEP 517) ... error
  ERROR: Command errored out with exit status 1:
   command: /usr/bin/python3 /usr/local/lib/python3.6/dist-packages/pip/_vendor/pep517/_in_process.py build_wheel /tmp/tmpfucqyf4c
       cwd: /tmp/pip-install-igqt1qhy/scipy
  Complete output (798 lines):
  lapack_opt_info:
  lapack_mkl_info:
  customize UnixCCompiler
    libraries mkl_rt not found in ['/usr/local/lib', '/usr/lib', '/usr/lib/aarch64-linux-gnu']
    NOT AVAILABLE
  
  openblas_lapack_info:
  customize UnixCCompiler
  customize UnixCCompiler
    libraries openblas not found in ['/usr/local/lib', '/usr/lib', '/usr/lib/aarch64-linux-gnu']
    NOT AVAILABLE
  
  openblas_clapack_info:
  customize UnixCCompiler
  customize UnixCCompiler
    libraries openblas,lapack not found in ['/usr/local/lib', '/usr/lib', '/usr/lib/aarch64-linux-gnu']
    NOT AVAILABLE
  
  flame_info:
  customize UnixCCompiler
    libraries flame not found in ['/usr/local/lib', '/usr/lib', '/usr/lib/aarch64-linux-gnu']
    NOT AVAILABLE
  
  atlas_3_10_threads_info:
  Setting PTATLAS=ATLAS
  customize UnixCCompiler
    libraries lapack_atlas not found in /usr/local/lib
  customize UnixCCompiler
    libraries tatlas,tatlas not found in /usr/local/lib
  customize UnixCCompiler
    libraries lapack_atlas not found in /usr/lib
  customize UnixCCompiler
    libraries tatlas,tatlas not found in /usr/lib
  customize UnixCCompiler
    libraries lapack_atlas not found in /usr/lib/aarch64-linux-gnu/atlas
  customize UnixCCompiler
    libraries tatlas,tatlas not found in /usr/lib/aarch64-linux-gnu/atlas
  customize UnixCCompiler
  customize UnixCCompiler
    libraries tatlas,tatlas not found in /usr/lib/aarch64-linux-gnu
  <class 'numpy.distutils.system_info.atlas_3_10_threads_info'>
    NOT AVAILABLE
  
  atlas_3_10_info:
  customize UnixCCompiler
    libraries lapack_atlas not found in /usr/local/lib
  customize UnixCCompiler
    libraries satlas,satlas not found in /usr/local/lib
  customize UnixCCompiler
    libraries lapack_atlas not found in /usr/lib
  customize UnixCCompiler
    libraries satlas,satlas not found in /usr/lib
  customize UnixCCompiler
    libraries lapack_atlas not found in /usr/lib/aarch64-linux-gnu/atlas
  customize UnixCCompiler
    libraries satlas,satlas not found in /usr/lib/aarch64-linux-gnu/atlas
  customize UnixCCompiler
  customize UnixCCompiler
    libraries satlas,satlas not found in /usr/lib/aarch64-linux-gnu
  <class 'numpy.distutils.system_info.atlas_3_10_info'>
    NOT AVAILABLE
  
  atlas_threads_info:
  Setting PTATLAS=ATLAS
  customize UnixCCompiler
    libraries lapack_atlas not found in /usr/local/lib
  customize UnixCCompiler
    libraries ptf77blas,ptcblas,atlas not found in /usr/local/lib
  customize UnixCCompiler
    libraries lapack_atlas not found in /usr/lib
  customize UnixCCompiler
    libraries ptf77blas,ptcblas,atlas not found in /usr/lib
  customize UnixCCompiler
    libraries lapack_atlas not found in /usr/lib/aarch64-linux-gnu/atlas
  customize UnixCCompiler
    libraries ptf77blas,ptcblas,atlas not found in /usr/lib/aarch64-linux-gnu/atlas
  customize UnixCCompiler
  customize UnixCCompiler
    libraries ptf77blas,ptcblas,atlas not found in /usr/lib/aarch64-linux-gnu
  <class 'numpy.distutils.system_info.atlas_threads_info'>
    NOT AVAILABLE
  
  atlas_info:
  customize UnixCCompiler
    libraries lapack_atlas not found in /usr/local/lib
  customize UnixCCompiler
    libraries f77blas,cblas,atlas not found in /usr/local/lib
  customize UnixCCompiler
    libraries lapack_atlas not found in /usr/lib
  customize UnixCCompiler
    libraries f77blas,cblas,atlas not found in /usr/lib
  customize UnixCCompiler
    libraries lapack_atlas not found in /usr/lib/aarch64-linux-gnu/atlas
  customize UnixCCompiler
    libraries f77blas,cblas,atlas not found in /usr/lib/aarch64-linux-gnu/atlas
  customize UnixCCompiler
  customize UnixCCompiler
  customize UnixCCompiler
  <class 'numpy.distutils.system_info.atlas_info'>
  customize UnixCCompiler
  get_default_fcompiler: matching types: '['gnu95', 'intel', 'lahey', 'pg', 'absoft', 'nag', 'vast', 'compaq', 'intele', 'intelem', 'gnu', 'g95', 'pathf95', 'nagfor']'
  customize Gnu95FCompiler
  Could not locate executable gfortran
  Could not locate executable f95
  customize IntelFCompiler
  Could not locate executable ifort
  Could not locate executable ifc
  customize LaheyFCompiler
  Could not locate executable lf95
  customize PGroupFCompiler
  Could not locate executable pgfortran
  customize AbsoftFCompiler
  Could not locate executable f90
  Could not locate executable f77
  customize NAGFCompiler
  customize VastFCompiler
  customize CompaqFCompiler
  Could not locate executable fort
  customize IntelItaniumFCompiler
  Could not locate executable efort
  Could not locate executable efc
  customize IntelEM64TFCompiler
  customize GnuFCompiler
  Could not locate executable g77
  customize G95FCompiler
  Could not locate executable g95
  customize PathScaleFCompiler
  Could not locate executable pathf95
  customize NAGFORCompiler
  Could not locate executable nagfor
  don't know how to compile Fortran code on platform 'posix'
  compiling '_configtest.c':
  
  /* This file is generated from numpy/distutils/system_info.py */
  void ATL_buildinfo(void);
  int main(void) {
    ATL_buildinfo();
    return 0;
  }
  
  C compiler: aarch64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -g -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC
  
  compile options: '-c'
  aarch64-linux-gnu-gcc: _configtest.c
  aarch64-linux-gnu-gcc -pthread _configtest.o -lf77blas -lcblas -latlas -o _configtest
  customize UnixCCompiler
  customize UnixCCompiler
    FOUND:
      language = f77
      libraries = ['lapack', 'f77blas', 'cblas', 'atlas', 'f77blas', 'cblas']
      library_dirs = ['/usr/lib/aarch64-linux-gnu']
      define_macros = [('NO_ATLAS_INFO', -1)]
  
    FOUND:
      language = f77
      libraries = ['lapack', 'f77blas', 'cblas', 'atlas', 'f77blas', 'cblas']
      library_dirs = ['/usr/lib/aarch64-linux-gnu']
      define_macros = [('NO_ATLAS_INFO', -1)]
  
  Splitting linalg.interpolative Fortran source files
  blas_opt_info:
  blas_mkl_info:
  customize UnixCCompiler
    libraries mkl_rt not found in ['/usr/local/lib', '/usr/lib', '/usr/lib/aarch64-linux-gnu']
    NOT AVAILABLE
  
  blis_info:
  customize UnixCCompiler
    libraries blis not found in ['/usr/local/lib', '/usr/lib', '/usr/lib/aarch64-linux-gnu']
    NOT AVAILABLE
  
  openblas_info:
  customize UnixCCompiler
  customize UnixCCompiler
    libraries openblas not found in ['/usr/local/lib', '/usr/lib', '/usr/lib/aarch64-linux-gnu']
    NOT AVAILABLE
  
  atlas_3_10_blas_threads_info:
  Setting PTATLAS=ATLAS
  customize UnixCCompiler
    libraries tatlas not found in ['/usr/local/lib', '/usr/lib', '/usr/lib/aarch64-linux-gnu/atlas', '/usr/lib/aarch64-linux-gnu']
    NOT AVAILABLE
  
  atlas_3_10_blas_info:
  customize UnixCCompiler
    libraries satlas not found in ['/usr/local/lib', '/usr/lib', '/usr/lib/aarch64-linux-gnu/atlas', '/usr/lib/aarch64-linux-gnu']
    NOT AVAILABLE
  
  atlas_blas_threads_info:
  Setting PTATLAS=ATLAS
  customize UnixCCompiler
    libraries ptf77blas,ptcblas,atlas not found in ['/usr/local/lib', '/usr/lib', '/usr/lib/aarch64-linux-gnu/atlas', '/usr/lib/aarch64-linux-gnu']
    NOT AVAILABLE
  
  atlas_blas_info:
  customize UnixCCompiler
  compiling '_configtest.c':
  
  /* This file is generated from numpy/distutils/system_info.py */
  void ATL_buildinfo(void);
  int main(void) {
    ATL_buildinfo();
    return 0;
  }
  
  C compiler: aarch64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -g -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC
  
  compile options: '-c'
  aarch64-linux-gnu-gcc: _configtest.c
  aarch64-linux-gnu-gcc -pthread _configtest.o -lf77blas -lcblas -latlas -o _configtest
  customize UnixCCompiler
  customize UnixCCompiler
    FOUND:
      language = c
      define_macros = [('HAVE_CBLAS', None), ('NO_ATLAS_INFO', -1)]
      libraries = ['f77blas', 'cblas', 'atlas', 'f77blas', 'cblas']
      library_dirs = ['/usr/lib/aarch64-linux-gnu']
  
    FOUND:
      language = c
      define_macros = [('HAVE_CBLAS', None), ('NO_ATLAS_INFO', -1)]
      libraries = ['f77blas', 'cblas', 'atlas', 'f77blas', 'cblas']
      library_dirs = ['/usr/lib/aarch64-linux-gnu']
  
  [makenpz] scipy/special/tests/data/boost.npz not rebuilt
  [makenpz] scipy/special/tests/data/gsl.npz not rebuilt
  [makenpz] scipy/special/tests/data/local.npz not rebuilt
  non-existing path in 'scipy/signal/windows': 'tests'
  running bdist_wheel
  running build
  running config_cc
  unifing config_cc, config, build_clib, build_ext, build commands --compiler options
  running config_fc
  unifing config_fc, config, build_clib, build_ext, build commands --fcompiler options
  running build_src
  build_src
  building py_modules sources
  building library "dfftpack" sources
  building library "fftpack" sources
  building library "mach" sources
  building library "quadpack" sources
  building library "lsoda" sources
  building library "vode" sources
  building library "dop" sources
  building library "fitpack" sources
  building library "fwrappers" sources
  building library "odrpack" sources
  building library "minpack" sources
  building library "rootfind" sources
  building library "superlu_src" sources
  building library "arpack_scipy" sources
  building library "sc_c_misc" sources
  building library "sc_cephes" sources
  building library "sc_mach" sources
  building library "sc_amos" sources
  building library "sc_cdf" sources
  building library "sc_specfun" sources
  building library "statlib" sources
  building extension "scipy.cluster._vq" sources
  building extension "scipy.cluster._hierarchy" sources
  building extension "scipy.cluster._optimal_leaf_ordering" sources
  building extension "scipy.fftpack._fftpack" sources
  f2py options: []
    adding 'build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/scipy/fftpack/fortranobject.c' to sources.
    adding 'build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/scipy/fftpack' to include_dirs.
  building extension "scipy.fftpack.convolve" sources
  f2py options: []
    adding 'build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/scipy/fftpack/fortranobject.c' to sources.
    adding 'build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/scipy/fftpack' to include_dirs.
  building extension "scipy.integrate._quadpack" sources
  building extension "scipy.integrate._odepack" sources
  building extension "scipy.integrate.vode" sources
  f2py options: []
    adding 'build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/scipy/integrate/fortranobject.c' to sources.
    adding 'build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/scipy/integrate' to include_dirs.
  building extension "scipy.integrate.lsoda" sources
  f2py options: []
    adding 'build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/scipy/integrate/fortranobject.c' to sources.
    adding 'build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/scipy/integrate' to include_dirs.
  building extension "scipy.integrate._dop" sources
  f2py options: []
    adding 'build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/scipy/integrate/fortranobject.c' to sources.
    adding 'build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/scipy/integrate' to include_dirs.
  building extension "scipy.integrate._test_multivariate" sources
  building extension "scipy.integrate._test_odeint_banded" sources
  f2py options: []
    adding 'build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/scipy/integrate/fortranobject.c' to sources.
    adding 'build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/scipy/integrate' to include_dirs.
    adding 'build/src.linux-aarch64-3.6/scipy/integrate/_test_odeint_banded-f2pywrappers.f' to sources.
  building extension "scipy.interpolate.interpnd" sources
  building extension "scipy.interpolate._ppoly" sources
  building extension "scipy.interpolate._bspl" sources
  building extension "scipy.interpolate._fitpack" sources
  building extension "scipy.interpolate.dfitpack" sources
  f2py options: []
    adding 'build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/scipy/interpolate/src/fortranobject.c' to sources.
    adding 'build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/scipy/interpolate/src' to include_dirs.
    adding 'build/src.linux-aarch64-3.6/scipy/interpolate/src/dfitpack-f2pywrappers.f' to sources.
  building extension "scipy.io._test_fortran" sources
  f2py options: []
    adding 'build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/scipy/io/fortranobject.c' to sources.
    adding 'build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/scipy/io' to include_dirs.
  building extension "scipy.io.matlab.streams" sources
  building extension "scipy.io.matlab.mio_utils" sources
  building extension "scipy.io.matlab.mio5_utils" sources
  building extension "scipy.linalg._fblas" sources
  f2py options: []
    adding 'build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/scipy/linalg/fortranobject.c' to sources.
    adding 'build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/scipy/linalg' to include_dirs.
    adding 'build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/scipy/linalg/_fblas-f2pywrappers.f' to sources.
  building extension "scipy.linalg._flapack" sources
  f2py options: []
    adding 'build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/scipy/linalg/fortranobject.c' to sources.
    adding 'build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/scipy/linalg' to include_dirs.
    adding 'build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/scipy/linalg/_flapack-f2pywrappers.f' to sources.
  building extension "scipy.linalg._flinalg" sources
  f2py options: []
    adding 'build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/scipy/linalg/fortranobject.c' to sources.
    adding 'build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/scipy/linalg' to include_dirs.
  building extension "scipy.linalg._interpolative" sources
  f2py options: []
    adding 'build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/scipy/linalg/fortranobject.c' to sources.
    adding 'build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/scipy/linalg' to include_dirs.
  building extension "scipy.linalg._solve_toeplitz" sources
  building extension "scipy.linalg.cython_blas" sources
  building extension "scipy.linalg.cython_lapack" sources
  building extension "scipy.linalg._decomp_update" sources
  building extension "scipy.odr.__odrpack" sources
  building extension "scipy.optimize._minpack" sources
  building extension "scipy.optimize._zeros" sources
  building extension "scipy.optimize._lbfgsb" sources
  f2py options: []
    adding 'build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/scipy/optimize/lbfgsb_src/fortranobject.c' to sources.
    adding 'build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/scipy/optimize/lbfgsb_src' to include_dirs.
  building extension "scipy.optimize.moduleTNC" sources
  building extension "scipy.optimize._cobyla" sources
  f2py options: []
    adding 'build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/scipy/optimize/cobyla/fortranobject.c' to sources.
    adding 'build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/scipy/optimize/cobyla' to include_dirs.
  building extension "scipy.optimize.minpack2" sources
  f2py options: []
    adding 'build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/scipy/optimize/minpack2/fortranobject.c' to sources.
    adding 'build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/scipy/optimize/minpack2' to include_dirs.
  building extension "scipy.optimize._slsqp" sources
  f2py options: []
    adding 'build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/scipy/optimize/slsqp/fortranobject.c' to sources.
    adding 'build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/scipy/optimize/slsqp' to include_dirs.
  building extension "scipy.optimize._nnls" sources
  f2py options: []
    adding 'build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/scipy/optimize/nnls/fortranobject.c' to sources.
    adding 'build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/scipy/optimize/nnls' to include_dirs.
  building extension "scipy.optimize._group_columns" sources
  building extension "scipy.optimize._bglu_dense" sources
  building extension "scipy.optimize._lsq.givens_elimination" sources
  building extension "scipy.optimize._trlib._trlib" sources
  building extension "scipy.optimize.cython_optimize._zeros" sources
  building extension "scipy.signal.sigtools" sources
  building extension "scipy.signal._spectral" sources
  building extension "scipy.signal._max_len_seq_inner" sources
  building extension "scipy.signal._peak_finding_utils" sources
  building extension "scipy.signal._upfirdn_apply" sources
  building extension "scipy.signal.spline" sources
  building extension "scipy.sparse.linalg.isolve._iterative" sources
  f2py options: []
    adding 'build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/scipy/sparse/linalg/isolve/iterative/fortranobject.c' to sources.
    adding 'build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/scipy/sparse/linalg/isolve/iterative' to include_dirs.
  building extension "scipy.sparse.linalg.dsolve._superlu" sources
  building extension "scipy.sparse.linalg.eigen.arpack._arpack" sources
  f2py options: []
    adding 'build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/scipy/sparse/linalg/eigen/arpack/fortranobject.c' to sources.
    adding 'build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/scipy/sparse/linalg/eigen/arpack' to include_dirs.
    adding 'build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/scipy/sparse/linalg/eigen/arpack/_arpack-f2pywrappers.f' to sources.
  building extension "scipy.sparse.csgraph._shortest_path" sources
  building extension "scipy.sparse.csgraph._traversal" sources
  building extension "scipy.sparse.csgraph._min_spanning_tree" sources
  building extension "scipy.sparse.csgraph._reordering" sources
  building extension "scipy.sparse.csgraph._tools" sources
  building extension "scipy.sparse._csparsetools" sources
  building extension "scipy.sparse._sparsetools" sources
  [generate_sparsetools] 'scipy/sparse/sparsetools/bsr_impl.h' already up-to-date
  [generate_sparsetools] 'scipy/sparse/sparsetools/csr_impl.h' already up-to-date
  [generate_sparsetools] 'scipy/sparse/sparsetools/csc_impl.h' already up-to-date
  [generate_sparsetools] 'scipy/sparse/sparsetools/other_impl.h' already up-to-date
  [generate_sparsetools] 'scipy/sparse/sparsetools/sparsetools_impl.h' already up-to-date
  building extension "scipy.spatial.qhull" sources
  building extension "scipy.spatial.ckdtree" sources
  building extension "scipy.spatial._distance_wrap" sources
  building extension "scipy.spatial._voronoi" sources
  building extension "scipy.spatial._hausdorff" sources
  building extension "scipy.special.specfun" sources
  f2py options: ['--no-wrap-functions']
    adding 'build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/scipy/special/fortranobject.c' to sources.
    adding 'build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/scipy/special' to include_dirs.
  building extension "scipy.special._ufuncs" sources
  building extension "scipy.special._ufuncs_cxx" sources
  building extension "scipy.special._ellip_harm_2" sources
  building extension "scipy.special.cython_special" sources
  building extension "scipy.special._comb" sources
  building extension "scipy.special._test_round" sources
  building extension "scipy.stats.statlib" sources
  f2py options: ['--no-wrap-functions']
    adding 'build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/scipy/stats/fortranobject.c' to sources.
    adding 'build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/scipy/stats' to include_dirs.
  building extension "scipy.stats._stats" sources
  building extension "scipy.stats.mvn" sources
  f2py options: []
    adding 'build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/scipy/stats/fortranobject.c' to sources.
    adding 'build/src.linux-aarch64-3.6/build/src.linux-aarch64-3.6/scipy/stats' to include_dirs.
    adding 'build/src.linux-aarch64-3.6/scipy/stats/mvn-f2pywrappers.f' to sources.
  building extension "scipy.ndimage._nd_image" sources
  building extension "scipy.ndimage._ni_label" sources
  building extension "scipy.ndimage._ctest" sources
  building extension "scipy.ndimage._ctest_oldapi" sources
  building extension "scipy.ndimage._cytest" sources
  building extension "scipy._lib._ccallback_c" sources
  building extension "scipy._lib._test_ccallback" sources
  building extension "scipy._lib._fpumode" sources
  building extension "scipy._lib.messagestream" sources
  C compiler: aarch64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -g -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC
  
  compile options: '-I/usr/include/python3.6m -c'
  aarch64-linux-gnu-gcc: _configtest.c
  aarch64-linux-gnu-gcc -pthread _configtest.o -o _configtest
  success!
  removing: _configtest.c _configtest.o _configtest.o.d _configtest
  building data_files sources
  build_src: building npy-pkg config files
  running build_py
  creating build/lib.linux-aarch64-3.6
  creating build/lib.linux-aarch64-3.6/scipy
  copying scipy/setup.py -> build/lib.linux-aarch64-3.6/scipy
  copying scipy/conftest.py -> build/lib.linux-aarch64-3.6/scipy
  copying scipy/__init__.py -> build/lib.linux-aarch64-3.6/scipy
  copying scipy/version.py -> build/lib.linux-aarch64-3.6/scipy
  copying scipy/_distributor_init.py -> build/lib.linux-aarch64-3.6/scipy
  copying build/src.linux-aarch64-3.6/scipy/__config__.py -> build/lib.linux-aarch64-3.6/scipy
  creating build/lib.linux-aarch64-3.6/scipy/cluster
  copying scipy/cluster/setup.py -> build/lib.linux-aarch64-3.6/scipy/cluster
  copying scipy/cluster/vq.py -> build/lib.linux-aarch64-3.6/scipy/cluster
  copying scipy/cluster/__init__.py -> build/lib.linux-aarch64-3.6/scipy/cluster
  copying scipy/cluster/hierarchy.py -> build/lib.linux-aarch64-3.6/scipy/cluster
  creating build/lib.linux-aarch64-3.6/scipy/constants
  copying scipy/constants/setup.py -> build/lib.linux-aarch64-3.6/scipy/constants
  copying scipy/constants/__init__.py -> build/lib.linux-aarch64-3.6/scipy/constants
  copying scipy/constants/constants.py -> build/lib.linux-aarch64-3.6/scipy/constants
  copying scipy/constants/codata.py -> build/lib.linux-aarch64-3.6/scipy/constants
  creating build/lib.linux-aarch64-3.6/scipy/fftpack
  copying scipy/fftpack/setup.py -> build/lib.linux-aarch64-3.6/scipy/fftpack
  copying scipy/fftpack/helper.py -> build/lib.linux-aarch64-3.6/scipy/fftpack
  copying scipy/fftpack/__init__.py -> build/lib.linux-aarch64-3.6/scipy/fftpack
  copying scipy/fftpack/realtransforms.py -> build/lib.linux-aarch64-3.6/scipy/fftpack
  copying scipy/fftpack/basic.py -> build/lib.linux-aarch64-3.6/scipy/fftpack
  copying scipy/fftpack/pseudo_diffs.py -> build/lib.linux-aarch64-3.6/scipy/fftpack
  creating build/lib.linux-aarch64-3.6/scipy/integrate
  copying scipy/integrate/setup.py -> build/lib.linux-aarch64-3.6/scipy/integrate
  copying scipy/integrate/__init__.py -> build/lib.linux-aarch64-3.6/scipy/integrate
  copying scipy/integrate/quadrature.py -> build/lib.linux-aarch64-3.6/scipy/integrate
  copying scipy/integrate/odepack.py -> build/lib.linux-aarch64-3.6/scipy/integrate
  copying scipy/integrate/_bvp.py -> build/lib.linux-aarch64-3.6/scipy/integrate
  copying scipy/integrate/quadpack.py -> build/lib.linux-aarch64-3.6/scipy/integrate
  copying scipy/integrate/_ode.py -> build/lib.linux-aarch64-3.6/scipy/integrate
  creating build/lib.linux-aarch64-3.6/scipy/integrate/_ivp
  copying scipy/integrate/_ivp/base.py -> build/lib.linux-aarch64-3.6/scipy/integrate/_ivp
  copying scipy/integrate/_ivp/bdf.py -> build/lib.linux-aarch64-3.6/scipy/integrate/_ivp
  copying scipy/integrate/_ivp/radau.py -> build/lib.linux-aarch64-3.6/scipy/integrate/_ivp
  copying scipy/integrate/_ivp/__init__.py -> build/lib.linux-aarch64-3.6/scipy/integrate/_ivp
  copying scipy/integrate/_ivp/common.py -> build/lib.linux-aarch64-3.6/scipy/integrate/_ivp
  copying scipy/integrate/_ivp/lsoda.py -> build/lib.linux-aarch64-3.6/scipy/integrate/_ivp
  copying scipy/integrate/_ivp/rk.py -> build/lib.linux-aarch64-3.6/scipy/integrate/_ivp
  copying scipy/integrate/_ivp/ivp.py -> build/lib.linux-aarch64-3.6/scipy/integrate/_ivp
  creating build/lib.linux-aarch64-3.6/scipy/interpolate
  copying scipy/interpolate/fitpack.py -> build/lib.linux-aarch64-3.6/scipy/interpolate
  copying scipy/interpolate/setup.py -> build/lib.linux-aarch64-3.6/scipy/interpolate
  copying scipy/interpolate/interpnd_info.py -> build/lib.linux-aarch64-3.6/scipy/interpolate
  copying scipy/interpolate/ndgriddata.py -> build/lib.linux-aarch64-3.6/scipy/interpolate
  copying scipy/interpolate/fitpack2.py -> build/lib.linux-aarch64-3.6/scipy/interpolate
  copying scipy/interpolate/interpolate.py -> build/lib.linux-aarch64-3.6/scipy/interpolate
  copying scipy/interpolate/_bsplines.py -> build/lib.linux-aarch64-3.6/scipy/interpolate
  copying scipy/interpolate/__init__.py -> build/lib.linux-aarch64-3.6/scipy/interpolate
  copying scipy/interpolate/_pade.py -> build/lib.linux-aarch64-3.6/scipy/interpolate
  copying scipy/interpolate/polyint.py -> build/lib.linux-aarch64-3.6/scipy/interpolate
  copying scipy/interpolate/rbf.py -> build/lib.linux-aarch64-3.6/scipy/interpolate
  copying scipy/interpolate/_fitpack_impl.py -> build/lib.linux-aarch64-3.6/scipy/interpolate
  copying scipy/interpolate/_cubic.py -> build/lib.linux-aarch64-3.6/scipy/interpolate
  creating build/lib.linux-aarch64-3.6/scipy/io
  copying scipy/io/netcdf.py -> build/lib.linux-aarch64-3.6/scipy/io
  copying scipy/io/setup.py -> build/lib.linux-aarch64-3.6/scipy/io
  copying scipy/io/__init__.py -> build/lib.linux-aarch64-3.6/scipy/io
  copying scipy/io/_fortran.py -> build/lib.linux-aarch64-3.6/scipy/io
  copying scipy/io/idl.py -> build/lib.linux-aarch64-3.6/scipy/io
  copying scipy/io/wavfile.py -> build/lib.linux-aarch64-3.6/scipy/io
  copying scipy/io/mmio.py -> build/lib.linux-aarch64-3.6/scipy/io
  creating build/lib.linux-aarch64-3.6/scipy/io/matlab
  copying scipy/io/matlab/mio4.py -> build/lib.linux-aarch64-3.6/scipy/io/matlab
  copying scipy/io/matlab/setup.py -> build/lib.linux-aarch64-3.6/scipy/io/matlab
  copying scipy/io/matlab/mio5_params.py -> build/lib.linux-aarch64-3.6/scipy/io/matlab
  copying scipy/io/matlab/__init__.py -> build/lib.linux-aarch64-3.6/scipy/io/matlab
  copying scipy/io/matlab/miobase.py -> build/lib.linux-aarch64-3.6/scipy/io/matlab
  copying scipy/io/matlab/mio.py -> build/lib.linux-aarch64-3.6/scipy/io/matlab
  copying scipy/io/matlab/byteordercodes.py -> build/lib.linux-aarch64-3.6/scipy/io/matlab
  copying scipy/io/matlab/mio5.py -> build/lib.linux-aarch64-3.6/scipy/io/matlab
  creating build/lib.linux-aarch64-3.6/scipy/io/arff
  copying scipy/io/arff/setup.py -> build/lib.linux-aarch64-3.6/scipy/io/arff
  copying scipy/io/arff/__init__.py -> build/lib.linux-aarch64-3.6/scipy/io/arff
  copying scipy/io/arff/arffread.py -> build/lib.linux-aarch64-3.6/scipy/io/arff
  creating build/lib.linux-aarch64-3.6/scipy/io/harwell_boeing
  copying scipy/io/harwell_boeing/_fortran_format_parser.py -> build/lib.linux-aarch64-3.6/scipy/io/harwell_boeing
  copying scipy/io/harwell_boeing/setup.py -> build/lib.linux-aarch64-3.6/scipy/io/harwell_boeing
  copying scipy/io/harwell_boeing/hb.py -> build/lib.linux-aarch64-3.6/scipy/io/harwell_boeing
  copying scipy/io/harwell_boeing/__init__.py -> build/lib.linux-aarch64-3.6/scipy/io/harwell_boeing
  creating build/lib.linux-aarch64-3.6/scipy/linalg
  copying scipy/linalg/setup.py -> build/lib.linux-aarch64-3.6/scipy/linalg
  copying scipy/linalg/decomp_svd.py -> build/lib.linux-aarch64-3.6/scipy/linalg
  copying scipy/linalg/decomp_qr.py -> build/lib.linux-aarch64-3.6/scipy/linalg
  copying scipy/linalg/_decomp_qz.py -> build/lib.linux-aarch64-3.6/scipy/linalg
  copying scipy/linalg/decomp_lu.py -> build/lib.linux-aarch64-3.6/scipy/linalg
  copying scipy/linalg/decomp.py -> build/lib.linux-aarch64-3.6/scipy/linalg
  copying scipy/linalg/misc.py -> build/lib.linux-aarch64-3.6/scipy/linalg
  copying scipy/linalg/flinalg.py -> build/lib.linux-aarch64-3.6/scipy/linalg
  copying scipy/linalg/_sketches.py -> build/lib.linux-aarch64-3.6/scipy/linalg
  copying scipy/linalg/_testutils.py -> build/lib.linux-aarch64-3.6/scipy/linalg
  copying scipy/linalg/_generate_pyx.py -> build/lib.linux-aarch64-3.6/scipy/linalg
  copying scipy/linalg/linalg_version.py -> build/lib.linux-aarch64-3.6/scipy/linalg
  copying scipy/linalg/_matfuncs_inv_ssq.py -> build/lib.linux-aarch64-3.6/scipy/linalg
  copying scipy/linalg/interpolative.py -> build/lib.linux-aarch64-3.6/scipy/linalg
  copying scipy/linalg/__init__.py -> build/lib.linux-aarch64-3.6/scipy/linalg
  copying scipy/linalg/blas.py -> build/lib.linux-aarch64-3.6/scipy/linalg
  copying scipy/linalg/_cython_signature_generator.py -> build/lib.linux-aarch64-3.6/scipy/linalg
  copying scipy/linalg/_decomp_ldl.py -> build/lib.linux-aarch64-3.6/scipy/linalg
  copying scipy/linalg/_decomp_polar.py -> build/lib.linux-aarch64-3.6/scipy/linalg
  copying scipy/linalg/special_matrices.py -> build/lib.linux-aarch64-3.6/scipy/linalg
  copying scipy/linalg/_interpolative_backend.py -> build/lib.linux-aarch64-3.6/scipy/linalg
  copying scipy/linalg/_expm_frechet.py -> build/lib.linux-aarch64-3.6/scipy/linalg
  copying scipy/linalg/matfuncs.py -> build/lib.linux-aarch64-3.6/scipy/linalg
  copying scipy/linalg/decomp_cholesky.py -> build/lib.linux-aarch64-3.6/scipy/linalg
  copying scipy/linalg/_procrustes.py -> build/lib.linux-aarch64-3.6/scipy/linalg
  copying scipy/linalg/_solvers.py -> build/lib.linux-aarch64-3.6/scipy/linalg
  copying scipy/linalg/basic.py -> build/lib.linux-aarch64-3.6/scipy/linalg
  copying scipy/linalg/decomp_schur.py -> build/lib.linux-aarch64-3.6/scipy/linalg
  copying scipy/linalg/_matfuncs_sqrtm.py -> build/lib.linux-aarch64-3.6/scipy/linalg
  copying scipy/linalg/lapack.py -> build/lib.linux-aarch64-3.6/scipy/linalg
  creating build/lib.linux-aarch64-3.6/scipy/misc
  copying scipy/misc/setup.py -> build/lib.linux-aarch64-3.6/scipy/misc
  copying scipy/misc/__init__.py -> build/lib.linux-aarch64-3.6/scipy/misc
  copying scipy/misc/common.py -> build/lib.linux-aarch64-3.6/scipy/misc
  copying scipy/misc/doccer.py -> build/lib.linux-aarch64-3.6/scipy/misc
  creating build/lib.linux-aarch64-3.6/scipy/odr
  copying scipy/odr/setup.py -> build/lib.linux-aarch64-3.6/scipy/odr
  copying scipy/odr/odrpack.py -> build/lib.linux-aarch64-3.6/scipy/odr
  copying scipy/odr/__init__.py -> build/lib.linux-aarch64-3.6/scipy/odr
  copying scipy/odr/models.py -> build/lib.linux-aarch64-3.6/scipy/odr
  copying scipy/odr/add_newdocs.py -> build/lib.linux-aarch64-3.6/scipy/odr
  creating build/lib.linux-aarch64-3.6/scipy/optimize
  copying scipy/optimize/_trustregion_exact.py -> build/lib.linux-aarch64-3.6/scipy/optimize
  copying scipy/optimize/_shgo.py -> build/lib.linux-aarch64-3.6/scipy/optimize
  copying scipy/optimize/_trustregion_ncg.py -> build/lib.linux-aarch64-3.6/scipy/optimize
  copying scipy/optimize/_remove_redundancy.py -> build/lib.linux-aarch64-3.6/scipy/optimize
  copying scipy/optimize/setup.py -> build/lib.linux-aarch64-3.6/scipy/optimize
  copying scipy/optimize/_constraints.py -> build/lib.linux-aarch64-3.6/scipy/optimize
  copying scipy/optimize/_tstutils.py -> build/lib.linux-aarch64-3.6/scipy/optimize
  copying scipy/optimize/_trustregion_krylov.py -> build/lib.linux-aarch64-3.6/scipy/optimize
  copying scipy/optimize/_hessian_update_strategy.py -> build/lib.linux-aarch64-3.6/scipy/optimize
  copying scipy/optimize/nnls.py -> build/lib.linux-aarch64-3.6/scipy/optimize
  copying scipy/optimize/__init__.py -> build/lib.linux-aarch64-3.6/scipy/optimize
  copying scipy/optimize/zeros.py -> build/lib.linux-aarch64-3.6/scipy/optimize
  copying scipy/optimize/_differentialevolution.py -> build/lib.linux-aarch64-3.6/scipy/optimize
  copying scipy/optimize/_numdiff.py -> build/lib.linux-aarch64-3.6/scipy/optimize
  copying scipy/optimize/_linprog.py -> build/lib.linux-aarch64-3.6/scipy/optimize
  copying scipy/optimize/tnc.py -> build/lib.linux-aarch64-3.6/scipy/optimize
  copying scipy/optimize/linesearch.py -> build/lib.linux-aarch64-3.6/scipy/optimize
  copying scipy/optimize/_linprog_util.py -> build/lib.linux-aarch64-3.6/scipy/optimize
  copying scipy/optimize/_linprog_simplex.py -> build/lib.linux-aarch64-3.6/scipy/optimize
  copying scipy/optimize/slsqp.py -> build/lib.linux-aarch64-3.6/scipy/optimize
  copying scipy/optimize/minpack.py -> build/lib.linux-aarch64-3.6/scipy/optimize
  copying scipy/optimize/lbfgsb.py -> build/lib.linux-aarch64-3.6/scipy/optimize
  copying scipy/optimize/_linprog_rs.py -> build/lib.linux-aarch64-3.6/scipy/optimize
  copying scipy/optimize/_linprog_ip.py -> build/lib.linux-aarch64-3.6/scipy/optimize
  copying scipy/optimize/optimize.py -> build/lib.linux-aarch64-3.6/scipy/optimize
  copying scipy/optimize/_dual_annealing.py -> build/lib.linux-aarch64-3.6/scipy/optimize
  copying scipy/optimize/_spectral.py -> build/lib.linux-aarch64-3.6/scipy/optimize
  copying scipy/optimize/_basinhopping.py -> build/lib.linux-aarch64-3.6/scipy/optimize
  copying scipy/optimize/_differentiable_functions.py -> build/lib.linux-aarch64-3.6/scipy/optimize
  copying scipy/optimize/cobyla.py -> build/lib.linux-aarch64-3.6/scipy/optimize
  copying scipy/optimize/_root_scalar.py -> build/lib.linux-aarch64-3.6/scipy/optimize
  copying scipy/optimize/_trustregion.py -> build/lib.linux-aarch64-3.6/scipy/optimize
  copying scipy/optimize/nonlin.py -> build/lib.linux-aarch64-3.6/scipy/optimize
  copying scipy/optimize/_minimize.py -> build/lib.linux-aarch64-3.6/scipy/optimize
  copying scipy/optimize/_trustregion_dogleg.py -> build/lib.linux-aarch64-3.6/scipy/optimize
  copying scipy/optimize/_hungarian.py -> build/lib.linux-aarch64-3.6/scipy/optimize
  copying scipy/optimize/_root.py -> build/lib.linux-aarch64-3.6/scipy/optimize
  creating build/lib.linux-aarch64-3.6/scipy/optimize/_lsq
  copying scipy/optimize/_lsq/setup.py -> build/lib.linux-aarch64-3.6/scipy/optimize/_lsq
  copying scipy/optimize/_lsq/trf.py -> build/lib.linux-aarch64-3.6/scipy/optimize/_lsq
  copying scipy/optimize/_lsq/lsq_linear.py -> build/lib.linux-aarch64-3.6/scipy/optimize/_lsq
  copying scipy/optimize/_lsq/__init__.py -> build/lib.linux-aarch64-3.6/scipy/optimize/_lsq
  copying scipy/optimize/_lsq/dogbox.py -> build/lib.linux-aarch64-3.6/scipy/optimize/_lsq
  copying scipy/optimize/_lsq/common.py -> build/lib.linux-aarch64-3.6/scipy/optimize/_lsq
  copying scipy/optimize/_lsq/least_squares.py -> build/lib.linux-aarch64-3.6/scipy/optimize/_lsq
  copying scipy/optimize/_lsq/bvls.py -> build/lib.linux-aarch64-3.6/scipy/optimize/_lsq
  copying scipy/optimize/_lsq/trf_linear.py -> build/lib.linux-aarch64-3.6/scipy/optimize/_lsq
  creating build/lib.linux-aarch64-3.6/scipy/optimize/_trlib
  copying scipy/optimize/_trlib/setup.py -> build/lib.linux-aarch64-3.6/scipy/optimize/_trlib
  copying scipy/optimize/_trlib/__init__.py -> build/lib.linux-aarch64-3.6/scipy/optimize/_trlib
  creating build/lib.linux-aarch64-3.6/scipy/optimize/_trustregion_constr
  copying scipy/optimize/_trustregion_constr/setup.py -> build/lib.linux-aarch64-3.6/scipy/optimize/_trustregion_constr
  copying scipy/optimize/_trustregion_constr/equality_constrained_sqp.py -> build/lib.linux-aarch64-3.6/scipy/optimize/_trustregion_constr
  copying scipy/optimize/_trustregion_constr/tr_interior_point.py -> build/lib.linux-aarch64-3.6/scipy/optimize/_trustregion_constr
  copying scipy/optimize/_trustregion_constr/projections.py -> build/lib.linux-aarch64-3.6/scipy/optimize/_trustregion_constr
  copying scipy/optimize/_trustregion_constr/__init__.py -> build/lib.linux-aarch64-3.6/scipy/optimize/_trustregion_constr
  copying scipy/optimize/_trustregion_constr/report.py -> build/lib.linux-aarch64-3.6/scipy/optimize/_trustregion_constr
  copying scipy/optimize/_trustregion_constr/minimize_trustregion_constr.py -> build/lib.linux-aarch64-3.6/scipy/optimize/_trustregion_constr
  copying scipy/optimize/_trustregion_constr/qp_subproblem.py -> build/lib.linux-aarch64-3.6/scipy/optimize/_trustregion_constr
  copying scipy/optimize/_trustregion_constr/canonical_constraint.py -> build/lib.linux-aarch64-3.6/scipy/optimize/_trustregion_constr
  creating build/lib.linux-aarch64-3.6/scipy/optimize/cython_optimize
  copying scipy/optimize/cython_optimize/__init__.py -> build/lib.linux-aarch64-3.6/scipy/optimize/cython_optimize
  creating build/lib.linux-aarch64-3.6/scipy/optimize/_shgo_lib
  copying scipy/optimize/_shgo_lib/__init__.py -> build/lib.linux-aarch64-3.6/scipy/optimize/_shgo_lib
  copying scipy/optimize/_shgo_lib/triangulation.py -> build/lib.linux-aarch64-3.6/scipy/optimize/_shgo_lib
  copying scipy/optimize/_shgo_lib/sobol_seq.py -> build/lib.linux-aarch64-3.6/scipy/optimize/_shgo_lib
  creating build/lib.linux-aarch64-3.6/scipy/signal
  copying scipy/signal/_max_len_seq.py -> build/lib.linux-aarch64-3.6/scipy/signal
  copying scipy/signal/setup.py -> build/lib.linux-aarch64-3.6/scipy/signal
  copying scipy/signal/_peak_finding.py -> build/lib.linux-aarch64-3.6/scipy/signal
  copying scipy/signal/wavelets.py -> build/lib.linux-aarch64-3.6/scipy/signal
  copying scipy/signal/bsplines.py -> build/lib.linux-aarch64-3.6/scipy/signal
  copying scipy/signal/__init__.py -> build/lib.linux-aarch64-3.6/scipy/signal
  copying scipy/signal/filter_design.py -> build/lib.linux-aarch64-3.6/scipy/signal
  copying scipy/signal/spectral.py -> build/lib.linux-aarch64-3.6/scipy/signal
  copying scipy/signal/lti_conversion.py -> build/lib.linux-aarch64-3.6/scipy/signal
  copying scipy/signal/_arraytools.py -> build/lib.linux-aarch64-3.6/scipy/signal
  copying scipy/signal/waveforms.py -> build/lib.linux-aarch64-3.6/scipy/signal
  copying scipy/signal/_savitzky_golay.py -> build/lib.linux-aarch64-3.6/scipy/signal
  copying scipy/signal/ltisys.py -> build/lib.linux-aarch64-3.6/scipy/signal
  copying scipy/signal/signaltools.py -> build/lib.linux-aarch64-3.6/scipy/signal
  copying scipy/signal/_upfirdn.py -> build/lib.linux-aarch64-3.6/scipy/signal
  copying scipy/signal/fir_filter_design.py -> build/lib.linux-aarch64-3.6/scipy/signal
  creating build/lib.linux-aarch64-3.6/scipy/signal/windows
  copying scipy/signal/windows/setup.py -> build/lib.linux-aarch64-3.6/scipy/signal/windows
  copying scipy/signal/windows/__init__.py -> build/lib.linux-aarch64-3.6/scipy/signal/windows
  copying scipy/signal/windows/windows.py -> build/lib.linux-aarch64-3.6/scipy/signal/windows
  creating build/lib.linux-aarch64-3.6/scipy/sparse
  copying scipy/sparse/base.py -> build/lib.linux-aarch64-3.6/scipy/sparse
  copying scipy/sparse/dok.py -> build/lib.linux-aarch64-3.6/scipy/sparse
  copying scipy/sparse/bsr.py -> build/lib.linux-aarch64-3.6/scipy/sparse
  copying scipy/sparse/setup.py -> build/lib.linux-aarch64-3.6/scipy/sparse
  copying scipy/sparse/__init__.py -> build/lib.linux-aarch64-3.6/scipy/sparse
  copying scipy/sparse/lil.py -> build/lib.linux-aarch64-3.6/scipy/sparse
  copying scipy/sparse/sputils.py -> build/lib.linux-aarch64-3.6/scipy/sparse
  copying scipy/sparse/sparsetools.py -> build/lib.linux-aarch64-3.6/scipy/sparse
  copying scipy/sparse/coo.py -> build/lib.linux-aarch64-3.6/scipy/sparse
  copying scipy/sparse/csr.py -> build/lib.linux-aarch64-3.6/scipy/sparse
  copying scipy/sparse/data.py -> build/lib.linux-aarch64-3.6/scipy/sparse
  copying scipy/sparse/generate_sparsetools.py -> build/lib.linux-aarch64-3.6/scipy/sparse
  copying scipy/sparse/dia.py -> build/lib.linux-aarch64-3.6/scipy/sparse
  copying scipy/sparse/spfuncs.py -> build/lib.linux-aarch64-3.6/scipy/sparse
  copying scipy/sparse/csc.py -> build/lib.linux-aarch64-3.6/scipy/sparse
  copying scipy/sparse/compressed.py -> build/lib.linux-aarch64-3.6/scipy/sparse
  copying scipy/sparse/extract.py -> build/lib.linux-aarch64-3.6/scipy/sparse
  copying scipy/sparse/construct.py -> build/lib.linux-aarch64-3.6/scipy/sparse
  copying scipy/sparse/_index.py -> build/lib.linux-aarch64-3.6/scipy/sparse
  copying scipy/sparse/_matrix_io.py -> build/lib.linux-aarch64-3.6/scipy/sparse
  creating build/lib.linux-aarch64-3.6/scipy/sparse/linalg
  copying scipy/sparse/linalg/_expm_multiply.py -> build/lib.linux-aarch64-3.6/scipy/sparse/linalg
  copying scipy/sparse/linalg/setup.py -> build/lib.linux-aarch64-3.6/scipy/sparse/linalg
  copying scipy/sparse/linalg/__init__.py -> build/lib.linux-aarch64-3.6/scipy/sparse/linalg
  copying scipy/sparse/linalg/matfuncs.py -> build/lib.linux-aarch64-3.6/scipy/sparse/linalg
  copying scipy/sparse/linalg/interface.py -> build/lib.linux-aarch64-3.6/scipy/sparse/linalg
  copying scipy/sparse/linalg/_norm.py -> build/lib.linux-aarch64-3.6/scipy/sparse/linalg
  copying scipy/sparse/linalg/_onenormest.py -> build/lib.linux-aarch64-3.6/scipy/sparse/linalg
  creating build/lib.linux-aarch64-3.6/scipy/sparse/linalg/isolve
  copying scipy/sparse/linalg/isolve/setup.py -> build/lib.linux-aarch64-3.6/scipy/sparse/linalg/isolve
  copying scipy/sparse/linalg/isolve/minres.py -> build/lib.linux-aarch64-3.6/scipy/sparse/linalg/isolve
  copying scipy/sparse/linalg/isolve/__init__.py -> build/lib.linux-aarch64-3.6/scipy/sparse/linalg/isolve
  copying scipy/sparse/linalg/isolve/_gcrotmk.py -> build/lib.linux-aarch64-3.6/scipy/sparse/linalg/isolve
  copying scipy/sparse/linalg/isolve/iterative.py -> build/lib.linux-aarch64-3.6/scipy/sparse/linalg/isolve
  copying scipy/sparse/linalg/isolve/lsmr.py -> build/lib.linux-aarch64-3.6/scipy/sparse/linalg/isolve
  copying scipy/sparse/linalg/isolve/lgmres.py -> build/lib.linux-aarch64-3.6/scipy/sparse/linalg/isolve
  copying scipy/sparse/linalg/isolve/lsqr.py -> build/lib.linux-aarch64-3.6/scipy/sparse/linalg/isolve
  copying scipy/sparse/linalg/isolve/utils.py -> build/lib.linux-aarch64-3.6/scipy/sparse/linalg/isolve
  creating build/lib.linux-aarch64-3.6/scipy/sparse/linalg/dsolve
  copying scipy/sparse/linalg/dsolve/setup.py -> build/lib.linux-aarch64-3.6/scipy/sparse/linalg/dsolve
  copying scipy/sparse/linalg/dsolve/_add_newdocs.py -> build/lib.linux-aarch64-3.6/scipy/sparse/linalg/dsolve
  copying scipy/sparse/linalg/dsolve/__init__.py -> build/lib.linux-aarch64-3.6/scipy/sparse/linalg/dsolve
  copying scipy/sparse/linalg/dsolve/linsolve.py -> build/lib.linux-aarch64-3.6/scipy/sparse/linalg/dsolve
  creating build/lib.linux-aarch64-3.6/scipy/sparse/linalg/eigen
  copying scipy/sparse/linalg/eigen/setup.py -> build/lib.linux-aarch64-3.6/scipy/sparse/linalg/eigen
  copying scipy/sparse/linalg/eigen/__init__.py -> build/lib.linux-aarch64-3.6/scipy/sparse/linalg/eigen
  creating build/lib.linux-aarch64-3.6/scipy/sparse/linalg/eigen/arpack
  copying scipy/sparse/linalg/eigen/arpack/setup.py -> build/lib.linux-aarch64-3.6/scipy/sparse/linalg/eigen/arpack
  copying scipy/sparse/linalg/eigen/arpack/arpack.py -> build/lib.linux-aarch64-3.6/scipy/sparse/linalg/eigen/arpack
  copying scipy/sparse/linalg/eigen/arpack/__init__.py -> build/lib.linux-aarch64-3.6/scipy/sparse/linalg/eigen/arpack
  creating build/lib.linux-aarch64-3.6/scipy/sparse/linalg/eigen/lobpcg
  copying scipy/sparse/linalg/eigen/lobpcg/setup.py -> build/lib.linux-aarch64-3.6/scipy/sparse/linalg/eigen/lobpcg
  copying scipy/sparse/linalg/eigen/lobpcg/__init__.py -> build/lib.linux-aarch64-3.6/scipy/sparse/linalg/eigen/lobpcg
  copying scipy/sparse/linalg/eigen/lobpcg/lobpcg.py -> build/lib.linux-aarch64-3.6/scipy/sparse/linalg/eigen/lobpcg
  creating build/lib.linux-aarch64-3.6/scipy/sparse/csgraph
  copying scipy/sparse/csgraph/setup.py -> build/lib.linux-aarch64-3.6/scipy/sparse/csgraph
  copying scipy/sparse/csgraph/_laplacian.py -> build/lib.linux-aarch64-3.6/scipy/sparse/csgraph
  copying scipy/sparse/csgraph/__init__.py -> build/lib.linux-aarch64-3.6/scipy/sparse/csgraph
  copying scipy/sparse/csgraph/_validation.py -> build/lib.linux-aarch64-3.6/scipy/sparse/csgraph
  creating build/lib.linux-aarch64-3.6/scipy/spatial
  copying scipy/spatial/setup.py -> build/lib.linux-aarch64-3.6/scipy/spatial
  copying scipy/spatial/__init__.py -> build/lib.linux-aarch64-3.6/scipy/spatial
  copying scipy/spatial/_plotutils.py -> build/lib.linux-aarch64-3.6/scipy/spatial
  copying scipy/spatial/_spherical_voronoi.py -> build/lib.linux-aarch64-3.6/scipy/spatial
  copying scipy/spatial/_procrustes.py -> build/lib.linux-aarch64-3.6/scipy/spatial
  copying scipy/spatial/distance.py -> build/lib.linux-aarch64-3.6/scipy/spatial
  copying scipy/spatial/kdtree.py -> build/lib.linux-aarch64-3.6/scipy/spatial
  creating build/lib.linux-aarch64-3.6/scipy/spatial/transform
  copying scipy/spatial/transform/setup.py -> build/lib.linux-aarch64-3.6/scipy/spatial/transform
  copying scipy/spatial/transform/rotation.py -> build/lib.linux-aarch64-3.6/scipy/spatial/transform
  copying scipy/spatial/transform/_rotation_spline.py -> build/lib.linux-aarch64-3.6/scipy/spatial/transform
  copying scipy/spatial/transform/__init__.py -> build/lib.linux-aarch64-3.6/scipy/spatial/transform
  creating build/lib.linux-aarch64-3.6/scipy/special
  copying scipy/special/_mptestutils.py -> build/lib.linux-aarch64-3.6/scipy/special
  copying scipy/special/setup.py -> build/lib.linux-aarch64-3.6/scipy/special
  copying scipy/special/lambertw.py -> build/lib.linux-aarch64-3.6/scipy/special
  copying scipy/special/_testutils.py -> build/lib.linux-aarch64-3.6/scipy/special
  copying scipy/special/_generate_pyx.py -> build/lib.linux-aarch64-3.6/scipy/special
  copying scipy/special/__init__.py -> build/lib.linux-aarch64-3.6/scipy/special
  copying scipy/special/sf_error.py -> build/lib.linux-aarch64-3.6/scipy/special
  copying scipy/special/_logsumexp.py -> build/lib.linux-aarch64-3.6/scipy/special
  copying scipy/special/_spherical_bessel.py -> build/lib.linux-aarch64-3.6/scipy/special
  copying scipy/special/_ellip_harm.py -> build/lib.linux-aarch64-3.6/scipy/special
  copying scipy/special/orthogonal.py -> build/lib.linux-aarch64-3.6/scipy/special
  copying scipy/special/basic.py -> build/lib.linux-aarch64-3.6/scipy/special
  copying scipy/special/add_newdocs.py -> build/lib.linux-aarch64-3.6/scipy/special
  copying scipy/special/spfun_stats.py -> build/lib.linux-aarch64-3.6/scipy/special
  creating build/lib.linux-aarch64-3.6/scipy/special/_precompute
  copying scipy/special/_precompute/setup.py -> build/lib.linux-aarch64-3.6/scipy/special/_precompute
  copying scipy/special/_precompute/gammainc_asy.py -> build/lib.linux-aarch64-3.6/scipy/special/_precompute
  copying scipy/special/_precompute/lambertw.py -> build/lib.linux-aarch64-3.6/scipy/special/_precompute
  copying scipy/special/_precompute/__init__.py -> build/lib.linux-aarch64-3.6/scipy/special/_precompute
  copying scipy/special/_precompute/expn_asy.py -> build/lib.linux-aarch64-3.6/scipy/special/_precompute
  copying scipy/special/_precompute/loggamma.py -> build/lib.linux-aarch64-3.6/scipy/special/_precompute
  copying scipy/special/_precompute/zetac.py -> build/lib.linux-aarch64-3.6/scipy/special/_precompute
  copying scipy/special/_precompute/struve_convergence.py -> build/lib.linux-aarch64-3.6/scipy/special/_precompute
  copying scipy/special/_precompute/gammainc_data.py -> build/lib.linux-aarch64-3.6/scipy/special/_precompute
  copying scipy/special/_precompute/utils.py -> build/lib.linux-aarch64-3.6/scipy/special/_precompute
  creating build/lib.linux-aarch64-3.6/scipy/stats
  copying scipy/stats/_stats_mstats_common.py -> build/lib.linux-aarch64-3.6/scipy/stats
  copying scipy/stats/setup.py -> build/lib.linux-aarch64-3.6/scipy/stats
  copying scipy/stats/_distr_params.py -> build/lib.linux-aarch64-3.6/scipy/stats
  copying scipy/stats/stats.py -> build/lib.linux-aarch64-3.6/scipy/stats
  copying scipy/stats/__init__.py -> build/lib.linux-aarch64-3.6/scipy/stats
  copying scipy/stats/mstats_extras.py -> build/lib.linux-aarch64-3.6/scipy/stats
  copying scipy/stats/kde.py -> build/lib.linux-aarch64-3.6/scipy/stats
  copying scipy/stats/_multivariate.py -> build/lib.linux-aarch64-3.6/scipy/stats
  copying scipy/stats/_distn_infrastructure.py -> build/lib.linux-aarch64-3.6/scipy/stats
  copying scipy/stats/mstats.py -> build/lib.linux-aarch64-3.6/scipy/stats
  copying scipy/stats/_discrete_distns.py -> build/lib.linux-aarch64-3.6/scipy/stats
  copying scipy/stats/_constants.py -> build/lib.linux-aarch64-3.6/scipy/stats
  copying scipy/stats/_rvs_sampling.py -> build/lib.linux-aarch64-3.6/scipy/stats
  copying scipy/stats/distributions.py -> build/lib.linux-aarch64-3.6/scipy/stats
  copying scipy/stats/_binned_statistic.py -> build/lib.linux-aarch64-3.6/scipy/stats
  copying scipy/stats/_hypotests.py -> build/lib.linux-aarch64-3.6/scipy/stats
  copying scipy/stats/mstats_basic.py -> build/lib.linux-aarch64-3.6/scipy/stats
  copying scipy/stats/morestats.py -> build/lib.linux-aarch64-3.6/scipy/stats
  copying scipy/stats/vonmises.py -> build/lib.linux-aarch64-3.6/scipy/stats
  copying scipy/stats/_continuous_distns.py -> build/lib.linux-aarch64-3.6/scipy/stats
  copying scipy/stats/contingency.py -> build/lib.linux-aarch64-3.6/scipy/stats
  copying scipy/stats/_tukeylambda_stats.py -> build/lib.linux-aarch64-3.6/scipy/stats
  creating build/lib.linux-aarch64-3.6/scipy/ndimage
  copying scipy/ndimage/setup.py -> build/lib.linux-aarch64-3.6/scipy/ndimage
  copying scipy/ndimage/fourier.py -> build/lib.linux-aarch64-3.6/scipy/ndimage
  copying scipy/ndimage/morphology.py -> build/lib.linux-aarch64-3.6/scipy/ndimage
  copying scipy/ndimage/__init__.py -> build/lib.linux-aarch64-3.6/scipy/ndimage
  copying scipy/ndimage/measurements.py -> build/lib.linux-aarch64-3.6/scipy/ndimage
  copying scipy/ndimage/_ni_docstrings.py -> build/lib.linux-aarch64-3.6/scipy/ndimage
  copying scipy/ndimage/_ni_support.py -> build/lib.linux-aarch64-3.6/scipy/ndimage
  copying scipy/ndimage/interpolation.py -> build/lib.linux-aarch64-3.6/scipy/ndimage
  copying scipy/ndimage/filters.py -> build/lib.linux-aarch64-3.6/scipy/ndimage
  creating build/lib.linux-aarch64-3.6/scipy/_build_utils
  copying scipy/_build_utils/__init__.py -> build/lib.linux-aarch64-3.6/scipy/_build_utils
  copying scipy/_build_utils/_fortran.py -> build/lib.linux-aarch64-3.6/scipy/_build_utils
  copying scipy/_build_utils/system_info.py -> build/lib.linux-aarch64-3.6/scipy/_build_utils
  creating build/lib.linux-aarch64-3.6/scipy/_lib
  copying scipy/_lib/setup.py -> build/lib.linux-aarch64-3.6/scipy/_lib
  copying scipy/_lib/_tmpdirs.py -> build/lib.linux-aarch64-3.6/scipy/_lib
  copying scipy/_lib/_gcutils.py -> build/lib.linux-aarch64-3.6/scipy/_lib
  copying scipy/_lib/decorator.py -> build/lib.linux-aarch64-3.6/scipy/_lib
  copying scipy/_lib/_testutils.py -> build/lib.linux-aarch64-3.6/scipy/_lib
  copying scipy/_lib/__init__.py -> build/lib.linux-aarch64-3.6/scipy/_lib
  copying scipy/_lib/_numpy_compat.py -> build/lib.linux-aarch64-3.6/scipy/_lib
  copying scipy/_lib/_threadsafety.py -> build/lib.linux-aarch64-3.6/scipy/_lib
  copying scipy/_lib/six.py -> build/lib.linux-aarch64-3.6/scipy/_lib
  copying scipy/_lib/doccer.py -> build/lib.linux-aarch64-3.6/scipy/_lib
  copying scipy/_lib/_util.py -> build/lib.linux-aarch64-3.6/scipy/_lib
  copying scipy/_lib/_version.py -> build/lib.linux-aarch64-3.6/scipy/_lib
  copying scipy/_lib/_ccallback.py -> build/lib.linux-aarch64-3.6/scipy/_lib
  running build_clib
  customize UnixCCompiler
  customize UnixCCompiler using build_clib
  building 'dfftpack' library
  Running from scipy source directory.
  /usr/local/lib/python3.6/dist-packages/numpy/distutils/system_info.py:782: UserWarning: Specified path /usr/local/include/python3.6m is invalid.
    return self.get_paths(self.section, key)
  error: library dfftpack has Fortran sources but no Fortran compiler found
  ----------------------------------------
  ERROR: Failed building wheel for scipy
  Running setup.py clean for scipy
  ERROR: Command errored out with exit status 1:
   command: /usr/bin/python3 -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-igqt1qhy/scipy/setup.py'"'"'; __file__='"'"'/tmp/pip-install-igqt1qhy/scipy/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' clean --all
       cwd: /tmp/pip-install-igqt1qhy/scipy
  Complete output (9 lines):
  
  `setup.py clean` is not supported, use one of the following instead:
  
    - `git clean -xdf` (cleans all files)
    - `git clean -Xdf` (cleans all versioned files, doesn't touch
                        files that aren't checked into the git repo)
  
  Add `--force` to your command to use it anyway if you must (unsupported).
  
  ----------------------------------------
  ERROR: Failed cleaning build dir for scipy
Failed to build scipy
ERROR: Could not build wheels for scipy which use PEP 517 and cannot be installed directly

What I tried:

apt-get update
apt-get upgrade

My guess is that gfortran needs to be installed, however

apt-get install gfortran

yields

Reading package lists... Done
Building dependency tree       
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
 gfortran : Depends: gfortran-7 (>= 7.3.0-12~) but it is not going to be installed
E: Unable to correct problems, you have held broken packages.

Maybe gfortran is already installed, but pip cannot find it. Anyway, there is a file

usr/bin/gfortran5

My etc/apt/sources.list reads

# See http://help.ubuntu.com/community/UpgradeNotes for how to upgrade to
# newer versions of the distribution.
# deb-src http://ports.ubuntu.com/ubuntu-ports/ bionic main restricted

## Major bug fix updates produced after the final release of the
## distribution.
# deb-src http://ports.ubuntu.com/ubuntu-ports/ bionic-updates main restricted

## N.B. software from this repository is ENTIRELY UNSUPPORTED by the Ubuntu
## team. Also, please note that software in universe WILL NOT receive any
## review or updates from the Ubuntu security team.
# deb-src http://ports.ubuntu.com/ubuntu-ports/ bionic universe
# deb-src http://ports.ubuntu.com/ubuntu-ports/ bionic-updates universe

## N.B. software from this repository is ENTIRELY UNSUPPORTED by the Ubuntu
## team, and may not be under a free licence. Please satisfy yourself as to
## your rights to use the software. Also, please note that software in
## multiverse WILL NOT receive any review or updates from the Ubuntu
## security team.
# deb-src http://ports.ubuntu.com/ubuntu-ports/ bionic multiverse
# deb-src http://ports.ubuntu.com/ubuntu-ports/ bionic-updates multiverse

## N.B. software from this repository may not have been tested as
## extensively as that contained in the main release, although it includes
## newer versions of some applications which may provide useful features.
## Also, please note that software in backports WILL NOT receive any review
## or updates from the Ubuntu security team.
# deb-src http://ports.ubuntu.com/ubuntu-ports/ bionic-backports main restricted universe$

## Uncomment the following two lines to add software from Canonical's
## 'partner' repository.
## This software is not part of Ubuntu, but is offered by Canonical and the
## respective vendors as a service to Ubuntu users.
deb http://archive.canonical.com/ubuntu bionic partner
# deb-src http://archive.canonical.com/ubuntu bionic partner

# deb-src http://ports.ubuntu.com/ubuntu-ports/ bionic-security main restricted
# deb-src http://ports.ubuntu.com/ubuntu-ports/ bionic-security universe
# deb-src http://ports.ubuntu.com/ubuntu-ports/ bionic-security multiverse
deb http://ports.ubuntu.com/ubuntu-ports/ bionic main universe

System:

  • ubuntu 18.04 LTS on Jetson AGX Xavier
  • Fresh installed OS image using the SDK-Manager

Any help highly appreciated!

Lorenz

Update:

Indeed, gfortran-5 is installed, because

gfortran-5 -v

outputs

Using built-in specs.
COLLECT_GCC=gfortran-5
COLLECT_LTO_WRAPPER=/usr/lib/gcc/aarch64-linux-gnu/5/lto-wrapper
Target: aarch64-linux-gnu
Configured with: ../src/configure -v --with-pkgversion='Ubuntu/Linaro 5.5.0-12ubuntu1' --with-bugurl=file:///usr/share/doc/gcc-5/README.Bugs --enable-languages=c,ada,c++,go,d,fortran,objc,obj-c++ --prefix=/usr --program-suffix=-5 --enable-shared --enable-linker-build-id --libexecdir=/usr/lib --without-included-gettext --enable-threads=posix --libdir=/usr/lib --enable-nls --with-sysroot=/ --enable-clocale=gnu --enable-libstdcxx-debug --enable-libstdcxx-time=yes --with-default-libstdcxx-abi=new --enable-gnu-unique-object --disable-libquadmath --enable-plugin --enable-default-pie --with-system-zlib --enable-multiarch --enable-fix-cortex-a53-843419 --disable-werror --enable-checking=release --build=aarch64-linux-gnu --host=aarch64-linux-gnu --target=aarch64-linux-gnu
Thread model: posix
gcc version 5.5.0 20171010 (Ubuntu/Linaro 5.5.0-12ubuntu1)

Update #2:

It seems that the gfortran command does not point to the correct binary, or nowhere at all.

which gfortran

yields an empty response, whereas

which gfortran-5

returns

/usr/bin/gfortran-5

Does anybody know how to fix this?

Thanks in advance!

Lorenz

Seems that the solution was just running

sudo ln -s /usr/bin/gfortran-5 /usr/bin/gfortran

and

sudo reboot

Stupid me!

I solved it in the following way.

apt install python3-scipy

Thank you