主页 > 学习 | 工作 > csync2安装报错&解决

csync2安装报错&解决

跟着linuxtone论坛前辈写的教程,做csync2+inotify同步实验,在安装csync2的时候出现了两个错误。

错误一:

[root@file2 csync2-1.34]# make

yacc  -d `test -f ‘cfgfile_parser.y’ || echo ‘./’`cfgfile_parser.y
/bin/sh: yacc: command not found
make: *** [cfgfile_parser.c] 错误 127

这个错误,报yacc命令么有找到,简单干脆的安装yacc的相关包:

[root@file2 csync2-1.34]# yum -y install yacc*

Loaded plugins: fastestmirror

Loading mirror speeds from cached hostfile

* addons: mirrors.163.com

* base: mirrors.163.com

* extras: mirrors.163.com

* updates: mirrors.163.com

Setting up Install Process

No package yacc* available.

Nothing to do

结果竟然告诉我没有这个包,于是google,知道了,原来是要安装byacc的包,于是:

[root@file2 csync2-1.34]# yum -y install *yacc

Loaded plugins: fastestmirror

Loading mirror speeds from cached hostfile

* addons: mirrors.163.com

* base: mirrors.163.com

* extras: mirrors.163.com

* updates: mirrors.163.com

Setting up Install Process

Resolving Dependencies

–> Running transaction check

—> Package byacc.x86_64 0:1.9-29.2.2 set to be updated

–> Finished Dependency Resolution

Dependencies Resolved

================================================================================

Package          Arch              Version               Repository       Size

================================================================================

Installing:

byacc            x86_64            1.9-29.2.2            base             41 k

Transaction Summary

================================================================================

Install       1 Package(s)

Upgrade       0 Package(s)

之后make clean&&./configure&&make报第二个错误:

/bin/sh /opt/tool/csync2/csync2-1.34/missing –run flex   `test -f cfgfile_scanner.l || echo ‘./’`cfgfile_scanner.l

/opt/tool/csync2/csync2-1.34/missing: line 46: flex: command not found

WARNING: `flex’ is missing on your system.  You should only need it if

you modified a `.l’ file.  You may need the `Flex’ package

in order for those modifications to take effect.  You can get

`Flex’ from any GNU archive site.

sed ‘/^#/ s|\.c|cfgfile_scanner.c|’ .c >cfgfile_scanner.c

sed:无法读取 .c:没有那个文件或目录

make[1]: *** [cfgfile_scanner.c] 错误 2

make[1]: Leaving directory `/opt/tool/csync2/csync2-1.34′

make: *** [all] 错误 2

蛋疼,看了看,有个warning提到flex这个东西,不知道什么东西,习惯性yum:

[root@file2 csync2-1.34]# yum -y install flex

Loaded plugins: fastestmirror

Loading mirror speeds from cached hostfile

* addons: mirrors.163.com

* base: mirrors.163.com

* extras: mirrors.163.com

* updates: mirrors.163.com

Setting up Install Process

Resolving Dependencies

–> Running transaction check

—> Package flex.x86_64 0:2.5.4a-41.fc6 set to be updated

–> Finished Dependency Resolution

Dependencies Resolved

================================================================================

Package        Arch             Version                   Repository      Size

================================================================================

Installing:

flex           x86_64           2.5.4a-41.fc6             base           131 k

Transaction Summary

================================================================================

Install       1 Package(s)

Upgrade       0 Package(s)

丫的,还真有这个东西!安装完成这个flex,然后make clean && ./configure&&make&&make install,果然OK了.

原创文章,转载请注明: 转载自三叶草

本文链接地址:http://www.anjing.me/1294.html

特别声明:商业网站转载需经作者同意,否则视为侵权!

, , ,

评论:1

参与评论
  1. 回复 燕郊 11/07/29

    我座沙发了

发表评论

邮箱地址不会被公开。

*

引用:0

下面所列的是引用到本博客的链接
csync2安装报错&解决 来自 三叶草
顶部