g ++不想让我使用DISLIN进行数据绘图

时间:2019-06-25 16:00:35

标签: c++ compiler-errors g++

今天,由于某些原因,当我尝试使用以下命令编译一些示例代码时,我已经安装了DISLIN并尝试使用DISLIN库绘制一些数据:

g++ -o DISLIN DISLIN.cpp -ldislin -Wall 

结果是:

    /tmp/ccPQdGu2.o: In function `main':
DISLIN.cpp:(.text+0x39): undefined reference to `Dislin::Dislin()'
DISLIN.cpp:(.text+0x118): undefined reference to `Dislin::scrmod(char const*)'
DISLIN.cpp:(.text+0x129): undefined reference to `Dislin::setpag(char const*)'
DISLIN.cpp:(.text+0x13a): undefined reference to `Dislin::metafl(char const*)'
DISLIN.cpp:(.text+0x146): undefined reference to `Dislin::disini()'
DISLIN.cpp:(.text+0x152): undefined reference to `Dislin::pagera()'
DISLIN.cpp:(.text+0x15e): undefined reference to `Dislin::complx()'

etc etc..
collect2: error: ld returned 1 exit status

由于某种原因,他似乎无法识别我的DISLIN功能...

代码头是:

#include <iostream>
#include <cmath>
#include"/usr/local/dislin/dislin.h"
#include"/usr/local/dislin/discpp.h"

因为使用:

#include "dislin.h"

不起作用。

0 个答案:

没有答案