Can't use 'defined(@array)' (Maybe you should just omit the defined()?)(编译内核时候的错误)
2017-04-13 15:41
537 查看
http://blog.csdn.net/q1302182594/article/details/52579187
0 开发环境
Ubuntu16.04.1(64bit)
Linux-2.6.39.4
1 错误描述
使用ubuntu14.04(64bit)编译linux2.6.39.4并没有出现什么错误,但是使用ubuntu16.04.1(64bit)编译linux-2.6.39.4时,却提示如题错误。
2 解决方法
见参考资料[1]。
参考资料
[1]编译kernel perl版本bug
其实,提示的错误信息已经明确告诉你了,你应该省略
这里,我们打开 kernel/timeconst.pl
将
查了一下更新,发现其中有一项是perl版本升级到了
0 开发环境
Ubuntu16.04.1(64bit)
Linux-2.6.39.4
1 错误描述
使用ubuntu14.04(64bit)编译linux2.6.39.4并没有出现什么错误,但是使用ubuntu16.04.1(64bit)编译linux-2.6.39.4时,却提示如题错误。
2 解决方法
见参考资料[1]。
参考资料
[1]编译kernel perl版本bug
Can't use 'defined(@array)' (Maybe you should just omit the defined()?) at kernel/timeconst.pl line 373.
其实,提示的错误信息已经明确告诉你了,你应该省略
defined().
这里,我们打开 kernel/timeconst.pl
@val = @{$canned_values{$hz}}; if (defined(@val)) { @val = compute_values($hz); } output($hz, @val);
将
if (defined(@val))改为
if (@val),再次编译就可以通过了。
查了一下更新,发现其中有一项是perl版本升级到了
v5.22.1,然后查了perl官方文档,发现官网因为一个bug,该版本将
defined(@array)去掉了。可以直接使用数组判断非空。
相关文章推荐
- Can't use 'defined(@array)' (Maybe you should just omit the defined()?) at kernel/timeconst.pl line
- Can't use 'defined(@array)' (Maybe you should just omit the defined()?)
- Can't use 'defined(@array)' (Maybe you should just omit the defined()?) at kernel/timeconst.pl
- 再ubuntu64位机下编译linux-2.32.2,出现Can't use 'defined(@array)' (Maybe you should just omit the defined()?)
- (Maybe you should just omit the defined()?) at kernel/timeconst.pl line
- 在Ubuntu 64位环境下编译Liunx内核出现 Can't use 'defined(@array)' 错误的解决办法
- 在Ubuntu 下编译Liunx内核出现 Can't use 'defined(@array)' 错误的解决办法
- 在Ubuntu 64位环境下编译Liunx内核出现 Can't use 'defined(@array)' 错误的解决办法
- 在Ubuntu 64位环境下编译Liunx内核出现 Can't use 'defined(@array)' 错误的解决办法
- 在Ubuntu 64位环境下编译Liunx内核出现 Can't use 'defined(@array)' 错误的解决办法
- 在Ubuntu 64位环境下编译Liunx内核出现 Can't use 'defined(@array)' 错误的解决办法
- Ubuntu16.04编译make内核出错Can't use 'defined(@array)'
- The one who can give anything you want is only yourself. The rating is the only you should pursue.
- c# dynamic,maybe I should say it is just some shortcut for "Object", box and unbox, without the cast
- 60款开源云应用【Part 2】(60 Open Source Apps You Can Use in the Cloud)
- CodeIgniter 错误: In order to use the Session class you are required to set an encryption key
- *Delphi编译dll时出错"Cannot debug project unless a host application is defined.use the run|parameters...dialog box."
- mysql5中大数据错误:Packet for query is too large (1117260 > 1048576). You can change this value on the ser
- Android错误之:You need to use a Theme.AppCompat theme (or descendant) with this activity.
- vs2010编译错误:#error 指令: Please use the /MD switch for _AFXDLL