Mineserver Community

Mineserver => Support => Topic started by: thegk01 on June 28, 2011, 02:17:46 pm



Title: Error building actual release :(
Post by: thegk01 on June 28, 2011, 02:17:46 pm
Hey,
I got an error in the mcregion file while compiling on my MacBook (Intel Core 2 Duo).
The compiler said this:
Code:
[ 32%] Building CXX object CMakeFiles/mineserver.dir/src/mcregion.cpp.o
/Users/myname/Downloads/fador-mineserver-c643202-1/src/mcregion.cpp: In function ‘int getdir(std::string, std::vector<std::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::allocator<std::basic_string<char, std::char_traits<char>, std::allocator<char> > > >&)’:
/Users/myname/Downloads/fador-mineserver-c643202-1/src/mcregion.cpp:443: error: ‘DIR’ was not declared in this scope
/Users/myname/Downloads/fador-mineserver-c643202-1/src/mcregion.cpp:443: error: ‘dp’ was not declared in this scope
/Users/myname/Downloads/fador-mineserver-c643202-1/src/mcregion.cpp:445: error: ‘opendir’ was not declared in this scope
/Users/myname/Downloads/fador-mineserver-c643202-1/src/mcregion.cpp:451: error: ‘readdir’ was not declared in this scope
/Users/myname/Downloads/fador-mineserver-c643202-1/src/mcregion.cpp:453: error: invalid use of incomplete type ‘struct dirent’
/Users/myname/Downloads/fador-mineserver-c643202-1/src/mcregion.cpp:444: error: forward declaration of ‘struct dirent’
/Users/myname/Downloads/fador-mineserver-c643202-1/src/mcregion.cpp:453: error: invalid use of incomplete type ‘struct dirent’
/Users/myname/Downloads/fador-mineserver-c643202-1/src/mcregion.cpp:444: error: forward declaration of ‘struct dirent’
/Users/myname/Downloads/fador-mineserver-c643202-1/src/mcregion.cpp:455: error: invalid use of incomplete type ‘struct dirent’
/Users/myname/Downloads/fador-mineserver-c643202-1/src/mcregion.cpp:444: error: forward declaration of ‘struct dirent’
/Users/myname/Downloads/fador-mineserver-c643202-1/src/mcregion.cpp:458: error: ‘closedir’ was not declared in this scope
make[2]: *** [CMakeFiles/mineserver.dir/src/mcregion.cpp.o] Error 1
make[1]: *** [CMakeFiles/mineserver.dir/all] Error 2
make: *** [all] Error 2

Yep. This is bad.
Additionally, I want to ask how I compile for archv6? This would be the final step to let Mineserver run on my iPod touch.

Thanks for any help :)
thegk01


Title: Re: Error building June 12 release :(
Post by: borisko on June 28, 2011, 07:43:29 pm
Try adding the following lines to the beginning of mcregion.cpp:
Code:
#include <sys/types.h>
#include <dirent.h>


Title: Re: Error building June 12 release :(
Post by: thegk01 on July 06, 2011, 10:31:46 pm
Okay, after I tried very much, added the headers borisko said ( :) ), changed some functions (because as a Mac user, there is nothing implemented :( ), I am now at a point where Mineserver launches and loads the config files etc.
But, after "world" is created, the program crashes with this error:
Code:
[22:24:41] map.cpp:228::init(): World world
[22:24:41] mineserver.cpp:535::run(): Generating spawn area...
Floating point exception

Any suggestions? :(


Title: Re: Error building June 12 release :(
Post by: thegk01 on July 11, 2011, 02:37:34 pm
Okay,
If I use a prebuilt map, then it works.
But if I start to chat, the mineserver executable stops with a "Floating Point Exception".

:(