r-spatial / sf

Simple Features for R
https://r-spatial.github.io/sf/
Other
1.33k stars 293 forks source link

Undefined symbol during compilation and loading of sf #2373

Closed ramiromagno closed 5 months ago

ramiromagno commented 5 months ago

Hi Edzer,

I've recently updated my Archlinux and I have the following system library versions:

I was trying to reinstall sf and terra and I am getting this compilation warnings about undefined symbols. I've browsed through some of the issues in this repository and I noticed that you mentioned that having multiple GDAL, GEOS and/or PROJ versions might be the issue but I don't have multiple versions.

Any help is appreciated! Thank you.

install.packages("sf")
#> Installing package into '/home/rmagno/R/x86_64-pc-linux-gnu-library/4.3'
#> (as 'lib' is unspecified)
library(sf)
#> Warning in CPL_gdal_init(): GDAL Error 1: /usr/lib/gdalplugins/ogr_Arrow.so:
#> undefined symbol:
#> _ZNK5arrow16KeyValueMetadata3GetERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE

#> Warning in CPL_gdal_init(): GDAL Error 1: /usr/lib/gdalplugins/ogr_Arrow.so:
#> undefined symbol:
#> _ZNK5arrow16KeyValueMetadata3GetERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE
#> Warning in CPL_gdal_init(): GDAL Error 1: /usr/lib/gdalplugins/ogr_Parquet.so:
#> undefined symbol:
#> _ZNK5arrow16KeyValueMetadata8ContainsERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE

#> Warning in CPL_gdal_init(): GDAL Error 1: /usr/lib/gdalplugins/ogr_Parquet.so:
#> undefined symbol:
#> _ZNK5arrow16KeyValueMetadata8ContainsERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE
#> Warning in CPL_gdal_init(): GDAL Error 1: /usr/lib/gdalplugins/ogr_Arrow.so:
#> undefined symbol:
#> _ZNK5arrow16KeyValueMetadata3GetERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE

#> Warning in CPL_gdal_init(): GDAL Error 1: /usr/lib/gdalplugins/ogr_Arrow.so:
#> undefined symbol:
#> _ZNK5arrow16KeyValueMetadata3GetERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE
#> Warning in CPL_gdal_init(): GDAL Error 1: /usr/lib/gdalplugins/ogr_Parquet.so:
#> undefined symbol:
#> _ZNK5arrow16KeyValueMetadata8ContainsERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE

