Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions ChangeLog
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@

* docker/ci-dev/Dockerfile: Also install the 'codetools' package

2020-03-31 Kevin Ushey <kevin@rstudio.com>

* R/Attributes.R: Fix for sourceCpp() on Windows w/R-devel

2020-03-24 Dirk Eddelbuettel <edd@debian.org>

* DESCRIPTION (Version, Date): Roll minor version
Expand Down
28 changes: 18 additions & 10 deletions R/Attributes.R
Original file line number Diff line number Diff line change
Expand Up @@ -127,17 +127,25 @@ sourceCpp <- function(file = "",
file.remove(context$previousDynlibPath)
} # #nocov end

# grab components we need to build command
r <- paste(R.home("bin"), "R", sep = .Platform$file.sep)
lib <- context$dynlibFilename
deps <- context$cppDependencySourcePaths
src <- context$cppSourceFilename

# prepare the command (output if we are in showOutput mode)
cmd <- paste(R.home(component="bin"), .Platform$file.sep, "R ",
"CMD SHLIB ",
ifelse(windowsDebugDLL, "-d ", ""),
"-o ", shQuote(context$dynlibFilename), " ",
ifelse(rebuild, "--preclean ", ""),
ifelse(dryRun, "--dry-run ", ""),
paste(shQuote(context$cppDependencySourcePaths),
collapse = " "), " ",
shQuote(context$cppSourceFilename), " ",
sep="")
args <- c(
r, "CMD", "SHLIB",
if (windowsDebugDLL) "-d",
if (rebuild) "--preclean",
if (dryRun) "--dry-run",
"-o", shQuote(lib),
if (length(deps))
paste(shQuote(deps), collapse = " "),
shQuote(src)
)

cmd <- paste(args, collapse = " ")
if (showOutput)
cat(cmd, "\n") # #nocov

Expand Down