installation error when downloading R packages (LinuxMint 17.1)


I am trying to install afni on Linux. I am new to Linux, so I have very little knowledge on how things work with it.

When I download the R packaes (using rPkgsInstall -pkgs ALL) I get the following error:

oo Warning: 
   Failed to load with this error message:

Error in dyn.load(ll) : 
  unable to load shared object '/home/galit/abin/':
  /lib/x86_64-linux-gnu/ version `GLIBC_2.23' not found (required by /home/galit/abin/
Calls: source ... withVisible -> eval -> eval -> set_R_io -> dyn.load
Execution halted

I tried to update and install GLIBC, but nothing seemed to work.
I used this setup for installation.
What do you advice me to do?

Thanks you!

That version might not be appropriate for your OS.
What is the output from:

ldd --version

  • rick

Hi Rick,
It says:
ldd (Ubuntu EGLIBC 2.19-0ubuntu6.5) 2.19
It’s from 2014… Is that too old?

Try the openmp_64 package, instead:

@update.afni.binaries -package linux_openmp_64

Then test it with: -check_all

Then you can show us the output from this.

  • rick

Hi Rick,
Here is the whole output:

-------------------------------- general ---------------------------------
architecture:         64bit ELF
system:               Linux
release:              3.13.0-37-generic
version:              #64-Ubuntu SMP Mon Sep 22 21:28:38 UTC 2014
distribution:         LinuxMint 17.1 rebecca
number of CPUs:       8
apparent login shell: tcsh
shell RC file:        .cshrc (exists)

--------------------- AFNI and related program tests ---------------------
which afni           : /home/galit/abin/afni
afni version         : Precompiled binary linux_openmp_64: Oct 12 2018 
                     : AFNI_18.3.01
AFNI_version.txt     : AFNI_18.3.01, linux_openmp_64, Oct 12 2018
which python         : /usr/bin/python
python version       : 2.7.6
which R              : /usr/bin/R
R version            : R version 3.4.4 (2018-03-15) -- "Someone to Lean On"
which tcsh           : /usr/bin/tcsh

instances of various programs found in PATH:
    afni    : 1   (/home/galit/abin/afni)
    R       : 1   (/usr/bin/R)
    python  : 1   (/usr/bin/python2.7)
    python2 : 1   (/usr/bin/python2.7)
    python3 : 1   (/usr/bin/python3.4)

testing ability to start various programs...
    afni                 : success
    suma                 : success
    3dSkullStrip         : FAILURE
        3dSkullStrip: error while loading shared libraries: cannot open shared object file: No such file or directory      : success
    3dAllineate          : success
    3dRSFC               : FAILURE
        3dRSFC: error while loading shared libraries: cannot open shared object file: No such file or directory
    SurfMesh             : success
    3dClustSim           : success

checking for R packages...
    rPkgsInstall -pkgs ALL -check : FAILURE
        oo Warning: 
           These packages are not installed on the computer: afex!
        These packages are not installed on the computer: phia!
        These packages are not installed on the computer: snow!
        These packages are not installed on the computer: nlme!
        These packages are not installed on the computer: lme4!
        These packages are not installed on the computer: paran!
        These packages are not installed on the computer: psych!
        These packages are not installed on the computer: brms!

checking for $HOME files...
    .afnirc                   : found
    .sumarc                   : missing
    .afni/help/all_progs.COMP : missing

------------------------------ python libs -------------------------------
++ module 'PyQt4' found at /usr/lib/python2.7/dist-packages/PyQt4
++ module loaded: PyQt4

-------------------------------- env vars --------------------------------
PATH = /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/home/galit/abin

R_LIBS = /home/galit/R


------------------------------ data checks -------------------------------
data dir : found AFNI_data6   under $HOME
           top history: ... Jun 2018 [gangc]: added 0.BGA and updated 2.3groups
data dir : found AFNI_demos   under $HOME
           top history: ... [pault]: remove rank from FATCAT_DEMO, FAT_MVM_DEMO
data dir : found suma_demo    under $HOME
           top history: .../SUMA_data/Build_tmp on Wed Aug 20 10:04:23 EDT 2014
data dir : found afni_handouts under $HOME
atlas    : found TT_N27+tlrc  under /home/galit/abin

------------------------------ OS specific -------------------------------
which apt-get        : /usr/bin/apt-get
apt-get version      : apt 1.0.1ubuntu2 for amd64 compiled on Oct 28 2014 20:55:14

=========================  summary, please fix:  =========================
*  AFNI programs show FAILURE
*  missing R packages (see rPkgsInstall)
*  consider running "suma -update_env" for .sumarc
*  consider running: apsearch -update_all_afni_help

Linux Mint 17.1 seems to be based on Ubuntu 14, and the
Ubuntu notes include this setup:

sudo apt-get install libxp6 python-qt4 r-base libpng16 libgsl0-dev tcsh
sudo apt-get update

sudo ln -s /usr/lib/x86_64-linux-gnu/ /usr/lib/

The last line is probably what you now need.

  • rick

OK, great. The R package installation seemed to work now. However, when I evaluate the setup, I still get an error that R packages are not installed. That is weird, because the installation seemed to work smoothly. I tried to install each package separately (phia, afex and brms) and got a note for each package that it was successfully installed on the computer (and a few warning messages that seemed irrelevant). But the evaluation still insisted the R programs are not installed! Maybe there is a different way to evaluate the setup?
Thanks a lot.

We are indeed running into some difficulties with the R packages.
It is possible that the R version that comes with your system is not
compatible with the current packages. But just to back up a little,
are you having any trouble running any of the group analysis R
programs? It is possible that you don’t need to worry about it.

  • rick

Hi Rick,
I didn’t get there yet, at the moment I have problems with running 3dSkullStrip. I get an error that does not exist. But when I run again sudo ln -s /usr/lib/x86_64-linux-gnu/ /usr/lib/x86-linux-gnu/ (the command that you suggested to solve the R problem) I get the message:
ln: failed to create symbolic link ‘/usr/lib/x86_64-linux-gnu/’: File exists
I’m not sure what it means or how to proceed from here. What should I do now?
Many thanks again,

Hi Galit,

Your ‘ln’ command should not have the x86 directory in
the destination name, it is just under /usr/lib:

sudo ln -s /usr/lib/x86_64-linux-gnu/ /usr/lib/
  • rick

Hi Rick,
Sorry, my misake in typing here the library name.
Anyway, I get the same error message using 3dSkullStrip - that does not exist. I manually tried to open (in both /usr/lib/ and /usr/lib/x86_64-linux/gnu/), and got a message that the link was broken. I removed the file and re-installed it (using the command lines you suggested on October 15 in this thread). And still the link is broken.
If it helps, running again sudo apt-get install libxp6 python-qt4 r-base libpng16 libgsl0-dev tcsh, I noticed the message “unable to locate package libpng16”. Perhaps that’s where the crux is?

Hi Galit,

That certainly might be the problem. Try to look that
package up on the LinuxMint documentation website.
To verify, what is the output of:

ls -l /usr/lib/x86_64-linux-gnu/libgsl.*

It is possible the package is libgsl-dev, try also:

sudo apt-get install libgsl-dev

Regarding libpng16, I guess you need to see what
is available for libpng, too.

Another option is backing up to the linux_xorg7_64.tgz
package, just to see if that is better.

  • rick

Hi Rick,

This is what I get with ls -l /usr/lib/x86_64-linux-gnu/libgsl.* :

lrwxrwxrwx 1 root root 35 Oct 29 09:34 /usr/lib/x86_64-linux-gnu/ → /usr/lib/x86_64-linux-gnu/
lrwxrwxrwx 1 root root 16 May 6 2017 /usr/lib/x86_64-linux-gnu/ →
-rw-r–r-- 1 root root 2455464 May 6 2017 /usr/lib/x86_64-linux-gnu/

The first line, I suppose is the broken link that I installed.

Still looking for a libpng16 compatible with Mint.


The libpng library should be available three ways. I would try the first way, then work down to the others. libpng16 is the latest version at the moment.

sudo apt-get install libpng16-16
sudo dpkg -i libpng16-16_1.6.26-6_amd64.deb
or from source at , then build with

make check
make install

Thanks, Daniel. The two first ways yielded error messages, but downloading and installing the source seemed to do the job! 3dSkullStrip is now finally running!
Thank you also Rick. I will let you know, when I reach the stage of group analysis, if the R packages properly work (the original motivation of this thread).