Skip to content

Commit 28d0ced

Browse files
committed
avoid removing inst/lib on clean
1 parent 20d6042 commit 28d0ced

File tree

3 files changed

+9
-6
lines changed

3 files changed

+9
-6
lines changed

src/Makevars.in

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -153,9 +153,9 @@ else
153153
@(cd tbb/src && $(MAKE_CMD) @STDVER@ $(MAKE_ARGS) $(MAKE_TARGETS) $(MAKE_LOG))
154154
endif
155155

156+
# NOTE: we do not want to clean ../inst/lib or ../inst/libs here,
157+
# as we may be writing to those locations in multiarch builds
156158
tbb-clean:
157-
@rm -rf ../inst/lib
158-
@rm -rf ../inst/libs
159159
@rm -rf ../inst/include/tbb
160160
@rm -rf ../inst/include/oneapi
161161
@rm -rf ../inst/include/tbb_local

src/install.libs.R

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,9 @@
1313
file.copy("symbols.rds", dest, overwrite = TRUE)
1414

1515
# also copy to package 'libs' folder, for devtools
16-
dest <- paste0("../libs", R_ARCH)
17-
dir.create(dest, recursive = TRUE, showWarnings = FALSE)
18-
file.copy(files, dest, overwrite = TRUE)
16+
libsDest <- paste0("../libs", R_ARCH)
17+
dir.create(libsDest, recursive = TRUE, showWarnings = FALSE)
18+
file.copy(files, libsDest, overwrite = TRUE)
1919

2020
# copy tbb
2121
# TODO: use 'dest' library directory once rstan is updated

tools/config/cleanup.R

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,7 @@
1+
12
# Clean up files generated during configuration here.
23
# Use 'remove_file()' to remove files generated during configuration.
3-
unlink("src/tbb/build/lib_release", recursive = TRUE)
44

5+
unlink("src/tbb/build/lib_release", recursive = TRUE)
6+
unlink("inst/lib", recursive = TRUE)
7+
unlink("inst/libs", recursive = TRUE)

0 commit comments

Comments
 (0)