Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
MPC 在这里: http: //www.multiprecision.org/ 我想在 Linux 下用 g++ 编译 C++ 代码,同时安装了 GMP 和 MPFR。关键是我不知道应该在命令行中放置哪些标志进行编译。
您需要与 libmpc 链接:
gcc foo.c -o foo -lmpc
我用 ubuntu 包中的 mpc 测试它:
sudo aptitude install libmpc-dev libmpc2
我的 foo.c 看起来像:
#include "mpc.h" int main() { mpc_t x; mpc_init2 (x, 256); return 0; }