Skip to content

Commit

Permalink
Readonly file io error (#1346)
Browse files Browse the repository at this point in the history
* Copy cpp source with copy.mode = false

Fixes #1345

* Add to ChangeLog

* Fix ChangeLog formatting

---------

Co-authored-by: Simon Guest <[email protected]>
  • Loading branch information
tesujimath and Simon Guest authored Nov 25, 2024
1 parent 6193de5 commit fdd7205
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
4 changes: 4 additions & 0 deletions ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
2024-11-25 Simon Guest <[email protected]>

* src/attributes.cpp: fix CPP source having to be writable

2024-11-03 Marco Colombo <[email protected]>

* vignettes/rmd/Rcpp-FAQ.Rmd: Fixed typos
Expand Down
2 changes: 1 addition & 1 deletion src/attributes.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3279,7 +3279,7 @@ namespace {

// copy the source file to the build dir
Rcpp::Function filecopy = Rcpp::Environment::base_env()["file.copy"];
filecopy(cppSourcePath_, generatedCppSourcePath(), true);
filecopy(cppSourcePath_, generatedCppSourcePath(), true, Rcpp::_["copy.mode"] = false);

// parse attributes
SourceFileAttributesParser sourceAttributes(cppSourcePath_, "", true);
Expand Down

0 comments on commit fdd7205

Please sign in to comment.