mGGk-fr / ghostplusplus

GOOGLE CODE BACKUP : Bot for mananging W3 Matches
Other
0 stars 0 forks source link

Failed to compile ghost #118

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. download and unzip archive with ghost++
2. make and make install bnc utils, make and make install stormlib
3. trying to make ghost itself (path: ghost/ghost)

What is the expected output? What do you see instead?

g++ -o bncsutilinterface.o  -O3 -DGHOST_MYSQL -I. -I../bncsutil/src/ 
-I../StormLib/ -c bncsutilinterface.cpp
g++ -o bnet.o  -O3 -DGHOST_MYSQL -I. -I../bncsutil/src/ -I../StormLib/ -c 
bnet.cpp
bnet.cpp: In member function \u2018void 
CBNET::ProcessChatEvent(CIncomingChatEvent*)\u2019:
bnet.cpp:1666:31: error: \u2018class boost::filesystem3::directory_entry\u2019 
has no member named \u2018filename\u2019
bnet.cpp:1667:41: error: conversion from \u2018boost::filesystem3::path {aka 
boost::filesystem3::path}\u2019 to non-scalar type \u2018std::string {aka 
std::basic_string<char>}\u2019 requested
bnet.cpp:1677:33: error: \u2018class boost::filesystem3::directory_entry\u2019 
has no member named \u2018filename\u2019
bnet.cpp:1679:41: error: \u2018class boost::filesystem3::directory_entry\u2019 
has no member named \u2018filename\u2019
bnet.cpp:1695:44: error: conversion from \u2018boost::filesystem3::path {aka 
boost::filesystem3::path}\u2019 to non-scalar type \u2018std::string {aka 
std::basic_string<char>}\u2019 requested
bnet.cpp:1777:31: error: \u2018class boost::filesystem3::directory_entry\u2019 
has no member named \u2018filename\u2019
bnet.cpp:1778:41: error: conversion from \u2018boost::filesystem3::path {aka 
boost::filesystem3::path}\u2019 to non-scalar type \u2018std::string {aka 
std::basic_string<char>}\u2019 requested
bnet.cpp:1788:27: error: \u2018class boost::filesystem3::directory_entry\u2019 
has no member named \u2018filename\u2019
bnet.cpp:1790:35: error: \u2018class boost::filesystem3::directory_entry\u2019 
has no member named \u2018filename\u2019
bnet.cpp:1806:44: error: conversion from \u2018boost::filesystem3::path {aka 
boost::filesystem3::path}\u2019 to non-scalar type \u2018std::string {aka 
std::basic_string<char>}\u2019 requested
make: *** [bnet.o] Error 1

What version of the product are you using? On what operating system?
17.1, tried also 15.0

Please provide any additional information below.
Im using Arch linux with kernel 2.6.39

Original issue reported on code.google.com by porto...@gmail.com on 13 Jul 2011 at 11:46

GoogleCodeExporter commented 9 years ago
boost version is 1.46

Original comment by porto...@gmail.com on 13 Jul 2011 at 12:40

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
hi,

this problem is caused by the latest boost versions. Either use 1.39 as 
recommended in wiki or apply the following three lines while in ghost/ghost dir

find . -name "*.cpp" -print | xargs sed -i 's/i->filename( );/i->path( 
).filename( ).string( );/g'
find . -name "*.cpp" -print | xargs sed -i 's/LastMatch.filename( 
);/LastMatch.filename( ).string( );/g'
find . -name "*.cpp" -print | xargs sed -i 's/i->path( ).stem( );/i->path( 
).stem( ).string( );/g'

hf

Original comment by angelus...@gmail.com on 28 Jul 2011 at 10:52

GoogleCodeExporter commented 9 years ago
Comment #3 is a good working solution for people with libboost 1.46.

Original comment by ayo...@gmail.com on 4 Feb 2012 at 8:01

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
With boost 1.39 I have this: 
bnet.cpp: In member function ‘void 
CBNET::ProcessChatEvent(CIncomingChatEvent*)’:
bnet.cpp:1666: error: ‘struct std::basic_string<char, std::char_traits<char>, 
std::allocator<char> >’ has no member named ‘string’
bnet.cpp:1667: error: ‘struct std::basic_string<char, std::char_traits<char>, 
std::allocator<char> >’ has no member named ‘string’
bnet.cpp:1677: error: ‘struct std::basic_string<char, std::char_traits<char>, 
std::allocator<char> >’ has no member named ‘string’
bnet.cpp:1679: error: ‘struct std::basic_string<char, std::char_traits<char>, 
std::allocator<char> >’ has no member named ‘string’
bnet.cpp:1695: error: ‘struct std::basic_string<char, std::char_traits<char>, 
std::allocator<char> >’ has no member named ‘string’
bnet.cpp:1777: error: ‘struct std::basic_string<char, std::char_traits<char>, 
std::allocator<char> >’ has no member named ‘string’
bnet.cpp:1778: error: ‘struct std::basic_string<char, std::char_traits<char>, 
std::allocator<char> >’ has no member named ‘string’
bnet.cpp:1788: error: ‘struct std::basic_string<char, std::char_traits<char>, 
std::allocator<char> >’ has no member named ‘string’
bnet.cpp:1790: error: ‘struct std::basic_string<char, std::char_traits<char>, 
std::allocator<char> >’ has no member named ‘string’
bnet.cpp:1806: error: ‘struct std::basic_string<char, std::char_traits<char>, 
std::allocator<char> >’ has no member named ‘string’
make: *** [bnet.o] Error 1

Original comment by neolo...@gmail.com on 14 Feb 2012 at 11:34

GoogleCodeExporter commented 9 years ago
i guess you already applied the linies from comment #3 and then used 1.39 libs.

you either have to apply those changes and use latest boost libs (1.47 or so), 
or use boost 1.39 and leave the files untouched. you might just replace all the 
changed .cpp-files with the original from zip-package/svn or just revert 
changes by inverting the statements (as followed):

find . -name "*.cpp" -print | xargs sed -i 's/i->path( ).filename( ).string( 
);/i->filename( );/g'
find . -name "*.cpp" -print | xargs sed -i 's/LastMatch.filename( ).string( 
);/LastMatch.filename( );/g'
find . -name "*.cpp" -print | xargs sed -i 's/i->path( ).stem( ).string( 
);/i->path( ).stem( );/g'

hf

Original comment by angelus...@gmail.com on 17 Feb 2012 at 12:15