3 replies [Last post]
gijsbert's picture
Joined: 05/14/2014

Hi, I just found out about OpenMx and it is exactly the software I was looking for, which is great! I am so happy it works for R, and it has good documentation.

Unfortunately, using OpenMx is somewhat limited due to the NPSOL library, which only supports Linux versions that use the Gnu C Compiler (GCC) up to version 4.6. But that is not helpful on standard Linux systems, such as Fedora 20, which uses gcc 4.8.

I figured out I can run it on Fedora 20, though, if I do *not* update the software it comes with. So that is what I do now. I run OpenMx in a VirtualBox version of a slightly older Linux system, which is not ideal. For example, I need to be careful not to update gcc to the most current version. I assume it would be the same on other popular Linux distributions (on Arch Linux, they already are at GCC version 4.9).

Are there any suggestions that at least the NPSOL people would be willing to compile their library up the the latest gcc and include it in the NPSOL source packages? That surely must be really easy to do for them, it is just a matter of adding a few files to their code, it does not require and additional software coding. In other words, if the OpenMx team could ask them to help us out, that would be absolutely awesome!!!

Just to show what I mean, I downloaded the NPSOL library code which has the compiled lbnpsol.a file for a number of different versions of GCC, which is good, but only up to version 4.6:



prast's picture
Joined: 08/18/2010
Output of failed installation

I can confirm the issue with npsol in Arch 64bit.
After runnig the source('') command I get:

* installing *source* package ‘OpenMx’ ...
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 we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking for gcc option to support OpenMP... -fopenmp
checking whether gcc is installed... yes
checking build system type... x86_64-unknown-linux-gnu
checking host system type... x86_64-unknown-linux-gnu
checking if gcc accepts -dumpversion option... yes
checking gcc version... 4.9.0
checking for gawk... gawk
checking for inst/npsol/linux/x86_64/gcc4.9/libnpsol.a... no
configure: error: npsol library not found
ERROR: configuration failed for package ‘OpenMx’
* removing ‘/home/philippe/R/x86_64-unknown-linux-gnu-library/3.1/OpenMx’

The downloaded source packages are in
Warning message:
In install.packages(pkgs = c("OpenMx"), repos = repos) :
installation of package ‘OpenMx’ had non-zero exit status

prast's picture
Joined: 08/18/2010

found the solution in thread

Restating Mike Cheungs approach:
1. I went to /tmp/RtmpaonwZU/downloaded_packages and uncompressed the OpenMx.tar.gz file.
2. Open the files and go to inst/npsol/linux/x86_64
3. Copy or rename the gcc4.8 directory to gcc4.9
4. Recompress the OpenMx directory to OpenMx.tar.gz
5. In R, install.packages('local/path/to/newlycreated/OpenMx.tar.gz')

That's it. Worked flawlessly.

RobK's picture
Joined: 04/19/2011
What goes wrong when you try to install?

Hmm, it's unusual for Linux users to have installation problems with OpenMx. The package should be buildable with gcc v4.8. I just successfully installed it for R v3.0.1 under Ubuntu v13.10, using gcc v4.8.1. It was a simple matter of copy-pasting source('') into an R session.

Have you tried installing the package with source(''), and if so, what exactly goes wrong?