Mac OS X supporter, may need help

Ender27182818
New member
 
Posts: 1
Joined: Mon Jul 30, 2012 16:14

Mac OS X supporter, may need help

by Ender27182818 » Mon Jul 30, 2012 16:20

I'm considering becoming the supporter for the Mac OS X build of minetest - I noticed it's been a long time since someone did it. To get things working I needed to build irrlicht on OS X, which is pretty easy, but only on the development branch of irrlicht (the latest stable, 1.7.3, has massive build problems).

Anyways, now I'm working on getting minetest to build linked against the develop (soon to be 1.8) branch of irrlicht. I'm hitting the following build output:

Your phone or window isn't wide enough to display the code box. If it's a phone, try rotating it to landscape mode.
Code: Select all
[ 40%] Building CXX object src/CMakeFiles/minetest.dir/main.cpp.o
Linking CXX executable ../bin/minetest
Undefined symbols for architecture i386:
  "irr::video::IdentityMaterial", referenced from:
      irr::scene::ISceneNode::getMaterial(unsigned int)in sky.cpp.o
      irr::scene::ISceneNode::getMaterial(unsigned int)in clientmap.cpp.o
      irr::scene::ISceneNode::getMaterial(unsigned int)in farmesh.cpp.o
      irr::scene::ISceneNode::getMaterial(unsigned int)in clouds.cpp.o
      irr::scene::ISceneNode::getMaterial(unsigned int)in sky.cpp.o
      irr::scene::ISceneNode::getMaterial(unsigned int)in clientmap.cpp.o
      irr::scene::ISceneNode::getMaterial(unsigned int)in farmesh.cpp.o
      irr::scene::ISceneNode::getMaterial(unsigned int)in clouds.cpp.o
      irr::scene::ISceneNode::getMaterial(unsigned int)in sky.cpp.o
      irr::scene::ISceneNode::getMaterial(unsigned int)in clientmap.cpp.o
      irr::scene::ISceneNode::getMaterial(unsigned int)in farmesh.cpp.o
      irr::scene::ISceneNode::getMaterial(unsigned int)in clouds.cpp.o
      irr::scene::ISceneNode::getMaterial(unsigned int)in sky.cpp.o
      irr::scene::ISceneNode::getMaterial(unsigned int)in clientmap.cpp.o
      irr::scene::ISceneNode::getMaterial(unsigned int)in farmesh.cpp.o
      irr::scene::ISceneNode::getMaterial(unsigned int)in clouds.cpp.o
  "irr::core::IdentityMatrix", referenced from:
      GenericCAO::addToScene(irr::scene::ISceneManager*, ITextureSource*, irr::IrrlichtDevice*)        in content_cao.cpp.o
      GenericCAO::updateTextures(std::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)in content_cao.cpp.o
      GenericCAO::updateTexturePos()       in content_cao.cpp.o
      the_game(bool&, bool, InputHandler*, irr::IrrlichtDevice*, irr::gui::IGUIFont*, std::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::basic_string<char, std::char_traits<char>, std::allocator<char> >, unsigned short, std::basic_string<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> >&, std::basic_string<char, std::char_traits<char>, std::allocator<char> >, ChatBackend&, SubgameSpec const&, bool)in game.cpp.o
      GenericCAO::addToScene(irr::scene::ISceneManager*, ITextureSource*, irr::IrrlichtDevice*)        in content_cao.cpp.o
      GenericCAO::updateTextures(std::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)in content_cao.cpp.o
      GenericCAO::updateTexturePos()       in content_cao.cpp.o
      the_game(bool&, bool, InputHandler*, irr::IrrlichtDevice*, irr::gui::IGUIFont*, std::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::basic_string<char, std::char_traits<char>, std::allocator<char> >, unsigned short, std::basic_string<wchar_t, std::char_traits<wchar_t>, std::allocator<wchar_t> >&, std::basic_string<char, std::char_traits<char>, std::allocator<char> >, ChatBackend&, SubgameSpec const&, bool)in game.cpp.o
  "_createDeviceEx", referenced from:
      _main in main.cpp.o
ld: symbol(s) not found for architecture i386
collect2: ld returned 1 exit status
make[2]: *** [bin/minetest] Error 1
make[1]: *** [src/CMakeFiles/minetest.dir/all] Error 2
make: *** [all] Error 2


This seems to imply to me that the API for irrlicht has changed between 1.7.3 and 1.8. Looking at the irrlicht API docs I'm not seeing much that has changed in something as basic as getMaterial. Maybe I'm reading the linker problem wrong since I've never worked with irrlicht or minetest (but I do have 3D engine experience).

Has anyone tried to build minetest against the latest develop branch of irrlicht? Do you know anything about getting it to work?

I'm thinking that unless people have some great insight I'll try building it on a Ubuntu VM, then try building the latest irrlicht and minetest on Ubuntu and see if I get similar problems. Mostly what I want to know is if it's a difficulty with cmake's config on Mac or a mismatch between irrlicht and minetest. I'm relatively new to C++ development on Mac, so...here's to learning new things.

Oh, and yes, I've had to make some slight modifications to the cmake config already to get this far. I'll eventually submit pull requests for this stuff when I get it working.
 

newbeb
New member
 
Posts: 1
Joined: Sun Aug 12, 2012 04:39

by newbeb » Sun Aug 12, 2012 04:49

I have gotten irrlicht compiled from the latest svn trunk on MacOS 10.7.2 with XCode 4.4.1. The examples run from within XCode, but I don't get them to run from the command line with the exception of the demo app, which renders a blank screen. I had to use the g++ llvm compiler to get things to work correctly, but it does build. I also forced it to target x86_64, but that might not have been strictly necessary.

I have fought with cmake to get it to generate a new xcode project for minetest, since things have changed in the file layouts with the mac project on github. I have tweaked the generated project to target the x86_64 platform and use the g++ llvm compiler as well as making a few tweaks to the minetest source to get things to compile cleanly. I got a clean compile and link tonight and got the app to launch from the shell prompt, but there is no GUI, probably because the full app package is not being built (not sure how to get cmake to do this...).

I am completely new to XCode, C++ on the mac, irrlicht and even minetest, but am willing to help you get things bootstrapped if I can. Probably don't want to be a maintainer, but I'll do what I can to help you out.

I'll fork the minetest repo and push my compilation tweaks up and try to merge the changes between the existing macos build project in github and what I have generated now as well.

From below it looks like you might be getting hit by the same issue I saw with the cmake generated code, which was that i386 was forced for minetest, but I had built libIrrlicht for x86_64. I got around it by generating the XCode project and then going in and tweaking all of the architectures and compiler settings to be the same (x86_64 and g++ llvm compiler).
 

User avatar
graywolf777
Member
 
Posts: 13
Joined: Fri Jul 27, 2012 13:06

by graywolf777 » Fri Aug 31, 2012 13:55

Hello To You Both!
As a Big MAC MAN myself, i have been praying that others (more versed in compiling/recompiling than myself) can get a stable updated version of .42 to work on the MAC OS. I have had luck with compiling it (stable) on my Ubuntu machine, and of course Windows build is ALWAYS favored first by many, but i would prefer to set up a stable MAC version for my children and I to build & play.
I applaud you both & send you both any encouragement & blessings I can give.

Thank You!

"A Proud MAC MAN"
-graywolf777
 


Return to Minetest Problems

Who is online

Users browsing this forum: No registered users and 16 guests