cvxgrp / scs

Splitting Conic Solver
MIT License
553 stars 136 forks source link

Configure prints "Library openblas found: NO" when libopenblas.so is installed #272

Open yurivict opened 5 months ago

yurivict commented 5 months ago

Specifications

===>  Building for py311-scs-3.2.4.p2
* Getting build dependencies for wheel...
* Building wheel...
+ meson setup /usr/ports/math/py-scs/work-py311/scs-3.2.4.post2 /usr/ports/math/py-scs/work-py311/scs-3.2.4.post2/.mesonpy-fw8q_7r3 -Dbuildtype=release -Db_ndebug=if-release -Db_vscrt=md --native-file=/usr/ports/math/py-scs/work-py311/scs-3.2.4.post2/.mesonpy-fw8q_7r3/meson-python-native-file.ini
The Meson build system
Version: 1.4.1
Source dir: /usr/ports/math/py-scs/work-py311/scs-3.2.4.post2
Build dir: /usr/ports/math/py-scs/work-py311/scs-3.2.4.post2/.mesonpy-fw8q_7r3
Build type: native build
Project name: scs
Project version: undefined
C compiler for the host machine: cc (clang 18.1.5 "FreeBSD clang version 18.1.5 (https://github.com/llvm/llvm-project.git llvmorg-18.1.5-0-g617a15a9eac9)")
C linker for the host machine: cc ld.lld 18.1.5
Host machine cpu family: x86_64
Host machine cpu: x86_64
Program python found: YES (/usr/local/bin/python3.11)
Library openblas found: NO
Found pkg-config: YES (/usr/local/bin/pkgconf) 2.2.0
Run-time dependency openblas found: YES 0.3.25
Compiler for C supports arguments -Wno-unused-result: YES 
Run-time dependency python found: YES 3.11
Build targets in project: 2
bodono commented 5 months ago

This build file is just relying on mesons find_library function to determine whether or not openblas is installed. The docs for that function say "By default the library is searched for in the system library directory". Is it possible that it is installed in somewhere different?

yurivict commented 5 months ago

libopenblas is always installed into the same path: /usr/local/lib/libopenblas.so

bodono commented 5 months ago

Seems like this is possibly an issue with meson and BSD specifically: https://github.com/mesonbuild/meson/issues/4468

Not sure what workaround we can do here.

bodono commented 5 months ago

You can try the legacy (non-meson) setup.

python legacy_setup.py install