[R-pkg-devel] Compilation used the "non-portable flag"

Dirk Eddelbuettel edd @end|ng |rom deb|@n@org
Wed May 15 13:15:46 CEST 2019


On 15 May 2019 at 11:49, Gábor Csárdi wrote:
| Thinking about this a bit more, I think this might be a bug in R CMD
| check, actually.
| 
| I understand that these flags are not portable, and yes, they should
| be reported if they are specified in the packages's Makevars* files.
| But in this case they are coming from the Ubuntu system's Makevars
| setup, and surely, they do work there. I would even say that it is
| actually good practice to include them in the system setup.
| 
| I can probably provide a patch for this.

See discussions on r-sig-debian -- in essence I had the same thouht and this
has been taken care of now in R 3.6.0-2.  We add this to Renviron.site 

## edd May 2019
##
## Debian (and its derivatives) impose a set of compiler flags to prevent some known
## security issues with compiled code.  These flags then become defaults for R as well
## (see eg /etc/R/Makeconf) but nevertheless confuse R as warnings get triggers.  Users,
## on the other hand, are often stumped about these.  So with this variable we declare
## these options as known for the local checks on the machine this file is on.
##
## See Section 8 of the R Internals manual for many more options to customize tests.
_R_CHECK_COMPILATION_FLAGS_KNOWN_='-Wformat -Werror=format-security -Wdate-time'


It may eventually move to Renviron now that Kurt kindly fixed an Renviron parser
buglet with `=` assignments in r-devel

So please add the environment variable now on all Debian and Ubuntu flavours,
and/or upgrade to 3.6.0-2.

Dirk

-- 
http://dirk.eddelbuettel.com | @eddelbuettel | edd using debian.org



More information about the R-package-devel mailing list