#> Warning in CPL_gdal_init(): GDAL Error 1: /usr/lib/gdalplugins/ogr_Parquet.so:
#> undefined symbol:
#> _ZNK5arrow16KeyValueMetadata8ContainsERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE
#> Linking to GEOS 3.12.0, GDAL 3.8.4, PROJ 9.4.0; sf_use_s2() is TRUE
sessioninfo::session_info()
#> ─ Session info ───────────────────────────────────────────────────────────────
#>  setting  value
#>  version  R version 4.3.3 (2024-02-29)
#>  os       Arch Linux
#>  system   x86_64, linux-gnu
#>  ui       X11
#>  language (EN)
#>  collate  en_US.UTF-8
#>  ctype    en_US.UTF-8
#>  tz       Europe/Lisbon
#>  date     2024-04-02
#>  pandoc   3.1.1 @ /usr/lib/rstudio/resources/app/bin/quarto/bin/tools/ (via rmarkdown)
#> 
#> ─ Packages ───────────────────────────────────────────────────────────────────
#>  package     * version date (UTC) lib source
#>  class         7.3-22  2023-05-03 [2] CRAN (R 4.3.3)
#>  classInt      0.4-10  2023-09-05 [1] CRAN (R 4.3.1)
#>  cli           3.6.2   2023-12-11 [1] CRAN (R 4.3.3)
#>  DBI           1.2.2   2024-02-16 [1] CRAN (R 4.3.3)
#>  digest        0.6.35  2024-03-11 [1] CRAN (R 4.3.3)
#>  e1071         1.7-14  2023-12-06 [1] CRAN (R 4.3.3)
#>  evaluate      0.23    2023-11-01 [1] CRAN (R 4.3.3)
#>  fastmap       1.1.1   2023-02-24 [1] CRAN (R 4.3.1)
#>  fs            1.6.3   2023-07-20 [1] CRAN (R 4.3.1)
#>  glue          1.7.0   2024-01-09 [1] CRAN (R 4.3.3)
#>  htmltools     0.5.7   2023-11-03 [1] CRAN (R 4.3.3)
#>  KernSmooth    2.23-22 2023-07-10 [1] CRAN (R 4.3.1)
#>  knitr         1.45    2023-10-30 [1] CRAN (R 4.3.3)
#>  lifecycle     1.0.4   2023-11-07 [1] CRAN (R 4.3.3)
#>  magrittr      2.0.3   2022-03-30 [1] CRAN (R 4.3.1)
#>  proxy         0.4-27  2022-06-09 [1] CRAN (R 4.3.1)
#>  purrr         1.0.2   2023-08-10 [1] CRAN (R 4.3.1)
#>  R.cache       0.16.0  2022-07-21 [1] CRAN (R 4.3.1)
#>  R.methodsS3   1.8.2   2022-06-13 [1] CRAN (R 4.3.1)
#>  R.oo          1.26.0  2024-01-24 [1] CRAN (R 4.3.3)
#>  R.utils       2.12.3  2023-11-18 [1] CRAN (R 4.3.3)
#>  Rcpp          1.0.12  2024-01-09 [1] CRAN (R 4.3.3)
#>  reprex        2.1.0   2024-01-11 [1] CRAN (R 4.3.3)
#>  rlang         1.1.3   2024-01-10 [1] CRAN (R 4.3.3)
#>  rmarkdown     2.26    2024-03-05 [1] CRAN (R 4.3.3)
#>  rstudioapi    0.15.0  2023-07-07 [1] CRAN (R 4.3.1)
#>  sessioninfo   1.2.2   2021-12-06 [1] CRAN (R 4.3.1)
#>  sf          * 1.0-16  2024-03-24 [1] CRAN (R 4.3.3)
#>  styler        1.10.2  2023-08-29 [1] CRAN (R 4.3.1)
#>  units         0.8-5   2023-11-28 [1] CRAN (R 4.3.3)
#>  vctrs         0.6.5   2023-12-01 [1] CRAN (R 4.3.3)
#>  withr         3.0.0   2024-01-16 [1] CRAN (R 4.3.3)
#>  xfun          0.42    2024-02-08 [1] CRAN (R 4.3.3)
#>  yaml          2.3.8   2023-12-11 [1] CRAN (R 4.3.3)
#> 
#>  [1] /home/rmagno/R/x86_64-pc-linux-gnu-library/4.3
#>  [2] /usr/lib/R/library
#> 
#> ──────────────────────────────────────────────────────────────────────────────

Created on 2024-04-02 with reprex v2.1.0

