Opened 11 months ago
Last modified 11 months ago
#68908 assigned defect
py-numpy: pep517 backend broken: ERROR: Unknown compiler(s): [['cython'], ['cython3']]
Reported by: | barracuda156 | Owned by: | michaelld (Michael Dickens) |
---|---|---|---|
Priority: | Normal | Milestone: | |
Component: | ports | Version: | 2.8.1 |
Keywords: | tiger, leopard, snowleopard, powerpc | Cc: | catap (Kirill A. Korinsky) |
Port: | py311-numpy |
Description (last modified by barracuda156)
The Meson build system Version: 1.2.99 Source dir: /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_python_py-numpy/py311-numpy/work/numpy-1.26.1 Build dir: /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_python_py-numpy/py311-numpy/work/numpy-1.26.1/.mesonpy-dd10zcxl/build Build type: cross build Project name: NumPy Project version: 1.26.1 C compiler for the host machine: cc -arch ppc (gcc 4.2.1 "powerpc-apple-darwin10-gcc-4.2.1 (GCC) 4.2.1 (Apple Inc. build 5626)") C linker for the host machine: cc -arch ppc ld64 87.3.1 C++ compiler for the host machine: c++ -arch ppc (gcc 4.2.1 "powerpc-apple-darwin10-g++-4.2.1 (GCC) 4.2.1 (Apple Inc. build 5626)") C++ linker for the host machine: c++ -arch ppc ld64 87.3.1 ../../meson.build:1:0: ERROR: Unknown compiler(s): [['cython'], ['cython3']] The following exception(s) were encountered: Running `cython -V` gave "[Errno 2] No such file or directory: 'cython'" Running `cython3 -V` gave "[Errno 2] No such file or directory: 'cython3'" A full log can be found at /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_python_py-numpy/py311-numpy/work/numpy-1.26.1/.mesonpy-dd10zcxl/build/meson-logs/meson-log.txt ERROR Backend subprocess exited when trying to invoke build_wheel
Also it was unneeded to force it for pre-3.12 pythons. Without it numpy
builds.
Attachments (1)
Change History (18)
comment:1 Changed 11 months ago by barracuda156
comment:2 Changed 11 months ago by barracuda156
Apparently this update has broken the port: https://github.com/macports/macports-ports/commit/5003eeca90f5d8b6cf935c6342e247afcdd81c2d I have 1.25.2 installed on the same system.
comment:3 Changed 11 months ago by barracuda156
And their vendored meson (why is it used instead of Macports one?) completely ignores env vars:
:notice:build ---> Building py311-numpy :debug:build Executing proc-pre-org.macports.build-build-0 :debug:build Executing proc-pre-org.macports.build-build-1 :debug:build Executing proc-pre-org.macports.build-build-2 :debug:build Executing org.macports.build (py311-numpy) :debug:build Environment: :debug:build ARCHFLAGS='-arch ppc' :debug:build ATLAS='None' :debug:build CC='/opt/local/bin/gcc-mp-13' :debug:build CC_PRINT_OPTIONS='YES' :debug:build CC_PRINT_OPTIONS_FILE='/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/.CC_PRINT_OPTIONS' :debug:build CFLAGS='-arch ppc -isysroot/' :debug:build CPATH='/opt/local/include' :debug:build CXX='/opt/local/bin/g++-mp-13' :debug:build CXXFLAGS='-arch ppc -D_GLIBCXX_USE_CXX11_ABI=0 -isysroot/' :debug:build CYTHON='/opt/local/bin/cython-3.11' :debug:build DEVELOPER_DIR='/Developer' :debug:build F77='/opt/local/bin/gfortran-mp-13' :debug:build F90='/opt/local/bin/gfortran-mp-13' :debug:build F90FLAGS='-m32' :debug:build FC='/opt/local/bin/gfortran-mp-13' :debug:build FCFLAGS='-m32' :debug:build FFLAGS='-m32' :debug:build LDFLAGS='-arch ppc' :debug:build LIBRARY_PATH='/opt/local/lib' :debug:build MACOSX_DEPLOYMENT_TARGET='10.6' :debug:build MKLROOT='None' :debug:build OBJC='/opt/local/bin/gcc-mp-13' :debug:build OBJCFLAGS='-arch ppc -isysroot/' :debug:build OPENBLAS='/opt/local/lib' :debug:build SETUPTOOLS_USE_DISTUTILS='stdlib' :info:build Executing: cd "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.2" && /opt/local/Library/Frameworks/Python.framework/Versions/3.11/bin/python3.11 -m build --no-isolation --wheel --outdir /opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work :debug:build system: cd "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.2" && /opt/local/Library/Frameworks/Python.framework/Versions/3.11/bin/python3.11 -m build --no-isolation --wheel --outdir /opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work :info:build * Getting build dependencies for wheel... :info:build * Building wheel... :info:build + /opt/local/Library/Frameworks/Python.framework/Versions/3.11/bin/python3.11 /opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.2/vendored-meson/meson/meson.py setup /opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.2 /opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.2/.mesonpy-rnpocwke/build -Dbuildtype=release -Db_ndebug=if-release -Db_vscrt=md --cross-file /opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.2/.mesonpy-rnpocwke/build/meson-python-cross-file.ini --native-file=/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.2/.mesonpy-rnpocwke/build/meson-python-native-file.ini :info:build The Meson build system :info:build Version: 1.2.99 :info:build Source dir: /opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.2 :info:build Build dir: /opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.2/.mesonpy-rnpocwke/build :info:build Build type: cross build :info:build Project name: NumPy :info:build Project version: 1.26.2 :info:build C compiler for the host machine: cc -arch ppc (gcc 4.2.1 "powerpc-apple-darwin10-gcc-4.2.1 (GCC) 4.2.1 (Apple Inc. build 5626)") :info:build C linker for the host machine: cc -arch ppc ld64 87.3.1 :info:build C++ compiler for the host machine: c++ -arch ppc (gcc 4.2.1 "powerpc-apple-darwin10-g++-4.2.1 (GCC) 4.2.1 (Apple Inc. build 5626)") :info:build C++ linker for the host machine: c++ -arch ppc ld64 87.3.1 :info:build ../../meson.build:1:0: ERROR: Unknown compiler(s): [['cython'], ['cython3']] :info:build The following exception(s) were encountered: :info:build Running `cython -V` gave "[Errno 2] No such file or directory: 'cython'" :info:build Running `cython3 -V` gave "[Errno 2] No such file or directory: 'cython3'" :info:build A full log can be found at /opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.2/.mesonpy-rnpocwke/build/meson-logs/meson-log.txt :info:build ERROR Backend subprocess exited when trying to invoke build_wheel :info:build Command failed: cd "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.2" && /opt/local/Library/Frameworks/Python.framework/Versions/3.11/bin/python3.11 -m build --no-isolation --wheel --outdir /opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work :info:build Exit code: 1
comment:4 Changed 11 months ago by barracuda156
Summary: | py311-numpy broken on PPC: ERROR: Unknown compiler(s): [['cython'], ['cython3']] → py311-numpy @1.26.1 ignores env vars: ERROR: Unknown compiler(s): [['cython'], ['cython3']] |
---|
comment:5 Changed 11 months ago by barracuda156
Just in case, confirmed on 10.6.8 Rosetta too:
The Meson build system Version: 1.2.99 Source dir: /opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1 Build dir: /opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/.mesonpy-bxvwlv29/build Build type: cross build Project name: NumPy Project version: 1.26.1 C compiler for the host machine: cc -arch ppc (gcc 4.2.1 "powerpc-apple-darwin10-gcc-4.2.1 (GCC) 4.2.1 (Apple Inc. build 5666) (dot 3)") C linker for the host machine: cc -arch ppc ld64 97.17 C++ compiler for the host machine: c++ -arch ppc (gcc 4.2.1 "powerpc-apple-darwin10-g++-4.2.1 (GCC) 4.2.1 (Apple Inc. build 5666) (dot 3)") C++ linker for the host machine: c++ -arch ppc ld64 97.17 ../../meson.build:1:0: ERROR: Unknown compiler(s): [['cython'], ['cython3']] The following exception(s) were encountered: Running `cython -V` gave "[Errno 2] No such file or directory: 'cython'" Running `cython3 -V` gave "[Errno 2] No such file or directory: 'cython3'" A full log can be found at /opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/.mesonpy-bxvwlv29/build/meson-logs/meson-log.txt ERROR Backend subprocess exited when trying to invoke build_wheel
Even calling explicitly py311-numpy +gcc12 configure.compiler=macports-gcc-12
(I did not build gcc13 on this system yet) has to effect, gcc-4.2
is picked.
comment:6 Changed 11 months ago by barracuda156
Ok, so one thing which broken this was pep517, which was unnecessarily forced for python <3.12. Without that it builds (though gfortran
is not found and, I believe, arch optimizations will not be done on ppc
, since detection was broken long back):
---> Configuring py311-numpy ---> Building py311-numpy Executing: cd "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1" && /opt/local/Library/Frameworks/Python.framework/Versions/3.11/bin/python3.11 setup.py --no-user-cfg build -j6 /opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/setup.py:17: DeprecationWarning: The distutils package is deprecated and slated for removal in Python 3.12. Use setuptools or check PEP 632 for potential alternatives from distutils.errors import CompileError Running from numpy source directory. /opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/setup.py:75: DeprecationWarning: `numpy.distutils` is deprecated since NumPy 1.23.0, as a result of the deprecation of `distutils` itself. It will be removed for Python >= 3.12. For older Python versions it will remain present. It is recommended to use `setuptools < 60.0` for those Python versions. For more details, see: https://numpy.org/devdocs/reference/distutils_status_migration.html import numpy.distutils.command.sdist Processing numpy/random/_bounded_integers.pxd.in Processing numpy/random/_bounded_integers.pyx.in Processing numpy/random/_common.pyx Processing numpy/random/_generator.pyx Processing numpy/random/_mt19937.pyx Processing numpy/random/_pcg64.pyx Processing numpy/random/_philox.pyx Processing numpy/random/_sfc64.pyx Processing numpy/random/bit_generator.pyx Processing numpy/random/mtrand.pyx fatal: not a git repository (or any of the parent directories): .git Cythonizing sources INFO: blas_opt_info: INFO: blas_armpl_info: INFO: customize UnixCCompiler INFO: libraries armpl_lp64_mp not found in ['/opt/local/Library/Frameworks/Python.framework/Versions/3.11/lib', '/usr/lib', '/opt/local/lib'] INFO: NOT AVAILABLE INFO: INFO: blas_mkl_info: INFO: Disabled blas_mkl_info: (MKLROOT is None) INFO: Disabled blas_mkl_info: (MKLROOT is None) INFO: libraries mkl_rt not found in [] INFO: NOT AVAILABLE INFO: INFO: blas_ssl2_info: INFO: libraries fjlapackexsve not found in ['/opt/local/Library/Frameworks/Python.framework/Versions/3.11/lib', '/usr/lib', '/opt/local/lib'] INFO: NOT AVAILABLE INFO: INFO: blis_info: INFO: FOUND: INFO: libraries = ['blis', 'blis'] INFO: library_dirs = ['/opt/local/lib'] INFO: define_macros = [('HAVE_CBLAS', None)] INFO: include_dirs = ['/opt/local/include', '/opt/local/Library/Frameworks/Python.framework/Versions/3.11/include'] INFO: language = c INFO: INFO: FOUND: INFO: libraries = ['blis', 'blis'] INFO: library_dirs = ['/opt/local/lib'] INFO: define_macros = [('HAVE_CBLAS', None)] INFO: include_dirs = ['/opt/local/include', '/opt/local/Library/Frameworks/Python.framework/Versions/3.11/include'] INFO: language = c INFO: dyld: lazy symbol binding failed: Symbol not found: _apr_xlate_open Referenced from: /opt/local/lib/libsvn_subr-1.0.dylib Expected in: /opt/local/lib/libaprutil-1.0.dylib dyld: Symbol not found: _apr_xlate_open Referenced from: /opt/local/lib/libsvn_subr-1.0.dylib Expected in: /opt/local/lib/libaprutil-1.0.dylib non-existing path in 'numpy/distutils': 'site.cfg' non-existing path in 'numpy/f2py': 'backends/meson.build.template' INFO: lapack_opt_info: INFO: lapack_armpl_info: INFO: libraries armpl_lp64_mp not found in ['/opt/local/Library/Frameworks/Python.framework/Versions/3.11/lib', '/usr/lib', '/opt/local/lib'] INFO: NOT AVAILABLE INFO: INFO: lapack_mkl_info: INFO: Disabled lapack_mkl_info: (MKLROOT is None) INFO: Disabled lapack_mkl_info: (MKLROOT is None) INFO: libraries mkl_rt not found in [] INFO: NOT AVAILABLE INFO: INFO: lapack_ssl2_info: INFO: libraries fjlapackexsve not found in ['/opt/local/Library/Frameworks/Python.framework/Versions/3.11/lib', '/usr/lib', '/opt/local/lib'] INFO: NOT AVAILABLE INFO: INFO: openblas_lapack_info: INFO: C compiler: /opt/local/bin/gcc-mp-12 -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -pipe -Os -arch ppc -isysroot/ creating /opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/.tmp/tmpdo7omz31/opt creating /opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/.tmp/tmpdo7omz31/opt/local creating /opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/.tmp/tmpdo7omz31/opt/local/var creating /opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/.tmp/tmpdo7omz31/opt/local/var/macports creating /opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/.tmp/tmpdo7omz31/opt/local/var/macports/build creating /opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/.tmp/tmpdo7omz31/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy creating /opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/.tmp/tmpdo7omz31/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy creating /opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/.tmp/tmpdo7omz31/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work creating /opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/.tmp/tmpdo7omz31/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/.tmp creating /opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/.tmp/tmpdo7omz31/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/.tmp/tmpdo7omz31 INFO: compile options: '-c' INFO: gcc-mp-12: /opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/.tmp/tmpdo7omz31/source.c INFO: /opt/local/bin/gcc-mp-12 -arch ppc /opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/.tmp/tmpdo7omz31/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/.tmp/tmpdo7omz31/source.o -L/opt/local/lib -lopenblas -o /opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/.tmp/tmpdo7omz31/a.out INFO: FOUND: INFO: libraries = ['openblas', 'openblas'] INFO: library_dirs = ['/opt/local/lib'] INFO: language = c INFO: define_macros = [('HAVE_CBLAS', None)] INFO: runtime_library_dirs = ['/opt/local/lib'] INFO: INFO: FOUND: INFO: libraries = ['openblas', 'openblas'] INFO: library_dirs = ['/opt/local/lib'] INFO: language = c INFO: define_macros = [('HAVE_CBLAS', None)] INFO: runtime_library_dirs = ['/opt/local/lib'] INFO: /opt/local/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/distutils/dist.py:274: UserWarning: Unknown distribution option: 'define_macros' warnings.warn(msg) running build running config_cc INFO: unifing config_cc, config, build_clib, build_ext, build commands --compiler options running config_fc INFO: unifing config_fc, config, build_clib, build_ext, build commands --fcompiler options running build_src INFO: build_src INFO: building py_modules sources creating build creating build/src.macosx-10.6-ppc-3.11 creating build/src.macosx-10.6-ppc-3.11/numpy creating build/src.macosx-10.6-ppc-3.11/numpy/distutils INFO: building library "npymath" sources WARN: Could not locate executable gfortran WARN: Could not locate executable f95 creating build/src.macosx-10.6-ppc-3.11/numpy/core creating build/src.macosx-10.6-ppc-3.11/numpy/core/src creating build/src.macosx-10.6-ppc-3.11/numpy/core/src/npymath
comment:7 Changed 11 months ago by barracuda156
Description: | modified (diff) |
---|---|
Summary: | py311-numpy @1.26.1 ignores env vars: ERROR: Unknown compiler(s): [['cython'], ['cython3']] → py-numpy: pep517 backend broken: ERROR: Unknown compiler(s): [['cython'], ['cython3']] |
comment:8 Changed 11 months ago by barracuda156
Yeah, arch detection is broken totally, regardless of backend:
########### CLIB COMPILER OPTIMIZATION ########### INFO: Platform : Architecture: unsupported Compiler : gcc CPU baseline : Requested : optimization disabled Enabled : none Flags : none Extra checks: none Requested : optimization disabled CPU dispatch : Enabled : none Generated : none
(This is upstream bug, not ours, and it was there for quite some time if not forever.)
comment:9 Changed 11 months ago by barracuda156
On a side note, here is why pep517 thinks this is a cross-build:
`
if sysconfig.get_platform().startswith('macosx-'):
archflags = os.environ.get('ARCHFLAGS', ).strip() if archflags:
arch, *other = filter(None, (x.strip() for x in archflags.split('-arch'))) if other:
raise ConfigError(f'Multi-architecture builds are not supported but $ARCHFLAGS={archflags!r}')
macver, _, nativearch = platform.mac_ver() if arch != nativearch:
x = os.environ.setdefault('_PYTHON_HOST_PLATFORM', f'macosx-{macver}-{arch}') if not x.endswith(arch):
raise ConfigError(f'$ARCHFLAGS={archflags!r} and $_PYTHON_HOST_PLATFORM={x!r} do not agree')
family = 'aarch64' if arch == 'arm64' else arch cross_file_data = textwrap.dedent(f
[binaries] c = ['cc', '-arch', {arch!r}] cpp = ['c++', '-arch', {arch!r}] [host_machine] system = 'darwin' cpu = {arch!r} cpu_family = {family!r} endian = 'little'
) self._meson_cross_file.write_text(cross_file_data) self._meson_argssetup?.extend(('--cross-file', os.fspath(self._meson_cross_file)))
`
But python has
PowerPC
, which is not the arch name:
`
macmini:macports-ports svacchanda$ /opt/local/bin/python3.11 -c 'import platform; print(platform.mac_ver())'
('10.6.8', (, , ), 'PowerPC')
`
comment:10 Changed 11 months ago by barracuda156
I have fixed the bug in meson-python
, now the build is recognized as native with pep517, but fails on:
---> Configuring py311-numpy ---> Building py311-numpy Executing: cd "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1" && /opt/local/Library/Frameworks/Python.framework/Versions/3.11/bin/python3.11 -m build --no-isolation --wheel --outdir /opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work * Getting build dependencies for wheel... * Building wheel... + /opt/local/Library/Frameworks/Python.framework/Versions/3.11/bin/python3.11 /opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/vendored-meson/meson/meson.py setup /opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1 /opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/.mesonpy-bjry3rb8/build -Dbuildtype=release -Db_ndebug=if-release -Db_vscrt=md --native-file=/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/.mesonpy-bjry3rb8/build/meson-python-native-file.ini Traceback (most recent call last): File "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/vendored-meson/meson/mesonbuild/mesonmain.py", line 194, in run return options.run_func(options) ^^^^^^^^^^^^^^^^^^^^^^^^^ File "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/vendored-meson/meson/mesonbuild/msetup.py", line 358, in run app.generate() File "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/vendored-meson/meson/mesonbuild/msetup.py", line 183, in generate return self._generate(env, capture, vslite_ctx) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/vendored-meson/meson/mesonbuild/msetup.py", line 228, in _generate intr.run() File "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/vendored-meson/meson/mesonbuild/interpreter/interpreter.py", line 2997, in run super().run() File "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/vendored-meson/meson/mesonbuild/interpreterbase/interpreterbase.py", line 164, in run self.evaluate_codeblock(self.ast, start=1) File "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/vendored-meson/meson/mesonbuild/interpreterbase/interpreterbase.py", line 190, in evaluate_codeblock raise e File "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/vendored-meson/meson/mesonbuild/interpreterbase/interpreterbase.py", line 182, in evaluate_codeblock self.evaluate_statement(cur) File "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/vendored-meson/meson/mesonbuild/interpreterbase/interpreterbase.py", line 196, in evaluate_statement return self.function_call(cur) ^^^^^^^^^^^^^^^^^^^^^^^ File "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/vendored-meson/meson/mesonbuild/interpreterbase/interpreterbase.py", line 521, in function_call res = func(node, func_args, kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/vendored-meson/meson/mesonbuild/interpreterbase/decorators.py", line 277, in wrapper return f(*nargs, **wrapped_kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/vendored-meson/meson/mesonbuild/interpreterbase/decorators.py", line 596, in wrapper return f(*wrapped_args, **wrapped_kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/vendored-meson/meson/mesonbuild/interpreter/interpreter.py", line 2409, in func_subdir self.evaluate_codeblock(codeblock) File "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/vendored-meson/meson/mesonbuild/interpreterbase/interpreterbase.py", line 190, in evaluate_codeblock raise e File "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/vendored-meson/meson/mesonbuild/interpreterbase/interpreterbase.py", line 182, in evaluate_codeblock self.evaluate_statement(cur) File "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/vendored-meson/meson/mesonbuild/interpreterbase/interpreterbase.py", line 206, in evaluate_statement return self.evaluate_if(cur) ^^^^^^^^^^^^^^^^^^^^^ File "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/vendored-meson/meson/mesonbuild/interpreterbase/interpreterbase.py", line 301, in evaluate_if self.evaluate_codeblock(i.block) File "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/vendored-meson/meson/mesonbuild/interpreterbase/interpreterbase.py", line 190, in evaluate_codeblock raise e File "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/vendored-meson/meson/mesonbuild/interpreterbase/interpreterbase.py", line 182, in evaluate_codeblock self.evaluate_statement(cur) File "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/vendored-meson/meson/mesonbuild/interpreterbase/interpreterbase.py", line 228, in evaluate_statement self.evaluate_foreach(cur) File "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/vendored-meson/meson/mesonbuild/interpreterbase/interpreterbase.py", line 472, in evaluate_foreach self.evaluate_codeblock(node.block) File "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/vendored-meson/meson/mesonbuild/interpreterbase/interpreterbase.py", line 190, in evaluate_codeblock raise e File "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/vendored-meson/meson/mesonbuild/interpreterbase/interpreterbase.py", line 182, in evaluate_codeblock self.evaluate_statement(cur) File "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/vendored-meson/meson/mesonbuild/interpreterbase/interpreterbase.py", line 206, in evaluate_statement return self.evaluate_if(cur) ^^^^^^^^^^^^^^^^^^^^^ File "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/vendored-meson/meson/mesonbuild/interpreterbase/interpreterbase.py", line 306, in evaluate_if self.evaluate_codeblock(node.elseblock) File "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/vendored-meson/meson/mesonbuild/interpreterbase/interpreterbase.py", line 190, in evaluate_codeblock raise e File "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/vendored-meson/meson/mesonbuild/interpreterbase/interpreterbase.py", line 182, in evaluate_codeblock self.evaluate_statement(cur) File "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/vendored-meson/meson/mesonbuild/interpreterbase/interpreterbase.py", line 198, in evaluate_statement self.assignment(cur) File "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/vendored-meson/meson/mesonbuild/interpreterbase/interpreterbase.py", line 635, in assignment value = self.evaluate_statement(node.value) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/vendored-meson/meson/mesonbuild/interpreterbase/interpreterbase.py", line 196, in evaluate_statement return self.function_call(cur) ^^^^^^^^^^^^^^^^^^^^^^^ File "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/vendored-meson/meson/mesonbuild/interpreterbase/interpreterbase.py", line 521, in function_call res = func(node, func_args, kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/vendored-meson/meson/mesonbuild/interpreterbase/decorators.py", line 826, in wrapped return f(*wrapped_args, **wrapped_kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/vendored-meson/meson/mesonbuild/interpreterbase/decorators.py", line 826, in wrapped return f(*wrapped_args, **wrapped_kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/vendored-meson/meson/mesonbuild/interpreterbase/decorators.py", line 826, in wrapped return f(*wrapped_args, **wrapped_kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ [Previous line repeated 4 more times] File "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/vendored-meson/meson/mesonbuild/interpreterbase/decorators.py", line 109, in wrapped ret = f(*wrapped_args, **wrapped_kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/vendored-meson/meson/mesonbuild/interpreterbase/decorators.py", line 127, in wrapped return f(*wrapped_args, **wrapped_kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/vendored-meson/meson/mesonbuild/interpreterbase/decorators.py", line 277, in wrapper return f(*nargs, **wrapped_kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/vendored-meson/meson/mesonbuild/interpreterbase/decorators.py", line 596, in wrapper return f(*wrapped_args, **wrapped_kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/vendored-meson/meson/mesonbuild/interpreter/interpreter.py", line 1774, in func_dependency d = df.lookup(kwargs) ^^^^^^^^^^^^^^^^^ File "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/vendored-meson/meson/mesonbuild/interpreter/dependencyfallbacks.py", line 355, in lookup dep = func(kwargs, func_args, func_kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/vendored-meson/meson/mesonbuild/interpreter/dependencyfallbacks.py", line 87, in _do_dependency dep = dependencies.find_external_dependency(name, self.environment, kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/vendored-meson/meson/mesonbuild/dependencies/detect.py", line 124, in find_external_dependency d = c() ^^^ File "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/vendored-meson/meson/mesonbuild/dependencies/blas_lapack.py", line 524, in __init__ if environment.machines[for_machine].is_darwin() and self.check_macOS_recent_enough(): ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/vendored-meson/meson/mesonbuild/dependencies/blas_lapack.py", line 529, in check_macOS_recent_enough sdk_version = subprocess.run(cmd, capture_output=True, check=True, text=True).stdout.strip() ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/opt/local/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/subprocess.py", line 571, in run raise CalledProcessError(retcode, process.args, subprocess.CalledProcessError: Command '['xcrun', '-sdk', 'macosx', '--show-sdk-version']' returned non-zero exit status 64. The Meson build system Version: 1.2.99 Source dir: /opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1 Build dir: /opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/.mesonpy-bjry3rb8/build Build type: native build Project name: NumPy Project version: 1.26.1 C compiler for the host machine: /opt/local/bin/gcc-mp-12 (gcc 12.3.0 "gcc-mp-12 (MacPorts gcc12 12.3.0_0) 12.3.0") C linker for the host machine: /opt/local/bin/gcc-mp-12 ld64 97.17 C++ compiler for the host machine: /opt/local/bin/g++-mp-12 (gcc 12.3.0 "g++-mp-12 (MacPorts gcc12 12.3.0_0) 12.3.0") C++ linker for the host machine: /opt/local/bin/g++-mp-12 ld64 97.17 Cython compiler for the host machine: /opt/local/bin/cython-3.11 (cython 0.29.34) Host machine cpu family: ppc Host machine cpu: power macintosh Program python found: YES (/opt/local/Library/Frameworks/Python.framework/Versions/3.11/bin/python3.11) Found pkg-config: /opt/local/bin/pkg-config (0.29.2) Run-time dependency python found: YES 3.11 Has header "Python.h" with dependency python-3.11: YES Compiler for C supports arguments -fno-strict-aliasing: YES Message: Disabling CPU feature detection due to unsupported architecture: "ppc" Configuring npy_cpu_dispatch_config.h using configuration Message: CPU Optimization Options baseline: Requested : none Enabled : dispatch: Requested : none Enabled : Library m found: YES Found CMake: /opt/local/bin/cmake (3.27.2) WARNING: CMake Toolchain: Failed to determine CMake compilers state Run-time dependency scipy-openblas found: NO (tried pkgconfig, framework and cmake) WARNING: MKLROOT env var set to /opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/.mesonpy-bjry3rb8/build/None, but not pointing to an MKL install Run-time dependency mkl found: NO (tried pkgconfig and system) WARNING: MKLROOT env var set to /opt/local/var/macports/build/_opt_PPCSnowLeopardPorts_python_py-numpy/py311-numpy/work/numpy-1.26.1/.mesonpy-bjry3rb8/build/None, but not pointing to an MKL install Run-time dependency mkl found: NO (tried pkgconfig and system) ../../numpy/meson.build:119:13: ERROR: Unhandled python exception This is a Meson bug and should be reported! ERROR Backend subprocess exited when trying to invoke build_wheel
Notice, this fixed compiler choice.
Changed 11 months ago by barracuda156
Attachment: | numpy_10.6.8_x86_64.log added |
---|
And the same error on 10.6.8 x86_64:
comment:11 Changed 11 months ago by barracuda156
Upstream issue for Unhandled python exception
error: https://github.com/numpy/numpy/issues/25406
comment:12 Changed 11 months ago by reneeotten (Renee Otten)
there are many issues with the update to NumPy 1.26+ and it appears testing wasn't done properly before that PR was merged. Also the variants selecting a different BLAS/LAPACK implementation are broken.
Similar issues are happening in the latest SciPy version, where we at least can use our own meson
port to build it so that irons out some of the issues you're describing here. I would think that's the first thing we should try: use our meson
and meson-python
ports instead of the vendored ones.
The error message you show in the ticket title is expected though as none of our py-cython
ports install scripts without the Python-version-suffix. So you will need to create a link to that in a pre-build
phase as in (which at least works for my WIP SciPy update):
# meson build systems is looking for default filenames without the version suffix pre-build { ln -s ${prefix}/bin/cython-${python.branch} ${worksrcpath}/cython build.env-append PATH=$env(PATH):${worksrcpath} }
comment:13 follow-up: 14 Changed 11 months ago by kencu (Ken)
this call:
xcrun -sdk macosx --show-sdk-version
is failing on systems < 10.8 and will need to be replaced by something else.
comment:14 Changed 11 months ago by barracuda156
Replying to kencu:
this call:
xcrun -sdk macosx --show-sdk-versionis failing on systems < 10.8 and will need to be replaced by something else.
It obviously does fail, I just thought that it was something else breaking the build (I can be wrong, of course).
Why is it even needed? We do not want xcrun
to decide for SDK at all.
- S. With R packages, this happens with each, but nothing is broken, the call is ignored:
** libs using C++ compiler: ‘g++-mp-13 (MacPorts gcc13 13.2.0_4+stdlib_flag) 13.2.0’ Warning in system2("xcrun", "--show-sdk-path", TRUE, TRUE) : running command ''xcrun' --show-sdk-path 2>&1' had status 64 using SDK: ‘NA’‘NA’‘NA’‘NA’‘NA’‘NA’
comment:15 follow-up: 16 Changed 11 months ago by kencu (Ken)
so that's the project. Figure out what it was doing, then come up with a replacement that works on < 10.8.
on a current system:
% xcrun -sdk macosx --show-sdk-version 14.2
comment:16 Changed 11 months ago by barracuda156
Replying to kencu:
so that's the project. Figure out what it was doing, then come up with a replacement that works on < 10.8.
on a current system:
% xcrun -sdk macosx --show-sdk-version 14.2
Yeah, it is indeed xcrun
breaking the build (arch detection for powerpc is a separate issue). A dirty hack of replacing the command with literal value plus dropping the ridiculous restriction to 13.3 fixes the build.
Notice, cxx_standard gets totally ignored now, despite being set: https://github.com/macports/macports-ports/blob/45a087d9b0e68bc807b8044a8007db18ffa68301/python/py-numpy/Portfile#L44-L45