Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rpp needs to update to Centos 7 Sysroot for C++11 compatability, which will fix many problems #33

Closed
1 task done
pettyalex opened this issue Aug 23, 2022 · 2 comments
Labels

Comments

@pettyalex
Copy link
Contributor

Solution to issue cannot be found in the documentation.

  • I checked the documentation.

Issue

Hello,

I've run into several issues compiling applications using Rcpp that ultimately are caused by conda's default Centos 6 sysroot not being c++11 compatible. Centos6 is out of support at this point, and many applications have stopped supporting it and no longer will correctly build or run inside of it. In short, the Rcpp conda package needs to use the Centos 7 sysroot (or newer) to build modern applications. This can be pretty easily done according to conda-forge docs here, which will save anyone working on top of the Rcpp conda package a lot of headache.

A specific example is SAIGE, which we worked around a problem caused by a <inttypes.h> header that is not c++11 compatible by setting a compiler flag: saigegit/SAIGE#17. So that readers don't have to click through, the root of that problem is that c++11 changed the specification for <inttypes.h> and made the macros in it unconditionally applied, while c++98 and C99 had those macros defined only if another macro was already defined. This results in a lot of applications that require c++11 or newer failing to build due to undefined macros.

I typically try to fix issues as upstream as possible, and there was a way to fix this inside of Rcpp itself, however the Rcpp maintiners rejected this, and responded firmly that conda / r-cpp are not a supported R or CRAN environment.

This means that the only place to fix this issue is here, by having rcpp (and potentially r-base) depend on the sysroot_linux-64 2.17 system root in conda-forge, which would move to a newer glibc / c++ implementation and finally be c++11 compatible.

I'm going to take a shot at doing this myself, but I don't have a local conda-forge development environment set up so I'm not going to be able to quickly or easily test it.

I'm attaching my installed packages and env info as the template asks, but this is a general problem and not specific to my single environment.

Installed packages