Standard output and standard error ``` sh trying URL 'https://cran.rstudio.com/src/contrib/sf_1.0-16.tar.gz' Content type 'application/x-gzip' length 3493756 bytes (3.3 MB) ================================================== downloaded 3.3 MB * installing *source* package ‘sf’ ... ** package ‘sf’ successfully unpacked and MD5 sums checked ** using staged installation configure: CC: gcc configure: CXX: g++ -std=gnu++17 checking for gdal-config... /usr/bin/gdal-config checking gdal-config usability... yes configure: GDAL: 3.8.4 checking GDAL version >= 2.0.1... yes checking for gcc... gcc checking whether the C compiler works... yes checking for C compiler default output file name... a.out checking for suffix of executables... checking whether we are cross compiling... no checking for suffix of object files... o checking whether the compiler supports GNU C... yes checking whether gcc accepts -g... yes checking for gcc option to enable C11 features... none needed checking for stdio.h... yes checking for stdlib.h... yes checking for string.h... yes checking for inttypes.h... yes checking for stdint.h... yes checking for strings.h... yes checking for sys/stat.h... yes checking for sys/types.h... yes checking for unistd.h... yes checking for gdal.h... yes checking GDAL: linking with --libs only... yes checking GDAL: /usr/share/gdal/pcs.csv readable... no checking GDAL: checking whether PROJ is available for linking:... yes checking GDAL: checking whether PROJ is available for running:... yes configure: GDAL: 3.8.4 configure: pkg-config proj exists, will use it configure: using proj.h. configure: PROJ: 9.4.0 checking PROJ: checking whether PROJ and sqlite3 are available for linking:... yes checking for geos-config... /usr/bin/geos-config checking geos-config usability... yes configure: GEOS: 3.12.0 checking GEOS version >= 3.4.0... yes checking for geos_c.h... yes checking geos: linking with -L/usr/lib -lgeos_c... yes configure: Package CPP flags: -DHAVE_PROJ_H -I/usr/include -I/usr/include configure: Package LIBS: -lproj -L/usr/lib -lgdal -L/usr/lib -lgeos_c configure: creating ./config.status config.status: creating src/Makevars ** libs using C++ compiler: ‘g++ (GCC) 13.2.1 20230801’ g++ -std=gnu++17 -I"/usr/include/R/" -DNDEBUG -DHAVE_PROJ_H -I/usr/include -I/usr/include -I'/home/rmagno/R/x86_64-pc-linux-gnu-library/4.3/Rcpp/include' -I/usr/local/include -fpic -march=x86-64 -mtune=generic -O2 -pipe -fno-plt -fexceptions -Wp,-D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security -fstack-clash-protection -fcf-protection -Wp,-D_GLIBCXX_ASSERTIONS -g -ffile-prefix-map=/build/r/src=/usr/src/debug/r -flto=auto -ffat-lto-objects -c RcppExports.cpp -o RcppExports.o g++ -std=gnu++17 -I"/usr/include/R/" -DNDEBUG -DHAVE_PROJ_H -I/usr/include -I/usr/include -I'/home/rmagno/R/x86_64-pc-linux-gnu-library/4.3/Rcpp/include' -I/usr/local/include -fpic -march=x86-64 -mtune=generic -O2 -pipe -fno-plt -fexceptions -Wp,-D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security -fstack-clash-protection -fcf-protection -Wp,-D_GLIBCXX_ASSERTIONS -g -ffile-prefix-map=/build/r/src=/usr/src/debug/r -flto=auto -ffat-lto-objects -c bbox.cpp -o bbox.o g++ -std=gnu++17 -I"/usr/include/R/" -DNDEBUG -DHAVE_PROJ_H -I/usr/include -I/usr/include -I'/home/rmagno/R/x86_64-pc-linux-gnu-library/4.3/Rcpp/include' -I/usr/local/include -fpic -march=x86-64 -mtune=generic -O2 -pipe -fno-plt -fexceptions -Wp,-D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security -fstack-clash-protection -fcf-protection -Wp,-D_GLIBCXX_ASSERTIONS -g -ffile-prefix-map=/build/r/src=/usr/src/debug/r -flto=auto -ffat-lto-objects -c gdal.cpp -o gdal.o g++ -std=gnu++17 -I"/usr/include/R/" -DNDEBUG -DHAVE_PROJ_H -I/usr/include -I/usr/include -I'/home/rmagno/R/x86_64-pc-linux-gnu-library/4.3/Rcpp/include' -I/usr/local/include -fpic -march=x86-64 -mtune=generic -O2 -pipe -fno-plt -fexceptions -Wp,-D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security -fstack-clash-protection -fcf-protection -Wp,-D_GLIBCXX_ASSERTIONS -g -ffile-prefix-map=/build/r/src=/usr/src/debug/r -flto=auto -ffat-lto-objects -c gdal_geom.cpp -o gdal_geom.o g++ -std=gnu++17 -I"/usr/include/R/" -DNDEBUG -DHAVE_PROJ_H -I/usr/include -I/usr/include -I'/home/rmagno/R/x86_64-pc-linux-gnu-library/4.3/Rcpp/include' -I/usr/local/include -fpic -march=x86-64 -mtune=generic -O2 -pipe -fno-plt -fexceptions -Wp,-D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security -fstack-clash-protection -fcf-protection -Wp,-D_GLIBCXX_ASSERTIONS -g -ffile-prefix-map=/build/r/src=/usr/src/debug/r -flto=auto -ffat-lto-objects -c gdal_read.cpp -o gdal_read.o g++ -std=gnu++17 -I"/usr/include/R/" -DNDEBUG -DHAVE_PROJ_H -I/usr/include -I/usr/include -I'/home/rmagno/R/x86_64-pc-linux-gnu-library/4.3/Rcpp/include' -I/usr/local/include -fpic -march=x86-64 -mtune=generic -O2 -pipe -fno-plt -fexceptions -Wp,-D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security -fstack-clash-protection -fcf-protection -Wp,-D_GLIBCXX_ASSERTIONS -g -ffile-prefix-map=/build/r/src=/usr/src/debug/r -flto=auto -ffat-lto-objects -c gdal_read_stream.cpp -o gdal_read_stream.o g++ -std=gnu++17 -I"/usr/include/R/" -DNDEBUG -DHAVE_PROJ_H -I/usr/include -I/usr/include -I'/home/rmagno/R/x86_64-pc-linux-gnu-library/4.3/Rcpp/include' -I/usr/local/include -fpic -march=x86-64 -mtune=generic -O2 -pipe -fno-plt -fexceptions -Wp,-D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security -fstack-clash-protection -fcf-protection -Wp,-D_GLIBCXX_ASSERTIONS -g -ffile-prefix-map=/build/r/src=/usr/src/debug/r -flto=auto -ffat-lto-objects -c gdal_utils.cpp -o gdal_utils.o g++ -std=gnu++17 -I"/usr/include/R/" -DNDEBUG -DHAVE_PROJ_H -I/usr/include -I/usr/include -I'/home/rmagno/R/x86_64-pc-linux-gnu-library/4.3/Rcpp/include' -I/usr/local/include -fpic -march=x86-64 -mtune=generic -O2 -pipe -fno-plt -fexceptions -Wp,-D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security -fstack-clash-protection -fcf-protection -Wp,-D_GLIBCXX_ASSERTIONS -g -ffile-prefix-map=/build/r/src=/usr/src/debug/r -flto=auto -ffat-lto-objects -c gdal_write.cpp -o gdal_write.o g++ -std=gnu++17 -I"/usr/include/R/" -DNDEBUG -DHAVE_PROJ_H -I/usr/include -I/usr/include -I'/home/rmagno/R/x86_64-pc-linux-gnu-library/4.3/Rcpp/include' -I/usr/local/include -fpic -march=x86-64 -mtune=generic -O2 -pipe -fno-plt -fexceptions -Wp,-D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security -fstack-clash-protection -fcf-protection -Wp,-D_GLIBCXX_ASSERTIONS -g -ffile-prefix-map=/build/r/src=/usr/src/debug/r -flto=auto -ffat-lto-objects -c geos.cpp -o geos.o g++ -std=gnu++17 -I"/usr/include/R/" -DNDEBUG -DHAVE_PROJ_H -I/usr/include -I/usr/include -I'/home/rmagno/R/x86_64-pc-linux-gnu-library/4.3/Rcpp/include' -I/usr/local/include -fpic -march=x86-64 -mtune=generic -O2 -pipe -fno-plt -fexceptions -Wp,-D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security -fstack-clash-protection -fcf-protection -Wp,-D_GLIBCXX_ASSERTIONS -g -ffile-prefix-map=/build/r/src=/usr/src/debug/r -flto=auto -ffat-lto-objects -c hex.cpp -o hex.o g++ -std=gnu++17 -I"/usr/include/R/" -DNDEBUG -DHAVE_PROJ_H -I/usr/include -I/usr/include -I'/home/rmagno/R/x86_64-pc-linux-gnu-library/4.3/Rcpp/include' -I/usr/local/include -fpic -march=x86-64 -mtune=generic -O2 -pipe -fno-plt -fexceptions -Wp,-D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security -fstack-clash-protection -fcf-protection -Wp,-D_GLIBCXX_ASSERTIONS -g -ffile-prefix-map=/build/r/src=/usr/src/debug/r -flto=auto -ffat-lto-objects -c mdim.cpp -o mdim.o g++ -std=gnu++17 -I"/usr/include/R/" -DNDEBUG -DHAVE_PROJ_H -I/usr/include -I/usr/include -I'/home/rmagno/R/x86_64-pc-linux-gnu-library/4.3/Rcpp/include' -I/usr/local/include -fpic -march=x86-64 -mtune=generic -O2 -pipe -fno-plt -fexceptions -Wp,-D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security -fstack-clash-protection -fcf-protection -Wp,-D_GLIBCXX_ASSERTIONS -g -ffile-prefix-map=/build/r/src=/usr/src/debug/r -flto=auto -ffat-lto-objects -c ops.cpp -o ops.o g++ -std=gnu++17 -I"/usr/include/R/" -DNDEBUG -DHAVE_PROJ_H -I/usr/include -I/usr/include -I'/home/rmagno/R/x86_64-pc-linux-gnu-library/4.3/Rcpp/include' -I/usr/local/include -fpic -march=x86-64 -mtune=generic -O2 -pipe -fno-plt -fexceptions -Wp,-D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security -fstack-clash-protection -fcf-protection -Wp,-D_GLIBCXX_ASSERTIONS -g -ffile-prefix-map=/build/r/src=/usr/src/debug/r -flto=auto -ffat-lto-objects -c polygonize.cpp -o polygonize.o g++ -std=gnu++17 -I"/usr/include/R/" -DNDEBUG -DHAVE_PROJ_H -I/usr/include -I/usr/include -I'/home/rmagno/R/x86_64-pc-linux-gnu-library/4.3/Rcpp/include' -I/usr/local/include -fpic -march=x86-64 -mtune=generic -O2 -pipe -fno-plt -fexceptions -Wp,-D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security -fstack-clash-protection -fcf-protection -Wp,-D_GLIBCXX_ASSERTIONS -g -ffile-prefix-map=/build/r/src=/usr/src/debug/r -flto=auto -ffat-lto-objects -c proj.cpp -o proj.o g++ -std=gnu++17 -I"/usr/include/R/" -DNDEBUG -DHAVE_PROJ_H -I/usr/include -I/usr/include -I'/home/rmagno/R/x86_64-pc-linux-gnu-library/4.3/Rcpp/include' -I/usr/local/include -fpic -march=x86-64 -mtune=generic -O2 -pipe -fno-plt -fexceptions -Wp,-D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security -fstack-clash-protection -fcf-protection -Wp,-D_GLIBCXX_ASSERTIONS -g -ffile-prefix-map=/build/r/src=/usr/src/debug/r -flto=auto -ffat-lto-objects -c proj_info.cpp -o proj_info.o g++ -std=gnu++17 -I"/usr/include/R/" -DNDEBUG -DHAVE_PROJ_H -I/usr/include -I/usr/include -I'/home/rmagno/R/x86_64-pc-linux-gnu-library/4.3/Rcpp/include' -I/usr/local/include -fpic -march=x86-64 -mtune=generic -O2 -pipe -fno-plt -fexceptions -Wp,-D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security -fstack-clash-protection -fcf-protection -Wp,-D_GLIBCXX_ASSERTIONS -g -ffile-prefix-map=/build/r/src=/usr/src/debug/r -flto=auto -ffat-lto-objects -c raster2sf.cpp -o raster2sf.o g++ -std=gnu++17 -I"/usr/include/R/" -DNDEBUG -DHAVE_PROJ_H -I/usr/include -I/usr/include -I'/home/rmagno/R/x86_64-pc-linux-gnu-library/4.3/Rcpp/include' -I/usr/local/include -fpic -march=x86-64 -mtune=generic -O2 -pipe -fno-plt -fexceptions -Wp,-D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security -fstack-clash-protection -fcf-protection -Wp,-D_GLIBCXX_ASSERTIONS -g -ffile-prefix-map=/build/r/src=/usr/src/debug/r -flto=auto -ffat-lto-objects -c sfc-sfg.cpp -o sfc-sfg.o g++ -std=gnu++17 -I"/usr/include/R/" -DNDEBUG -DHAVE_PROJ_H -I/usr/include -I/usr/include -I'/home/rmagno/R/x86_64-pc-linux-gnu-library/4.3/Rcpp/include' -I/usr/local/include -fpic -march=x86-64 -mtune=generic -O2 -pipe -fno-plt -fexceptions -Wp,-D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security -fstack-clash-protection -fcf-protection -Wp,-D_GLIBCXX_ASSERTIONS -g -ffile-prefix-map=/build/r/src=/usr/src/debug/r -flto=auto -ffat-lto-objects -c signed_area.cpp -o signed_area.o g++ -std=gnu++17 -I"/usr/include/R/" -DNDEBUG -DHAVE_PROJ_H -I/usr/include -I/usr/include -I'/home/rmagno/R/x86_64-pc-linux-gnu-library/4.3/Rcpp/include' -I/usr/local/include -fpic -march=x86-64 -mtune=generic -O2 -pipe -fno-plt -fexceptions -Wp,-D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security -fstack-clash-protection -fcf-protection -Wp,-D_GLIBCXX_ASSERTIONS -g -ffile-prefix-map=/build/r/src=/usr/src/debug/r -flto=auto -ffat-lto-objects -c stars.cpp -o stars.o g++ -std=gnu++17 -I"/usr/include/R/" -DNDEBUG -DHAVE_PROJ_H -I/usr/include -I/usr/include -I'/home/rmagno/R/x86_64-pc-linux-gnu-library/4.3/Rcpp/include' -I/usr/local/include -fpic -march=x86-64 -mtune=generic -O2 -pipe -fno-plt -fexceptions -Wp,-D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security -fstack-clash-protection -fcf-protection -Wp,-D_GLIBCXX_ASSERTIONS -g -ffile-prefix-map=/build/r/src=/usr/src/debug/r -flto=auto -ffat-lto-objects -c wkb.cpp -o wkb.o g++ -std=gnu++17 -I"/usr/include/R/" -DNDEBUG -DHAVE_PROJ_H -I/usr/include -I/usr/include -I'/home/rmagno/R/x86_64-pc-linux-gnu-library/4.3/Rcpp/include' -I/usr/local/include -fpic -march=x86-64 -mtune=generic -O2 -pipe -fno-plt -fexceptions -Wp,-D_FORTIFY_SOURCE=2 -Wformat -Werror=format-security -fstack-clash-protection -fcf-protection -Wp,-D_GLIBCXX_ASSERTIONS -g -ffile-prefix-map=/build/r/src=/usr/src/debug/r -flto=auto -ffat-lto-objects -c zm_range.cpp -o zm_range.o g++ -std=gnu++17 -shared -L/usr/lib64/R/lib -Wl,-O1 -Wl,--sort-common -Wl,--as-needed -Wl,-z,relro -Wl,-z,now -Wl,-z,pack-relative-relocs -flto=auto -o sf.so RcppExports.o bbox.o gdal.o gdal_geom.o gdal_read.o gdal_read_stream.o gdal_utils.o gdal_write.o geos.o hex.o mdim.o ops.o polygonize.o proj.o proj_info.o raster2sf.o sfc-sfg.o signed_area.o stars.o wkb.o zm_range.o -lproj -L/usr/lib -lgdal -L/usr/lib -lgeos_c -L/usr/lib64/R/lib -lR installing to /home/rmagno/R/x86_64-pc-linux-gnu-library/4.3/00LOCK-sf/00new/sf/libs ** R ** demo ** inst ** byte-compile and prepare package for lazy loading in method for ‘dbWriteTable’ with signature ‘"PostgreSQLConnection","character","sf"’: no definition for class “PostgreSQLConnection” in method for ‘dbDataType’ with signature ‘"PostgreSQLConnection","sf"’: no definition for class “PostgreSQLConnection” in method for ‘coerce’ with signature ‘"Spatial","sf"’: no definition for class “Spatial” in method for ‘coerce’ with signature ‘"Spatial","sfc"’: no definition for class “Spatial” in method for ‘coerce’ with signature ‘"sf","Spatial"’: no definition for class “Spatial” in method for ‘coerce’ with signature ‘"sfc","Spatial"’: no definition for class “Spatial” in method for ‘coerce’ with signature ‘"XY","Spatial"’: no definition for class “Spatial” in method for ‘coerce’ with signature ‘"crs","CRS"’: no definition for class “CRS” in method for ‘coerce’ with signature ‘"sgbp","sparseMatrix"’: no definition for class “sparseMatrix” ** help *** installing help indices *** copying figures ** building package indices ** installing vignettes ** testing if installed package can be loaded from temporary location Warning in CPL_gdal_init() : GDAL Error 1: /usr/lib/gdalplugins/ogr_Arrow.so: undefined symbol: _ZNK5arrow16KeyValueMetadata3GetERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE Warning in CPL_gdal_init() : GDAL Error 1: /usr/lib/gdalplugins/ogr_Arrow.so: undefined symbol: _ZNK5arrow16KeyValueMetadata3GetERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE Warning in CPL_gdal_init() : GDAL Error 1: /usr/lib/gdalplugins/ogr_Parquet.so: undefined symbol: _ZNK5arrow16KeyValueMetadata8ContainsERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE Warning in CPL_gdal_init() : GDAL Error 1: /usr/lib/gdalplugins/ogr_Parquet.so: undefined symbol: _ZNK5arrow16KeyValueMetadata8ContainsERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE Warning in CPL_gdal_init() : GDAL Error 1: /usr/lib/gdalplugins/ogr_Arrow.so: undefined symbol: _ZNK5arrow16KeyValueMetadata3GetERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE Warning in CPL_gdal_init() : GDAL Error 1: /usr/lib/gdalplugins/ogr_Arrow.so: undefined symbol: _ZNK5arrow16KeyValueMetadata3GetERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE Warning in CPL_gdal_init() : GDAL Error 1: /usr/lib/gdalplugins/ogr_Parquet.so: undefined symbol: _ZNK5arrow16KeyValueMetadata8ContainsERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE Warning in CPL_gdal_init() : GDAL Error 1: /usr/lib/gdalplugins/ogr_Parquet.so: undefined symbol: _ZNK5arrow16KeyValueMetadata8ContainsERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE ** checking absolute paths in shared objects and dynamic libraries ** testing if installed package can be loaded from final location Warning in CPL_gdal_init() : GDAL Error 1: /usr/lib/gdalplugins/ogr_Arrow.so: undefined symbol: _ZNK5arrow16KeyValueMetadata3GetERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE Warning in CPL_gdal_init() : GDAL Error 1: /usr/lib/gdalplugins/ogr_Arrow.so: undefined symbol: _ZNK5arrow16KeyValueMetadata3GetERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE Warning in CPL_gdal_init() : GDAL Error 1: /usr/lib/gdalplugins/ogr_Parquet.so: undefined symbol: _ZNK5arrow16KeyValueMetadata8ContainsERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE Warning in CPL_gdal_init() : GDAL Error 1: /usr/lib/gdalplugins/ogr_Parquet.so: undefined symbol: _ZNK5arrow16KeyValueMetadata8ContainsERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE Warning in CPL_gdal_init() : GDAL Error 1: /usr/lib/gdalplugins/ogr_Arrow.so: undefined symbol: _ZNK5arrow16KeyValueMetadata3GetERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE Warning in CPL_gdal_init() : GDAL Error 1: /usr/lib/gdalplugins/ogr_Arrow.so: undefined symbol: _ZNK5arrow16KeyValueMetadata3GetERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE Warning in CPL_gdal_init() : GDAL Error 1: /usr/lib/gdalplugins/ogr_Parquet.so: undefined symbol: _ZNK5arrow16KeyValueMetadata8ContainsERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE Warning in CPL_gdal_init() : GDAL Error 1: /usr/lib/gdalplugins/ogr_Parquet.so: undefined symbol: _ZNK5arrow16KeyValueMetadata8ContainsERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE ** testing if installed package keeps a record of temporary installation path * DONE (sf) The downloaded source packages are in '/tmp/RtmpbwOYXY/downloaded_packages' ```
edzer commented 5 months ago

