Reputation: 785
I am trying to use the function exp1 and log101 which take long doubles as input and output long doubles in turn. However, when I try to compile the file I get the following error message:
/tmp/ccIvBVbG.o: In function `main':
derivative.c:(.text+0x250): undefined reference to `log101'
collect2: ld returned 1 exit status
I have included math.h library and also provided the -lm option. What is the remedy to this issue? Any help and comments are appreciated.
Thanks
P.S. Compiler is GCC on 32-bit Ubuntu 12.04 LTS
Upvotes: 2
Views: 145
Reputation: 140659
The names of the functions you are trying to use are exp10l
and log10l
. The last character in the name is a lowercase L, not another 1.
Upvotes: 5