安装splint过程中出现错误:recipe for target 'cscanner.o' failed

为当前最终发行版之前的所有版本提供支持
回复
desila
帖子: 6
注册时间: 2018-01-05 15:19
系统: Ubuntu
送出感谢: 1 次
接收感谢: 0

安装splint过程中出现错误:recipe for target 'cscanner.o' failed

#1

帖子 desila » 2018-01-06 21:53

各位大佬好,我在安装deal.ii过程中提示没有splint,然后就去安装splint了。主要步骤如下:
sudo mkdir /usr/local/splint
cd splint-3.1.2
./configure --prefix=/usr/local/splint
make
但是make先是提示cgrammar.c文件中三处缺少分号,添加之后如下所示,出现了两款问题:
Making all in src
make[2]: Entering directory '/home/desila/Downloads/splint-3.1.2/src'
Compiling cgrammar.c...
flex -L cscanner.l
cat flex.head lex.yy.c flex.reset | sed 's/YYSTYPE/cgrammar_YYSTYPE/g' | sed 's/lsllex/cgrammar_lsllex/g' > cscanner.c
Compiling cscanner.c...
In file included from Headers/basic.h:46:0,
from cscanner.c:993:
Headers/globals.h:38:25: error: conflicting types for ‘yyleng’
extern /*@unused@*/ int yyleng;
^
cscanner.c:369:11: note: previous declaration of ‘yyleng’ was here
yy_size_t yyleng;
^
Makefile:1101: recipe for target 'cscanner.o' failed
make[2]: *** [cscanner.o] Error 1
make[2]: Leaving directory '/home/desila/Downloads/splint-3.1.2/src'
Makefile:256: recipe for target 'all-recursive' failed
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory '/home/desila/Downloads/splint-3.1.2'
Makefile:195: recipe for target 'all' failed
make: *** [all] Error 2

请问下大佬们这两个问题:yyleng的前后不一致和recipe for target ** failed该如何解决?
poloshiao
论坛版主
帖子: 18000
注册时间: 2009-08-04 16:33
送出感谢: 21 次
接收感谢: 1914 次

Re: 安装splint过程中出现错误:recipe for target 'cscanner.o' failed

#2

帖子 poloshiao » 2018-01-06 23:37

然后就去安装splint了
https://packages.ubuntu.com/search?suit ... chon=names
套件 splint

安装 splint
sudo apt install splint
desila
帖子: 6
注册时间: 2018-01-05 15:19
系统: Ubuntu
送出感谢: 1 次
接收感谢: 0

Re: 安装splint过程中出现错误:recipe for target 'cscanner.o' failed

#3

帖子 desila » 2018-01-07 14:10

poloshiao 写了:
然后就去安装splint了
https://packages.ubuntu.com/search?suit ... chon=names
套件 splint

安装 splint
sudo apt install splint
谢谢大神,从ubuntu package里边下到了好多要用到的库
回复

回到 “老旧版本支持”