Skip to main content
Stack Overflow
  1. About
  2. For Teams

Return to Question

edited tags
Link
Ben Bolker
  • 230.5k
  • 26
  • 405
  • 498
Source Link

Undefined reference to BLAS

I'm trying to install the HurdleNormal R package as a dependency for another package (COZINE), and I'm getting the following error:

C:\rtools45\x86_64-w64-mingw32.static.posix\bin/ld.exe: 
hurdle_likelihood.o:hurdle_likelihood.cpp:(.text+0x1fc): undefined reference to `ddot_'
C:\rtools45\x86_64-w64-mingw32.static.posix\bin/ld.exe: 
hurdle_likelihood.o:hurdle_likelihood.cpp:(.text+0x3be): undefined reference to `dsyrk_'
C:\rtools45\x86_64-w64-mingw32.static.posix\bin/ld.exe: 
hurdle_likelihood.o:hurdle_likelihood.cpp:(.text+0x6c8): undefined reference to `dgemv_'
C:\rtools45\x86_64-w64-mingw32.static.posix\bin/ld.exe: 
hurdle_likelihood.o:hurdle_likelihood.cpp:(.text+0x23f0): undefined reference to `dgemm_'
C:\rtools45\x86_64-w64-mingw32.static.posix\bin/ld.exe: 
hurdle_likelihood.o:hurdle_likelihood.cpp:(.text+0x49c4): undefined reference to `ddot_'
C:\rtools45\x86_64-w64-mingw32.static.posix\bin/ld.exe: 
hurdle_likelihood.o:hurdle_likelihood.cpp:(.text.hot+0x12c): undefined reference to `dgemv_'
C:\rtools45\x86_64-w64-mingw32.static.posix\bin/ld.exe: 
hurdle_likelihood.o:hurdle_likelihood.cpp:(.text.hot+0x263): undefined reference to `dgemv_'
C:\rtools45\x86_64-w64-mingw32.static.posix\bin/ld.exe: 
hurdle_likelihood.o:hurdle_likelihood.cpp:(.text.hot+0x3ba): undefined reference to `dgemv_'
C:\rtools45\x86_64-w64-mingw32.static.posix\bin/ld.exe: 
hurdle_likelihood.o:hurdle_likelihood.cpp:(.text.hot+0x7cc): undefined reference to `dgemv_'
C:\rtools45\x86_64-w64-mingw32.static.posix\bin/ld.exe: 
hurdle_likelihood.o:hurdle_likelihood.cpp:(.text.hot+0x882): undefined reference to `dgemv_'
collect2.exe: error: ld returned 1 exit status
no DLL was created
ERROR: compilation failed for package 'HurdleNormal'
* removing 'C:/Users/miran/AppData/Local/R/win-library/4.5/HurdleNormal'
Warning message:
In i.p(...) :
installation of package 
‘C:/Users/myname/AppData/Local/Temp/RtmpM19b7s/file3f984fe63d57/HurdleNormal_0.98.8.tar.gz’ 
had non-zero exit status

It seems that R can't find basic BLAS functions that are used in the package code.

I have tried multiple troubleshooting fixes, including reinstalling R tools, and manually copy/pasting the .dll files from the OpenBLAS-0.3.29_x64 downloaded .zip file, and installing openblas from the terminal using conda install openblas. So far nothing has worked. I am aware of ropenblas, but based on the package documentation it only configures R to use OpenBLAS on Linux systems.

I am working in Windows 11, RStudio version 2023060 (Build 421) with R version 4.5.

I have seen so many different solutions to this online (which all seem to do different things, none of which have worked so far), half of which I don't have enough computer knowledge to implement.

This specific package is needed to try and replicate a previous analysis. Any assistance is appreciated.

lang-r

AltStyle によって変換されたページ (->オリジナル) /