c语言 - 无法编译和运行 minisat+ 卫星求解器



我使用的是我们大学系里的一台Cent0S机器。请注意,我没有权限使用我以root用户身份使用的系统。我下载了miniat +zip文件

我提取了zip。根据安装文件,我运行

make rx

但是我得到了以下结果:

Makefile:96: depend.mak: No such file or directory
Making dependencies...
In file included from ./Main.h:23,
                 from <command-line>:0:
ADTs/Int.h:101:17: error: gmp.h: No such file or directory
In file included from ./Main.h:23,
                 from <command-line>:0:
ADTs/Int.h:101:17: error: gmp.h: No such file or directory
In file included from ./Main.h:23,
                 from <command-line>:0:
ADTs/Int.h:101:17: error: gmp.h: No such file or directory
In file included from ./Main.h:23,
                 from <command-line>:0:
ADTs/Int.h:101:17: error: gmp.h: No such file or directory
In file included from ./Main.h:23,
                 from <command-line>:0:
ADTs/Int.h:101:17: error: gmp.h: No such file or directory
In file included from ./Main.h:23,
                 from <command-line>:0:
ADTs/Int.h:101:17: error: gmp.h: No such file or directory
In file included from ./Main.h:23,
                 from <command-line>:0:
ADTs/Int.h:101:17: error: gmp.h: No such file or directory
In file included from ./Main.h:23,
                 from <command-line>:0:
ADTs/Int.h:101:17: error: gmp.h: No such file or directory
In file included from ./Main.h:23,
                 from <command-line>:0:
ADTs/Int.h:101:17: error: gmp.h: No such file or directory
In file included from ./Main.h:23,
                 from <command-line>:0:
ADTs/Int.h:101:17: error: gmp.h: No such file or directory
In file included from ./Main.h:23,
                 from <command-line>:0:
ADTs/Int.h:101:17: error: gmp.h: No such file or directory
In file included from ./Main.h:23,
                 from <command-line>:0:
ADTs/Int.h:101:17: error: gmp.h: No such file or directory
In file included from ./Main.h:23,
                 from <command-line>:0:
ADTs/Int.h:101:17: error: gmp.h: No such file or directory
make: *** [depend.mak] Error 1

我还从github下载了miniat +。

我使用

运行它

使

制作安装

,但我仍然有错误。有人告诉我,我需要安装gmp和gmp-devel?对吗?

可能有帮助:我不确定我是否有root用户的密码,因为我在大学的实验室工作。

有人如何运行miniat +正确吗?

看起来miniat依赖于GNU MP Bignum库(gmp)。您的系统上安装了libgmp吗?


更新:在没有root权限的系统上安装库

由于您在没有root访问权限的大学机器上,您有两个选项:

  1. 让大学的IT人员帮你在机器上安装libgmp。这可能是最简单的方法,这取决于系统管理员的兼容性。

  2. 在超级用户是一个线程讨论如何安装包一个普通用户。在此之后,您仍然需要将库搜索路径(使用-L开关)添加到miniat包的Makefile中的CFLAGS中。

  3. 你可以像这样手工构建libgmp:完成后,还必须像选项#2一样修改minisat-Makefile.

    $ cd 
    $ mkdir opt/gmp
    $ wget ftp://ftp.gnu.org/gnu/gmp/gmp-5.1.2.tar.bz2
    $ tar -xjvf gmp-5.1.2.tar.bz2
    $ cd gmp-5.1.2
    $ ./configure --prefix=~/opt/gmp/ &&
    $ make &&
    // this will install libgmp into /home/your-login/opt/gmp/
    $ make install
    

相关内容

  • 没有找到相关文章

最新更新