[R-sig-Debian] Default CXXFLAGS

Ivan Krylov |kry|ov @end|ng |rom d|@root@org
Tue May 21 14:42:24 CEST 2024


On Tue, 21 May 2024 07:08:02 -0500
Dirk Eddelbuettel <edd using debian.org> wrote:

> You cannot undo what it is in R's own /etc/R/Makeconf via a
> programmatic way via some sort of option or alike.

I think this is about the following line in debian/rules:

optimflags      = `DEB_BUILD_MAINT_OPTIONS=optimize=-lto dpkg-buildflags --get CFLAGS`

https://sources.debian.org/src/r-base/4.4.0-2/debian/rules/#L101

...which later propagares to cxxflags	= $(optimflags) and
eventually CXXFLAGS="$(cxxflags)" ... ./configure.

On Sid, dpkg-buildflags --get CFLAGS includes
-Werror=implicit-function-declaration, which g++ doesn't like:

root using 020af1fe3ba2:/# g++ -Werror=implicit-function-declaration -c ex.cpp
cc1plus: warning: '-Werror=' argument
'-Werror=implicit-function-declaration' is not valid for C++

-- 
Best regards,
Ivan



More information about the R-SIG-Debian mailing list