MantisBT

View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0000919VCMIOtherpublic2012-04-08 02:392012-05-15 17:06
Reporterdarkbill 
Assigned ToIvan 
PriorityimmediateSeveritymajorReproducibilityalways
StatusclosedResolutionfixed 
PlatformLinux 64bitOSOS Version
Product Version0.88 
Target VersionFixed in Version 
Summary0000919: make error with gcc 4.7.0
DescriptionThe making error were shown as below:

make[2]: Entering directory `/tmp/packerbuild-1000/vcmi-svn/vcmi-svn/src/vcmi/lib'
  CXX libvcmi_la-BattleAction.lo
  CXX libvcmi_la-BattleState.lo
  CXX libvcmi_la-CArtHandler.lo
In file included from StdInc.h:3:0:
../Global.h: In instantiation of 'const ValT& bmap<KeyT, ValT>::operator[](KeyT) const [with KeyT = short unsigned int; ValT = ArtSlotInfo]':
CArtHandler.cpp:1390:28: required from here
../Global.h:144:21: error: 'find' was not declared in this scope, and no declarations were found by argument-dependent lookup at the point of instantiation [-fpermissive]
../Global.h:144:21: note: declarations in dependent base 'std::map<short unsigned int, ArtSlotInfo, std::less<short unsigned int>, std::allocator<std::pair<const short unsigned int, ArtSlotInfo> > >' are not found by unqualified lookup
../Global.h:144:21: note: use 'this->find' instead
make[2]: *** [libvcmi_la-CArtHandler.lo] Error 1

=================================
Then I tried to google this problem, and got an answer said "add the -fpermissive flag to cxx flag". I tried, but not work well for me.
TagsNo tags attached.
Attached Files

- Relationships

-  Notes
(0002340)
Tow (developer)
2012-04-08 02:48

Does the compiler suggestion to use this->find (at Global.h l. 144) solve the problem?
(0002342)
Ivan (developer)
2012-04-08 08:14

@Tow in this case - yes. But there are several other places where gcc-4.7 complains. Will fix it.
(0002343)
Ivan (developer)
2012-04-08 10:37

fixed in rev 2619 - VCMI should work with gcc-4.7

darkbill, you may need to delete file vcmi/lib/StdInc.h.gch manually
(0002344)
darkbill (reporter)
2012-04-08 12:00

Ivan, Thanks very much.
It can be compiled well now.
(0002438)
Ivan (developer)
2012-05-15 17:06

Closing old compile issues

- Issue History
Date Modified Username Field Change
2012-04-08 02:39 darkbill New Issue
2012-04-08 02:48 Tow Note Added: 0002340
2012-04-08 02:48 Tow Assigned To => Tow
2012-04-08 02:48 Tow Status new => feedback
2012-04-08 08:14 Ivan Note Added: 0002342
2012-04-08 08:14 Ivan Assigned To Tow => Ivan
2012-04-08 08:14 Ivan Status feedback => assigned
2012-04-08 10:37 Ivan Note Added: 0002343
2012-04-08 10:37 Ivan Status assigned => resolved
2012-04-08 10:37 Ivan Resolution open => fixed
2012-04-08 12:00 darkbill Note Added: 0002344
2012-05-15 17:06 Ivan Note Added: 0002438
2012-05-15 17:06 Ivan Status resolved => closed

Site | Forums | Wiki | Slack | GitHub


Copyright © 2000 - 2024 MantisBT Team
Hosting provided by DigitalOcean