Commit 1912736
committed
load tbb stub library on windows again
RcppParallel 6.0.0 (via #241) stopped loading any TBB library in .onLoad
on Windows, on the grounds that TBB is statically linked there. However,
we still ship a stub tbb.dll (see src/install.libs.R) for packages that
link with '-ltbb', e.g. via StanHeaders' LdFlags(). Those packages record
a load-time dependency on 'tbb.dll' in their DLL's import table, and the
Windows loader can only resolve it against an already-loaded module --
RcppParallel's lib/x64 directory is not on the DLL search path.
As a result, with 6.0.0 on Windows, Stan-based packages fail to load with:
LoadLibrary failure: The specified module could not be found.
as seen with e.g. WSPsignal on r-universe:
https://github.com/r-universe/cran/actions/runs/30028540221/job/89334243681
Restore the preload, resolving the stub directly (tbbLibraryPath() now
reports static library names on Windows, so it cannot be used here).1 parent fbaeabb commit 1912736
2 files changed
Lines changed: 22 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
3 | 10 | | |
4 | 11 | | |
5 | 12 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
11 | 11 | | |
12 | 12 | | |
13 | 13 | | |
14 | | - | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
15 | 21 | | |
16 | | - | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
17 | 29 | | |
| 30 | + | |
18 | 31 | | |
19 | 32 | | |
20 | 33 | | |
| |||
0 commit comments