_libgcc_mutex             0.1                 conda_forge    conda-forge
_openmp_mutex             4.5                       1_gnu    conda-forge
_r-mutex                  1.0.1               anacondar_1    conda-forge
binutils_impl_linux-64    2.36.1               h193b22a_2    conda-forge
binutils_linux-64         2.36                 hf3e587d_9    conda-forge
bwidget                   1.9.14               ha770c72_1    conda-forge
bzip2                     1.0.8                h7f98852_4    conda-forge
c-ares                    1.18.1               h7f98852_0    conda-forge
ca-certificates           2021.10.8            ha878542_0    conda-forge
cairo                     1.16.0            ha61ee94_1011    conda-forge
cget                      0.2.0                    pypi_0    pypi
click                     8.0.3                    pypi_0    pypi
curl                      7.82.0               h2283fc2_0    conda-forge
expat                     2.4.8                h27087fc_0    conda-forge
font-ttf-dejavu-sans-mono 2.37                 hab24e00_0    conda-forge
font-ttf-inconsolata      3.000                h77eed37_0    conda-forge
font-ttf-source-code-pro  2.038                h77eed37_0    conda-forge
font-ttf-ubuntu           0.83                 hab24e00_0    conda-forge
fontconfig                2.14.0               h8e229c2_0    conda-forge
fonts-conda-ecosystem     1                             0    conda-forge
fonts-conda-forge         1                             0    conda-forge
freetype                  2.10.4               h0708190_1    conda-forge
fribidi                   1.0.10               h36c2ea0_0    conda-forge
gcc_impl_linux-64         10.3.0              hf2f2afa_14    conda-forge
gcc_linux-64              10.3.0               hc39de41_9    conda-forge
gettext                   0.19.8.1          h73d1719_1008    conda-forge
gfortran_impl_linux-64    10.3.0              h73f4979_14    conda-forge
gfortran_linux-64         10.3.0               hb09a455_9    conda-forge
graphite2                 1.3.13            h58526e2_1001    conda-forge
gsl                       2.7                  he838d99_0    conda-forge
gxx_impl_linux-64         10.3.0              hf2f2afa_14    conda-forge
gxx_linux-64              10.3.0               h2593f52_9    conda-forge
harfbuzz                  4.2.0                hf9f4e7c_1    conda-forge
icu                       70.1                 h27087fc_0    conda-forge
jbig                      2.1               h7f98852_2003    conda-forge
jpeg                      9e                   h7f98852_0    conda-forge
kernel-headers_linux-64   2.6.32              he073ed8_15    conda-forge
keyutils                  1.6.1                h166bdaf_0    conda-forge
krb5                      1.19.3               h08a2579_0    conda-forge
ld_impl_linux-64          2.36.1               hea4e1c9_2    conda-forge
lerc                      3.0                  h9c3ff4c_0    conda-forge
libblas                   3.9.0           13_linux64_openblas    conda-forge
libcblas                  3.9.0           13_linux64_openblas    conda-forge
libcurl                   7.82.0               h2283fc2_0    conda-forge
libdeflate                1.10                 h7f98852_0    conda-forge
libedit                   3.1.20191231         he28a2e2_2    conda-forge
libev                     4.33                 h516909a_1    conda-forge
libffi                    3.4.2                h7f98852_5    conda-forge
libgcc-devel_linux-64     10.3.0              he6cfe16_14    conda-forge
libgcc-ng                 11.2.0              h1d223b6_14    conda-forge
libgfortran-ng            11.2.0              h69a702a_14    conda-forge
libgfortran5              11.2.0              h5c6108e_14    conda-forge
libgit2                   1.4.2                h4c07d5c_0    conda-forge
libglib                   2.70.2               h174f98d_4    conda-forge
libgomp                   11.2.0              h1d223b6_14    conda-forge
libiconv                  1.16                 h516909a_0    conda-forge
liblapack                 3.9.0           13_linux64_openblas    conda-forge
libnghttp2                1.47.0               he49606f_0    conda-forge
libnsl                    2.0.0                h7f98852_0    conda-forge
libopenblas               0.3.18          pthreads_h8fe5266_0    conda-forge
libpng                    1.6.37               h21135ba_2    conda-forge
libsanitizer              10.3.0              h26c7422_14    conda-forge
libssh2                   1.10.0               ha35d2d1_2    conda-forge
libstdcxx-devel_linux-64  10.3.0              he6cfe16_14    conda-forge
libstdcxx-ng              11.2.0              he4da1e4_14    conda-forge
libtiff                   4.3.0                h542a066_3    conda-forge
libuuid                   2.32.1            h7f98852_1000    conda-forge
libwebp-base              1.2.2                h7f98852_1    conda-forge
libxcb                    1.13              h7f98852_1004    conda-forge
libxml2                   2.9.12               h22db469_2    conda-forge
libzlib                   1.2.11            h166bdaf_1014    conda-forge
lz4-c                     1.9.3                h9c3ff4c_1    conda-forge
make                      4.3                  hd18ef5c_1    conda-forge
ncurses                   6.3                  h9c3ff4c_0    conda-forge
openssl                   3.0.2                h166bdaf_1    conda-forge
pango                     1.50.6               hbd2fdc8_0    conda-forge
pcre                      8.45                 h9c3ff4c_0    conda-forge
pcre2                     10.37                h032f7d1_0    conda-forge
pip                       22.0.4             pyhd8ed1ab_0    conda-forge
pixman                    0.40.0               h36c2ea0_0    conda-forge
pthread-stubs             0.4               h36c2ea0_1001    conda-forge
python                    3.10.4          h2660328_0_cpython    conda-forge
python_abi                3.10                    2_cp310    conda-forge
r-askpass                 1.1               r41hcfec24a_2    conda-forge
r-assertthat              0.2.1             r41hc72bb7e_2    conda-forge
r-backports               1.4.1             r41hcfec24a_0    conda-forge
r-base                    4.1.3                h06d3f91_1    conda-forge
r-base64enc               0.1_3           r41hcfec24a_1004    conda-forge
r-brew                    1.0_7             r41hc72bb7e_0    conda-forge
r-brio                    1.1.3             r41hcfec24a_0    conda-forge
r-cachem                  1.0.6             r41hcfec24a_0    conda-forge
r-callr                   3.7.0             r41hc72bb7e_0    conda-forge
r-cli                     3.2.0             r41h03ef668_0    conda-forge
r-clipr                   0.8.0             r41hc72bb7e_0    conda-forge
r-commonmark              1.8.0             r41h06615bd_0    conda-forge
r-covr                    3.5.1             r41h03ef668_0    conda-forge
r-cpp11                   0.4.2             r41hc72bb7e_0    conda-forge
r-crayon                  1.5.1             r41hc72bb7e_0    conda-forge
r-credentials             1.3.2             r41hc72bb7e_0    conda-forge
r-crosstalk               1.2.0             r41hc72bb7e_0    conda-forge
r-curl                    4.3.2             r41hcfec24a_0    conda-forge
r-desc                    1.4.1             r41hc72bb7e_0    conda-forge
r-devtools                2.4.3             r41hc72bb7e_0    conda-forge
r-diffobj                 0.3.5             r41hcfec24a_0    conda-forge
r-digest                  0.6.29            r41h03ef668_0    conda-forge
r-dt                      0.22              r41hc72bb7e_0    conda-forge
r-ellipsis                0.3.2             r41hcfec24a_0    conda-forge
r-evaluate                0.15              r41hc72bb7e_0    conda-forge
r-fansi                   1.0.3             r41h06615bd_0    conda-forge
r-fastmap                 1.1.0             r41h03ef668_0    conda-forge
r-fs                      1.5.2             r41h03ef668_0    conda-forge
r-gert                    1.5.0             r41h30f61c7_1    conda-forge
r-gh                      1.3.0             r41hc72bb7e_0    conda-forge
r-git2r                   0.30.1            r41hf72769b_0    conda-forge
r-gitcreds                0.1.1             r41hc72bb7e_0    conda-forge
r-glue                    1.6.2             r41h06615bd_0    conda-forge
r-highr                   0.9               r41hc72bb7e_0    conda-forge
r-htmltools               0.5.2             r41h03ef668_0    conda-forge
r-htmlwidgets             1.5.4             r41hc72bb7e_0    conda-forge
r-httr                    1.4.2             r41hc72bb7e_0    conda-forge
r-ini                     0.3.1           r41hc72bb7e_1003    conda-forge
r-jquerylib               0.1.4             r41hc72bb7e_0    conda-forge
r-jsonlite                1.8.0             r41h06615bd_0    conda-forge
r-knitr                   1.38              r41hc72bb7e_0    conda-forge
r-later                   1.2.0             r41h03ef668_0    conda-forge
r-lazyeval                0.2.2             r41hcfec24a_2    conda-forge
r-lifecycle               1.0.1             r41hc72bb7e_0    conda-forge
r-magrittr                2.0.3             r41h06615bd_0    conda-forge
r-memoise                 2.0.1             r41hc72bb7e_0    conda-forge
r-mime                    0.12              r41hcfec24a_0    conda-forge
r-openssl                 2.0.0             r41h1f3e0c5_0    conda-forge
r-pillar                  1.7.0             r41hc72bb7e_0    conda-forge
r-pkgbuild                1.3.1             r41hc72bb7e_0    conda-forge
r-pkgconfig               2.0.3             r41hc72bb7e_1    conda-forge
r-pkgload                 1.2.4             r41h03ef668_0    conda-forge
r-praise                  1.0.0           r41hc72bb7e_1005    conda-forge
r-prettyunits             1.1.1             r41hc72bb7e_1    conda-forge
r-processx                3.5.3             r41h06615bd_0    conda-forge
r-promises                1.2.0.1           r41h03ef668_0    conda-forge
r-ps                      1.6.0             r41hcfec24a_0    conda-forge
r-purrr                   0.3.4             r41hcfec24a_1    conda-forge
r-r6                      2.5.1             r41hc72bb7e_0    conda-forge
r-rappdirs                0.3.3             r41hcfec24a_0    conda-forge
r-rcmdcheck               1.4.0             r41h785f33e_0    conda-forge
r-rcpp                    1.0.8.3           r41h7525677_0    conda-forge
r-rematch2                2.1.2             r41hc72bb7e_1    conda-forge
r-remotes                 2.4.2             r41hc72bb7e_0    conda-forge
r-rex                     1.2.1             r41hc72bb7e_0    conda-forge
r-rlang                   1.0.2             r41h7525677_0    conda-forge
r-roxygen2                7.1.2             r41h03ef668_0    conda-forge
r-rprojroot               2.0.3             r41hc72bb7e_0    conda-forge
r-rstudioapi              0.13              r41hc72bb7e_0    conda-forge
r-rversions               2.1.1             r41hc72bb7e_0    conda-forge
r-sessioninfo             1.2.2             r41hc72bb7e_0    conda-forge
r-stringi                 1.7.6             r41h30a9eb7_2    conda-forge
r-stringr                 1.4.0             r41hc72bb7e_2    conda-forge
r-sys                     3.4               r41hcfec24a_0    conda-forge
r-testthat                3.1.3             r41h7525677_0    conda-forge
r-tibble                  3.1.6             r41hcfec24a_0    conda-forge
r-usethis                 2.1.5             r41hc72bb7e_0    conda-forge
r-utf8                    1.2.2             r41hcfec24a_0    conda-forge
r-vctrs                   0.4.0             r41h7525677_0    conda-forge
r-waldo                   0.4.0             r41hc72bb7e_0    conda-forge
r-whisker                 0.4               r41hc72bb7e_1    conda-forge
r-withr                   2.5.0             r41hc72bb7e_0    conda-forge
r-xfun                    0.30              r41h7525677_0    conda-forge
r-xml2                    1.3.3             r41h03ef668_0    conda-forge
r-xopen                   1.0.0           r41hc72bb7e_1003    conda-forge
r-yaml                    2.3.5             r41h06615bd_0    conda-forge
r-zip                     2.2.0             r41hcfec24a_0    conda-forge
readline                  8.1                  h46c0cb4_0    conda-forge
sed                       4.8                  he412f7d_0    conda-forge
setuptools                62.0.0          py310hff52083_0    conda-forge
six                       1.16.0                   pypi_0    pypi
sqlite                    3.37.1               h4ff8645_0    conda-forge
sysroot_linux-64          2.12                he073ed8_15    conda-forge
tk                        8.6.12               h27826a3_0    conda-forge
tktable                   2.10                 hb7b940f_3    conda-forge
tzdata                    2022a                h191b570_0    conda-forge
wheel                     0.37.1             pyhd8ed1ab_0    conda-forge
xorg-kbproto              1.0.7             h7f98852_1002    conda-forge
xorg-libice               1.0.10               h7f98852_0    conda-forge
xorg-libsm                1.2.3             hd9c2040_1000    conda-forge
xorg-libx11               1.7.2                h7f98852_0    conda-forge
xorg-libxau               1.0.9                h7f98852_0    conda-forge
xorg-libxdmcp             1.1.3                h7f98852_0    conda-forge
xorg-libxext              1.3.4                h7f98852_1    conda-forge
xorg-libxrender           0.9.10            h7f98852_1003    conda-forge
xorg-libxt                1.2.1                h7f98852_2    conda-forge
xorg-renderproto          0.11.1            h7f98852_1002    conda-forge
xorg-xextproto            7.3.0             h7f98852_1002    conda-forge
xorg-xproto               7.0.31            h7f98852_1007    conda-forge
xz                        5.2.5                h516909a_1    conda-forge
zlib                      1.2.11            h166bdaf_1014    conda-forge
zstd                      1.5.2                ha95c52a_0    conda-forge

