On 20 May 2025 at 19:39, Peiyuan Zhu wrote: | How to use the O4 flag in an RCpp project? Every time when I load_all it | starts using the O2 flag or the debug flag. What should I put into Makevar? | Can I still do remote::install.github(...)?
Given that this mailing list can need explicit approval on eg initial posts, your post here precedes these two follow-ups you posted since. So by now this same question by you has also been asked - on Stackoverflow about twelve hours ago; you were told that it is not a genuinely well-formed question (and StackOverflow can be funny that way, I stop interacting there for that reason). The URL is at https://stackoverflow.com/questions/79631329/how-to-use-o4-flag-in-rcpp-project - on GitHub at the Rcpp repo also about twelve hours ago, and Kevin gave you fairly extensive feedback saying that it isn't really a Rcpp question, and also closed it, see https://github.com/RcppCore/Rcpp/issues/1383 I also gave you some feedback there six hours ago, in essence the issue is one that has nothing to do with Rcpp and is about how R calls make to generate the compilation, see https://github.com/RcppCore/Rcpp/issues/1383#issuecomment-2896674848 The underlying issue ("how do I override compiler switches") has been discussed elsewhere too, likely here and earlier on the (older) list r-devel. In short, "no we cannot remove -O2" and "no it does not matter" because (if I recall correctly) the right-most value wins. The documentation of `make` probably has more. Otherwise you probably want to consult the "Writing R Extensions" manual. Hope this helps. Dirk -- dirk.eddelbuettel.com | @eddelbuettel | e...@debian.org ______________________________________________ R-package-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-package-devel