igraph 1.3.5 installs fine. The details for the failure with 1.4.0
unable to load shared object ‘…/igraph/libs/igraph.so’: undefined symbol: _ZNSt13runtime_errorC1EPKc
sessionInfo()
R version 3.6.0 (2019-04-26)
Platform: x86_64-redhat-linux-gnu (64-bit)
Running under: Red Hat Enterprise Linux Server 7.9 (Maipo)
Matrix products: default
BLAS/LAPACK: /usr/lib64/R/lib/libRblas.so
locale:
[1] LC_CTYPE=en_US.UTF-8 LC_NUMERIC=C
[3] LC_TIME=en_US.UTF-8 LC_COLLATE=en_US.UTF-8
[5] LC_MONETARY=en_US.UTF-8 LC_MESSAGES=en_US.UTF-8
[7] LC_PAPER=en_US.UTF-8 LC_NAME=C
[9] LC_ADDRESS=C LC_TELEPHONE=C
[11] 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_3.6.0 tools_3.6.0
gcc --version
gcc (GCC) 12.1.1 20220628 (Red Hat 12.1.1-3)
Copyright (C) 2022 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
strings /usr/lib64/libstdc++.so.6 | grep LIBCXX
GLIBCXX_3.4
GLIBCXX_3.4.1
GLIBCXX_3.4.2
GLIBCXX_3.4.3
GLIBCXX_3.4.4
GLIBCXX_3.4.5
GLIBCXX_3.4.6
GLIBCXX_3.4.7
GLIBCXX_3.4.8
GLIBCXX_3.4.9
GLIBCXX_3.4.10
GLIBCXX_3.4.11
GLIBCXX_3.4.12
GLIBCXX_3.4.13
GLIBCXX_3.4.14
GLIBCXX_3.4.15
GLIBCXX_3.4.16
GLIBCXX_3.4.17
GLIBCXX_3.4.18
GLIBCXX_3.4.19
GLIBCXX_DEBUG_MESSAGE_LENGTH
1 Like
Sorry about that. This problem only shows up on a few platforms, so we didn’t catch it before 1.4.0 was published.
I will be fixed in the next release, version 1.4.1, expected to be submitted to CRAN soon.
opened 04:44AM - 13 Feb 23 UTC
closed 01:22PM - 14 Feb 23 UTC
Hi,
I suspect there are others on Red Hat/CentOS struggling right now, so I'm… reporting on an Linux/CentOS 7.9 installation problem with the recent igraph 1.4.0. Using R 4.2.2, package fails the 'testing if installed package can be loaded from temporary location' validation. FWIW, thus far, there has been no problem installing any of the previous versions of igraph using GCC 10.
I've tried with all officially Red Hat-supported GCC versions. Here is what I get:
gcc/g++/gfortran (GCC) 7.3.1 20180303 (Red Hat 7.3.1-5) and gcc/g++/gfortran (GCC) 8.3.1 20190311 (Red Hat 8.3.1-3) both give:
```
** testing if installed package can be loaded from temporary location
Error: package or namespace load failed for ‘igraph’ in dyn.load(file, DLLpath = DLLpath, ...):
unable to load shared object '/c4/home/henrik/R/x86_64-pc-linux-gnu-library/4.2-CBI-gcc10/00LOCK-igraph/00new/igraph/libs/igraph.so':
/c4/home/henrik/R/x86_64-pc-linux-gnu-library/4.2-CBI-gcc10/00LOCK-igraph/00new/igraph/libs/igraph.so: undefined symbol: _ZSt24__throw_out_of_range_fmtPKcz
Error: loading failed
```
gcc/g++/gfortran (GCC) 9.3.1 20200408 (Red Hat 9.3.1-2), gcc/g++/gfortran (GCC) 10.2.1 20210130 (Red Hat 10.2.1-11), and gcc/g++/gfortran (GCC) 11.2.1 20220127 (Red Hat 11.2.1-9) give:
```
** testing if installed package can be loaded from temporary location
Error: package or namespace load failed for ‘igraph’ in dyn.load(file, DLLpath = DLLpath, ...):
unable to load shared object '/c4/home/henrik/R/x86_64-pc-linux-gnu-library/4.2-CBI-gcc10/00LOCK-igraph/00new/igraph/libs/igraph.so':
/c4/home/henrik/R/x86_64-pc-linux-gnu-library/4.2-CBI-gcc10/00LOCK-igraph/00new/igraph/libs/igraph.so: undefined symbol: _ZNSt13runtime_errorC1EPKc
Error: loading failed
```
# Workaround
I couldn't find anything around the above in the issue tracker, but the good news is that the problem seems to have been fixed in the development version, igraph 1.4.0-9007:
```r
> remotes::install_github("igraph/rigraph")
Downloading GitHub repo igraph/rigraph@HEAD
── R CMD build ───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
✔ checking for file ‘/scratch/henrik/RtmpetO0kM/remotes24152ee46fb6/igraph-rigraph-e6e946c/DESCRIPTION’ (438ms)
─ preparing ‘igraph’:
✔ checking DESCRIPTION meta-information ...
─ cleaning src
─ running ‘cleanup’
─ checking for LF line-endings in source and make files and shell scripts (653ms)
─ checking for empty or unneeded directories
─ building ‘igraph_1.4.0.9007.tar.gz’
Installing package into '/c4/home/henrik/R/x86_64-pc-linux-gnu-library/4.2-CBI-gcc10'
(as 'lib' is unspecified)
...
** R
** demo
** inst
** byte-compile and prepare package for lazy loading
** help
*** installing help indices
** building package indices
** installing vignettes
** testing if installed package can be loaded from temporary location
** checking absolute paths in shared objects and dynamic libraries
** testing if installed package can be loaded from final location
** testing if installed package keeps a record of temporary installation path
* DONE (igraph)
```