Page 1 of 1

Linking external libraries with nrnivmodl

Posted: Thu Feb 02, 2012 10:09 am
by redarrow
Hello,

is there a way of linking an external library (I have included code that uses the GNU scientific library in a MOD-file) when using nrnivmodl? I've been able to accomplish this by recompiling NEURON and defining appropriate environment variables (namely, CFLAGS and LDFLAGS), but it would be nice to do this without having to recompile the full source code.

Thank you in advance,
Daniele

Re: Linking external libraries with nrnivmodl

Posted: Thu Feb 02, 2012 10:49 am
by hines
use
nrnivmodl -incflags "-I... -I.... -Ietcetera" -loadflags "-L... -lfoo"
to add the include flags during compiling and the ld options during linking.

nrnivmodl is a shell script.