sousasag / ARES

ARES - Automatic Routine for line Equivalent widths in stellar Spectra

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Compile and run for first time in Ubuntu 16.04 with GSL 2.1

jtmyles opened this issue · comments

Issue: Compile time error due to GSL 2 difference. GSL 2 replaces the Jacobian J from gsl_multifit_fdfsolver with the gradient function J^T f.

In file included from ARES_v2.c:47:0: areslib.h in function ‘fitngauss’: areslib.h:599:24: error: ‘gsl_multifit_fdfsolver {aka struct <anonymous>} has no member named ‘J’ gsl_multifit_covar (s_>J, 0.0, covar);

Solution: Replace areslib_gsl2.h with areslib.h
$ mv areslib_gsl2.h areslib.h

Issue: Run time error due to missing library link.

./ARES: error while loading shared libraries: libgsl.so19: cannot open shared object file: No such file or directory

Solution: append the lib directory containing gsl lib files to LD_LIBRARY_PATH. For example, in ~/.bashrc, add

LD_LIBRARY_PATH=/usr/local/lib
export LD_LIBRARY_PATH

(if GSL was installed to a non-default prefix, then LD_LIBRARY_PATH would have to be adjusted accordingly)