thomasp85 / transformr

Smooth Polygon Transformations
Other
115 stars 12 forks source link

Install on Ubuntu 24.04 failed #15

Open Marc-Girondot opened 1 month ago

Marc-Girondot commented 1 month ago

System: Ubuntu 24.04 R 4.4.1

In R:

devtools::install_github("thomasp85/transformr")

It returns an error (all the logs are at the end of this report): Erreur dans dyn.load(file, DLLpath = DLLpath, ...) : impossible de charger l'objet partagé '/usr/local/lib/R/site-library/sf/libs/sf.so' : libgdal.so.32: cannot open shared object file: No such file or directory

Indeed, I have the last version of libgdal.so installed which is version 34: mgirond@caretta:~$ cd /usr/lib/x86_64-linux-gnu mgirond@caretta:/usr/lib/x86_64-linux-gnu$ ls -a libgdal* libgdal.so libgdal.so.34 libgdal.so.34.3.8.4

Using a hack to symlink 34 to 32 does not work either: sudo ln -s /usr/lib/x86_64-linux-gnu/libgdal.so /usr/lib/x86_64-linux-gnu/libgdal.so.32

will return: Erreur dans dyn.load(file, DLLpath = DLLpath, ...) : impossible de charger l'objet partagé '/usr/local/lib/R/site-library/sf/libs/sf.so' : /usr/local/lib/R/site-library/sf/libs/sf.so: undefined symbol: _ZN18OGRGeometryFactory13createFromWkbEPKvP19OGRSpatialReferencePP11OGRGeometrym13OGRwkbVariant

All the logs are here:

devtools::install_github("thomasp85/transformr") Downloading GitHub repo thomasp85/transformr@HEAD ── R CMD build ────────────────────────────────────────────────────────────────────────── ✔ checking for file ‘/tmp/RtmpaALtTp/remotes85b47a4fd5/thomasp85-transformr-0f7262d/DESCRIPTION’ (361ms) ─ preparing ‘transformr’: ✔ checking DESCRIPTION meta-information ─ cleaning src ─ checking for LF line-endings in source and make files and shell scripts ─ checking for empty or unneeded directories ─ building ‘transformr_0.1.5.9000.tar.gz’

Installation du package dans ‘/usr/local/lib/R/site-library’ (car ‘lib’ n'est pas spécifié)

mgirond@caretta:~$ cd /usr/lib/x86_64-linux-gnu mgirond@caretta:/usr/lib/x86_64-linux-gnu$ ls -a libgdal* libgdal.so libgdal.so.34 libgdal.so.34.3.8.4

mgirond@caretta:/usr/lib/x86_64-linux-gnu$ sudo ln -s /usr/lib/x86_64-linux-gnu/libgdal.so /usr/lib/x86_64-linux-gnu/libgdal.so.32

Erreur dans dyn.load(file, DLLpath = DLLpath, ...) : impossible de charger l'objet partagé '/usr/local/lib/R/site-library/sf/libs/sf.so' : /usr/local/lib/R/site-library/sf/libs/sf.so: undefined symbol: _ZN18OGRGeometryFactory13createFromWkbEPKvP19OGRSpatialReferencePP11OGRGeometrym13OGRwkbVariant Appels : ... asNamespace -> loadNamespace -> library.dynam -> dyn.load Exécution arrêtée

The-Dub commented 1 month ago

Hi,

I got a similar issue installing transformr on a docker container.

hope this helps!