Error in install packages about libnetcdf.so.15 not found (Ubuntu 22.04.01): a solution
If you install netcdf library using:
sudo apt-get install libapparmor1 libcurl4-openssl-dev netcdf-bin libnetcdf-dev udunits-bin libudunits2-dev
It will install the current version of libnetcdf in /usr/lib/x86_64-linux-gnu/
It can be seen with :
cd /usr/lib/x86_64-linux-gnu/
ls -al libnetcdf*
-rw-r--r-- 1 root root 1200 sept. 29 2021 libnetcdf.settings
lrwxrwxrwx 1 root root 15 sept. 29 2021 libnetcdf.so -> libnetcdf.so.19
-rw-r--r-- 1 root root 1346880 sept. 29 2021 libnetcdf.so.19
But when you try to install or update tidync package, it will produce an error:
Erreur dans dyn.load(file, DLLpath = DLLpath, ...) :
impossible de charger l'objet partagé '/usr/local/lib/R/site-library/ncdf4/libs/ncdf4.so':
libnetcdf.so.15: cannot open shared object file: No such file or directory
It search for libnetcdf.so.15 which is an outdated version.
The solution is to symlink libnetcdf.so.15 with the most recent version which is itself a symlink !
sudo ln -s /usr/lib/x86_64-linux-gnu/libnetcdf.so /usr/lib/x86_64-linux-gnu/libnetcdf.so.15
And now you can update tidync
Commentaires
Enregistrer un commentaire