Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
482 views
in Technique[技术] by (71.8m points)

c - Where to find "gmp.h"?

I am installing a library, and got this error message:

xxxx@ubuntu$ make
(cd num; make all)
make[1]: Entering directory `/home/xxxx/num'
make[1]: Nothing to be done for `all'.
make[1]: Leaving directory `/home/xxxx/num'
(cd itv; make all)
make[1]: Entering directory `/home/xxxx/itv'
gcc -Wcast-qual -Wswitch -Werror-implicit-function-declaration -Wall -Wextra -Wundef -Wbad-function-cast -Wcast-align -Wstrict-prototypes -Wno-unused -std=c99 -U__STRICT_ANSI__ -O3 -DNDEBUG -I../num -I../apron -I/usr/include -I/usr/include -DNUM_MPQ -c -o itvMPQ.o itv.c
In file included from itv.h:9:0,
             from itv.c:5:
../num/num.h:15:17: fatal error: gmp.h: No such file or directory
compilation terminated.
make[1]: *** [itvMPQ.o] Error 1
make[1]: Leaving directory `/home/xxxx/itv'
make: *** [c] Error 2

So the problem is that it can not find gmp.h, does anyone know where this file is located, and how to make it found by the installer? By the way, at the moment my Makefile points mainly to /usr and /usr/local...

Edit1: After installing libgmp3-dev as suggested, the current error message is ../num/num.h:16:18: fatal error: mpfr.h: No such file or directory, does anyone know which package it is about?

Edit2: I have installed MPFR by following this page, and that did help, now the error message is gmp_caml.c:17:33: fatal error: caml/camlidlruntime.h: No such file or directory, could anyone help?

Edit3: I have done apt-file search camlidlruntime, and it returns camlidl: /usr/lib/ocaml/caml/camlidlruntime.h, but there is no camlidlruntime.h in my folder /usr/lib/ocaml/caml/, how could I check if I have installed dev package of MPFR? and which package it is exactly about?

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

you need to install libgmp3-dev

depends on your linux

yum install  libgmp3-dev

apt-get install  libgmp3-dev

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

Just Browsing Browsing

[2] html - How to create even cell spacing within a

2.1m questions

2.1m answers

60 comments

57.0k users

...