编译时遇到的问题

【版权申明】未经博主同意,谢绝转载!(请尊重原创,博主保留追究权) 

编译时遇到的问题

You must install 'makeinfo' on your build machine

解: 装 texinfo

sudo apt-get install texinfo

_GL_WARN_ON_USE (gets, "gets is a security hole - use fgets instead");

error log:

In file included from clean-temp.h:22:0,
from clean-temp.c:23:
./stdio.h:456:1: error: ‘gets’ undeclared here (not in a function); did you mean ‘fgets’?
_GL_WARN_ON_USE (gets, “gets is a security hole - use fgets instead”);

解:

从原来的
_GL_WARN_ON_USE (gets, "gets is a security hole - use fgets instead");

修改为:(添加了第一行和第三行)
#if defined(__GLIBC__) && !defined(__UCLIBC__) && !__GLIBC_PREREQ(2, 16)
_GL_WARN_ON_USE (gets, "gets is a security hole - use fgets instead");
#endif  

error: Autoconf version 2.60 or higher is required

解:

查看当前的autoconf版本:
	/usr/bin/autoconf -V

安装1:
	wget ftp://ftp.gnu.org/gnu/autoconf/autoconf-2.64.tar.gz
	tar -xf autoconf-2.64.tar.gz
	./configure
	make
	make install

安装2:
	sudo apt-get install autoconf2.64

conftest.c:14625: must be after `@defmac' to use `@defmacx'

error log:

autoconf.texi:9: warning: @setcontentsaftertitlepage is obsolete; move your @contents command if you want the contents after the title page
conftest.c:14625: must be after @defmac' to use@defmacx’
Makefile:241: recipe for target ‘autoconf.info’ failed

解: (修改autoconf.texi文件即可, 去掉两处地方的@c)

--- autoconf-2.65/doc/autoconf.texi	2009-11-05 10:42:15.000000000 +0800
+++ autoconf-2.65/doc/autoconf.texi.new	2013-05-28 05:41:09.243770263 +0800
@@ -15,7 +15,7 @@
 @c The ARG is an optional argument.  To be used for macro arguments in
 @c their documentation (@defmac).
 @macro ovar{varname}
-@r{[}@var{\varname\}@r{]}@c
+@r{[}@var{\varname\}@r{]}
 @end macro
 
 @c @dvar(ARG, DEFAULT)
@@ -23,7 +23,7 @@
 @c The ARG is an optional argument, defaulting to DEFAULT.  To be used
 @c for macro arguments in their documentation (@defmac).
 @macro dvar{varname, default}
-@r{[}@var{\varname\} = @samp{\default\}@r{]}@c
+@r{[}@var{\varname\} = @samp{\default\}@r{]}
 @end macro

autoreconf: xxxxxx/usr/bin/automake failed with exit status: 255

error log:

Unescaped left brace in regex is illegal here in regex; marked by <-- HERE in m/${ <-- HERE ([^ \t=:+{}]+)}/ at xxxxx/usr/bin/automake line 4113.
autoreconf: xxxxx/usr/bin/automake failed with exit status: 255
package/Makefile.package.in:281: recipe for target ‘xxxxx/build/host-pkg-config-0.25/.stamp_configured’ failed

解: (新版的perl不在支持左大括号的使用,进入这个文件删掉大括号)

vi xxxx/usr/bin/automake
(选定到4113, 由上log可知)

从
$text =~ s/\${([^ \t=:+{}]+)}/&substitute_ac_subst_variables_worker ($1)/ge;
改为:(其实就是删了一对大括号)
$text =~ s/\$([^ \t=:+{}]+)/&substitute_ac_subst_variables_worker ($1)/ge;
发布了68 篇原创文章 · 获赞 22 · 访问量 7万+

猜你喜欢

转载自blog.csdn.net/MACMACip/article/details/105512052