These are run-time warnings, not compile warnings, but to me they indicate a problem with your GDAL installation. Do they also occur when you start a GDAL binary such as gdaltranslate (on the command line, outside R)?

ramiromagno commented 5 months ago

Thank you! Indeed I get those runtime errors too with:

~> gdal_translate 
ERROR 1: /usr/lib/gdalplugins/ogr_Arrow.so: undefined symbol: _ZNK5arrow16KeyValueMetadata3GetERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE
ERROR 1: /usr/lib/gdalplugins/ogr_Arrow.so: undefined symbol: _ZNK5arrow16KeyValueMetadata3GetERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE
ERROR 1: /usr/lib/gdalplugins/ogr_Parquet.so: undefined symbol: _ZNK5arrow16KeyValueMetadata8ContainsERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE
ERROR 1: /usr/lib/gdalplugins/ogr_Parquet.so: undefined symbol: _ZNK5arrow16KeyValueMetadata8ContainsERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE
Usage: gdal_translate [--help] [--help-general] [--long-usage]
       [-ot {Byte/Int8/Int16/UInt16/UInt32/Int32/UInt64/Int64/Float32/Float64/
             CInt16/CInt32/CFloat32/CFloat64}] [-strict]
       [-if <format>]... [-of <format>]
       [-b <band>] [-mask <band>] [-expand {gray|rgb|rgba}]
       [-outsize <xsize>[%]|0 <ysize>[%]|0] [-tr <xres> <yres>]
       [-ovr <level>|AUTO|AUTO-<n>|NONE]
       [-r {nearest,bilinear,cubic,cubicspline,lanczos,average,mode}]
       [-unscale] [-scale[_bn] [<src_min> <src_max> [<dst_min> <dst_max>]]]... [-exponent[_bn] <exp_val>]...
       [-srcwin <xoff> <yoff> <xsize> <ysize>] [-epo] [-eco]
       [-projwin <ulx> <uly> <lrx> <lry>] [-projwin_srs <srs_def>]
       [-a_srs <srs_def>] [-a_coord_epoch <epoch>]
       [-a_ullr <ulx> <uly> <lrx> <lry>] [-a_nodata <value>]
       [-a_gt <gt0> <gt1> <gt2> <gt3> <gt4> <gt5>]
       [-a_scale <value>] [-a_offset <value>]
       [-nogcp] [-gcp <pixel> <line> <easting> <northing> [<elevation>]]...
       |-colorinterp{_bn} {red|green|blue|alpha|gray|undefined}]
       |-colorinterp {red|green|blue|alpha|gray|undefined},...]
       [-mo <META-TAG>=<VALUE>]... [-q] [-sds]
       [-co <NAME>=<VALUE>]... [-stats] [-norat] [-noxmp]
       [-oo <NAME>=<VALUE>]...
       <src_dataset> <dst_dataset>

FAILURE: No source dataset specified.
edzer commented 5 months ago

So your problem is elsewhere.