OpenBlas fails to build with the port options set to: AVX=on: Support Advanced Vector Extensions (AVX) AVX2=off: Support Advanced Vector Extensions 2 (AVX2) DYNAMIC_ARCH=on: Optimize for multiple CPU types, otherwise for this CPU INTERFACE64=off: Use 8 byte integers on 64-bit architectures OPENMP=off: Use OpenMP for threading The compilation error is: dynamic.c:734:15: error: use of undeclared identifier 'gotoblas_SAPPHIRERAPIDS' return &gotoblas_SAPPHIRERAPIDS; ^ dynamic.c:1054:20: error: use of undeclared identifier 'gotoblas_SAPPHIRERAPIDS' if (gotoblas == &gotoblas_SAPPHIRERAPIDS) return corename[26]; ^ 2 errors generated.
After some testing it turned out that the build fails only with AVX=on AVX2=off DYNAMIC_ARCH=on Disabling AVX option or enabling AVX2 option with DYNAMIC_ARCH=on allows port to build successfully. Some changes were made at upstream code to dynamic.c in the OpenBlas 0.3.26 version, but it seems that OpenBlas 0.3.26 also suffers from this issue.
Created attachment 248126 [details] Archive with the build log for OpenBlas 0.3.25 Attached a full test build log for the OpenBlas version 0.3.25 on a FreeBSD 13.2-RELEASE-p8 amd64 host.
Created attachment 248144 [details] Proposed patch Added a proposed patch to fix this build issue. This fix was approved upstream in https://github.com/OpenMathLib/OpenBLAS/issues/4476
Created attachment 248145 [details] Archive with the build log for the proposed patch Added a test build log for the proposed patch from a 13.2-RELEASE-p8 amd64 host
Some additional information - this patch can be applied to OpenBLAS version 0.3.25 and to the latest version 0.3.26. We'll have to keep this patch in the ports tree until this bug will be fixed upstream.
FYI The proposed patch was included in upstream source code with a https://github.com/OpenMathLib/OpenBLAS/pull/4482 It set to be included in a OpenBLAS 0.3.27 release milestone. phd_kimberlite@ can you please approve the patch so we can move on on the bug #276789 ?
Ping! =) Any update on this?