RcppCore / RcppEigen

Rcpp integration for the Eigen templated linear algebra library
Other
110 stars 40 forks source link

Warnings during installation #110

Closed waynelapierre closed 2 years ago

waynelapierre commented 2 years ago

When installing RcppEigen, I got hundreds of warnings like this one:

../inst/include/Eigen/src/Core/CoreEvaluators.h:90:8:   required from ‘struct Eigen::internal::evaluator<Eigen::Transpose<const Eigen::Block<const Eigen::CwiseBinaryOp<Eigen::internal::scalar_product_op<double, double>, const Eigen::CwiseNullaryOp<Eigen::internal::scalar_constant_op<double>, const Eigen::Matrix<double, -1, 1> >, const Eigen::Block<const Eigen::Matrix<double, -1, -1>, -1, 1, false> >, 1, 1, false> > >’
../inst

My session information is:

R version 4.1.3 (2022-03-10)
Platform: x86_64-redhat-linux-gnu (64-bit)
Running under: Fedora Linux 36 (Workstation Edition)

Matrix products: default
BLAS/LAPACK: /usr/lib64/libflexiblas.so.3.2

locale:
 [1] LC_CTYPE=en_US.UTF-8       LC_NUMERIC=C               LC_TIME=en_US.UTF-8       
 [4] LC_COLLATE=en_US.UTF-8     LC_MONETARY=en_US.UTF-8    LC_MESSAGES=en_US.UTF-8   
 [7] LC_PAPER=en_US.UTF-8       LC_NAME=C                  LC_ADDRESS=C              
[10] LC_TELEPHONE=C             LC_MEASUREMENT=en_US.UTF-8 LC_IDENTIFICATION=C       

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods   base     

loaded via a namespace (and not attached):
[1] compiler_4.1.3 tools_4.1.3  
eddelbuettel commented 2 years ago
  1. It is from upstream code, so please report Eigen warnings at the Eigen repo. RcppEigen is just a messenger wrapping it.

  2. See the CRAN Repository Policy:

Packages should not attempt to disable compiler diagnostics, nor to remove other diagnostic information such as symbols in shared objects.

meaning that in general I cannot suppress that (and even have to remove suppression added upstream as eg in BH).

  1. The usual remedy is to turn the warning off in your system-local file ~/.R/Makevars by disabling the corresponding warning: g++ usually tells you its name. I sometimes use these or a subset of these
PEDANTIC= -DBOOST_NO_AUTO_PTR -Wno-sign-compare -Wno-parentheses -Wno-maybe-uninitialized
XTRAFLAGS=-Wno-misleading-indentation -Wno-unused -Wno-ignored-attributes -Wno-parentheses -Wno-address-of-packed-member

in my CXXFLAGS, CXX11FLAGS, CXX1FLAGS, ...