Environment info

active environment : alex-saige
    active env location : /belowshare/vumcshare/data100t1/home/alex/.conda/envs/alex/envs/alex-saige
            shell level : 2
       user config file : /belowshare/vumcshare/data100t1/home/alex/.condarc
 populated config files : /belowshare/vumcshare/data100t1/home/alex/.condarc
          conda version : 4.11.0
    conda-build version : not installed
         python version : 3.10.2.final.0
       virtual packages : __linux=5.4.0=0
                          __glibc=2.31=0
                          __unix=0=0
                          __archspec=1=x86_64
       base environment : /belowshare/vumcshare/data100t1/home/alex/.conda/envs/alex  (writable)
      conda av data dir : /belowshare/vumcshare/data100t1/home/alex/.conda/envs/alex/etc/conda
  conda av metadata url : None
           channel URLs : https://conda.anaconda.org/conda-forge/linux-64
                          https://conda.anaconda.org/conda-forge/noarch
          package cache : /belowshare/vumcshare/data100t1/home/alex/.conda/envs/alex/pkgs
                          /belowshare/vumcshare/data100t1/home/alex/.conda/pkgs
       envs directories : /belowshare/vumcshare/data100t1/home/alex/.conda/envs/alex/envs
                          /belowshare/vumcshare/data100t1/home/alex/.conda/envs
               platform : linux-64
             user-agent : conda/4.11.0 requests/2.27.1 CPython/3.10.2 Linux/5.4.0-110-generic ubuntu/20.04.4 glibc/2.31
                UID:GID : 1001:1012
             netrc file : None
           offline mode : False
@pettyalex pettyalex added the bug label Aug 23, 2022
@pettyalex pettyalex changed the title Rpp needs to update to Centos 7 Sysroot to get to C++11 and fix many problems Rpp needs to update to Centos 7 Sysroot for C++11 compatability, which will fix many problems Aug 23, 2022
@pettyalex
Copy link
Contributor Author

For some more context on this issue, here's an issue were some conda-forge/core developers discuss the pros / cons of Centos 7, and unfortunately decide to keep the default Centos 6: conda-forge/conda-forge.github.io#1436

@pettyalex
Copy link
Contributor Author

This was resolved when the PR was merged!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant