bug in devil lib, /usr/include/IL/il.h

博客详细介绍了在使用devil库时遇到的一个关键问题,该问题与文件/usr/include/IL/il.h有关。内容可能涉及编译错误、Spring框架的整合以及如何应用补丁来解决这个问题。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

Details

Description:

When trying to compile spring (in AUR), the compilation procedure quits with the following error:

In file included from rts/Map/SM3/terrain/TerrainBase.h:41,
from rts/Map/SM3/Sm3Map.h:6,
from rts/Map/ReadMap.cpp:19:
/usr/include/IL/il.h:497: error: '<anonymous>' has incomplete type
/usr/include/IL/il.h:497: error: invalid use of 'ILvoid'
/usr/include/IL/il.h:498: error: '<anonymous>' has incomplete type
/usr/include/IL/il.h:498: error: invalid use of 'ILvoid'
/usr/include/IL/il.h:505: error: '<anonymous>' has incomplete type
/usr/include/IL/il.h:505: error: invalid use of 'ILvoid'
/usr/include/IL/il.h:516: error: '<anonymous>' has incomplete type
/usr/include/IL/il.h:516: error: invalid use of 'ILvoid'
/usr/include/IL/il.h:518: error: '<anonymous>' has incomplete type
/usr/include/IL/il.h:518: error: invalid use of 'ILvoid'
/usr/include/IL/il.h:521: error: '<anonymous>' has incomplete type
/usr/include/IL/il.h:521: error: invalid use of 'ILvoid'
/usr/include/IL/il.h:522: error: '<anonymous>' has incomplete type
/usr/include/IL/il.h:522: error: invalid use of 'ILvoid'
/usr/include/IL/il.h:525: error: '<anonymous>' has incomplete type
/usr/include/IL/il.h:525: error: invalid use of 'ILvoid'
/usr/include/IL/il.h:540: error: '<anonymous>' has incomplete type
/usr/include/IL/il.h:540: error: invalid use of 'ILvoid'
/usr/include/IL/il.h:552: error: '<anonymous>' has incomplete type
/usr/include/IL/il.h:552: error: invalid use of 'ILvoid'
/usr/include/IL/il.h:553: error: '<anonymous>' has incomplete type
/usr/include/IL/il.h:553: error: invalid use of 'ILvoid'
/usr/include/IL/il.h:554: error: '<anonymous>' has incomplete type
/usr/include/IL/il.h:554: error: invalid use of 'ILvoid'
/usr/include/IL/il.h:568: error: '<anonymous>' has incomplete type
/usr/include/IL/il.h:568: error: invalid use of 'ILvoid'

Additional info:

This error is clearly related to a bug in /usr/include/IL/il.h, ownedby the devil package. All occurences of "int name(ILvoid);" in the fileneed to be replaced by "int name(void);".

It's already reported in DevIL's bugtracker: http://sourceforge.net/tracker/index.php?func=detail&aid=1651292&group_id=4470&atid=104470

Quick'n'dirty sed patch:
sed 's|(ILvoid)|(void)|g' -i /usr/include/IL/il.h

(For the spring package, you'll also need:
sed '101 a/>> end_p' -i $startdir/src/spring_0.74b3/rts/System/tdf_grammar.hpp)

Big thanks to Cirdan for the information :-)

Steps to reproduce:

Compile Spring.
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值