Morn76 wrote:Excellent, thanks Amaz! I've added Belugion (=OmniStudent). If anyone else would like to get added, please come forward.
Thankyou, wrote a small wiki page to test my permissions.
Morn76 wrote:Excellent, thanks Amaz! I've added Belugion (=OmniStudent). If anyone else would like to get added, please come forward.
Morn76 wrote:So it looks like leveldb and freetype work without problems; gettext might work if include and library paths were changed because Homebrew does not install this in /usr/local, so as not to clash with OS X's built-in BSD gettext.
LuaJIT on the other hand is a complete disappointment on OS X and leads to an executable that immediately crashes.
P.S. I've uploaded a new Minetest git build with LevelDB and Freetype enabled. And I've added a script to mtmake-osx for massaging dynamic libraries with dylibbundler.
OmniStudent wrote:Thankyou, wrote a small wiki page to test my permissions.
OmniStudent wrote:Great work, I've tried the binary and everything seems fine. Pity about LuaJIT http://luajit.org/index.html, but from my first glance it looks like this hasn't been updated for osx in a while (only 10.3 and 10.4 are mentioned in the install instructions). On the other hand, I can install it through brew, so I guess its up to date.
Morn76 wrote:P.S. OmniStudent, please make sure your copy of mtname-osx is updated before you create a new ZIP for GitHub though, because builds are supposed to include freetype and leveldb now.
OmniStudent wrote:Thankyou, but it will probably be a while until I contribute a zip. Right now I'm just having too much fun trying to build a player "AI".
If you're building a 64 bit application on OSX which links directly or indirectly against LuaJIT, you need to link your main executable with these flags:
-pagezero_size 10000 -image_base 100000000
OmniStudent wrote:You're amazingly fast Morn76! How much coding experience do you have?
Process: minetest [41454]
Path: /Volumes/VOLUME//Users/*/Downloads/*/minetest.app/Contents/MacOS/../Resources/bin/minetest
Identifier: celeron55.minetest
Version: 20140425.3a6d6e4 (20140425.3a6d6e4)
Code Type: X86-64 (Native)
Parent Process: launchd [138]
Responsible: minetest [41454]
User ID: 501
Date/Time: 2014-04-26 22:35:40.437 +0200
OS Version: Mac OS X 10.9.2 (13C1021)
Report Version: 11
Crashed Thread: 0 Dispatch queue: com.apple.main-thread
Exception Type: EXC_BAD_ACCESS (SIGSEGV)
Exception Codes: EXC_I386_GPFLT
Thread 0 Crashed:: Dispatch queue: com.apple.main-thread
0 libunwind.dylib 0x00007fff854a4a81 libunwind::CompactUnwinder_x86_64<libunwind::LocalAddressSpace>::stepWithCompactEncodingFrameless(unsigned int, unsigned long long, libunwind::LocalAddressSpace&, libunwind::Registers_x86_64&, bool) + 565
1 libunwind.dylib 0x00007fff854a233b libunwind::CompactUnwinder_x86_64<libunwind::LocalAddressSpace>::stepWithCompactEncoding(unsigned int, unsigned long long, libunwind::LocalAddressSpace&, libunwind::Registers_x86_64&) + 41
2 libunwind.dylib 0x00007fff854a22e1 libunwind::UnwindCursor<libunwind::LocalAddressSpace, libunwind::Registers_x86_64>::step() + 113
3 libunwind.dylib 0x00007fff854a19f2 _Unwind_RaiseException + 166
4 libc++abi.dylib 0x00007fff8eaacc4a __cxa_throw + 107
5 minetest 0x00000001052edea1 con::Connection::Receive(unsigned short&, SharedBuffer<unsigned char>&) + 1745Process: minetest [45565]
Path: /Volumes/VOLUME//Users/*/Downloads/*/minetest.app/Contents/MacOS/../Resources/bin/minetest
Identifier: celeron55.minetest
Version: 20140425.3a6d6e4 (20140425.3a6d6e4)
Code Type: X86-64 (Native)
Parent Process: launchd [138]
Responsible: minetest [45565]
User ID: 501
Date/Time: 2014-04-26 23:56:11.174 +0200
OS Version: Mac OS X 10.9.2 (13C1021)
Report Version: 11
Crashed Thread: 0 Dispatch queue: com.apple.main-thread
Exception Type: EXC_BAD_ACCESS (SIGSEGV)
Exception Codes: EXC_I386_GPFLT
Thread 0 Crashed:: Dispatch queue: com.apple.main-thread
0 libunwind.dylib 0x00007fff854a4a81 libunwind::CompactUnwinder_x86_64<libunwind::LocalAddressSpace>::stepWithCompactEncodingFrameless(unsigned int, unsigned long long, libunwind::LocalAddressSpace&, libunwind::Registers_x86_64&, bool) + 565
1 libunwind.dylib 0x00007fff854a233b libunwind::CompactUnwinder_x86_64<libunwind::LocalAddressSpace>::stepWithCompactEncoding(unsigned int, unsigned long long, libunwind::LocalAddressSpace&, libunwind::Registers_x86_64&) + 41
2 libunwind.dylib 0x00007fff854a22e1 libunwind::UnwindCursor<libunwind::LocalAddressSpace, libunwind::Registers_x86_64>::step() + 113
3 libunwind.dylib 0x00007fff854a19f2 _Unwind_RaiseException + 166
4 libc++abi.dylib 0x00007fff8eaacc4a __cxa_throw + 107
5 minetest 0x000000010c2374f7 ServerMap::ServerMap(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, IGameDef*, EmergeManager*) + 2343Morn76 wrote:OmniStudent wrote:You're amazingly fast Morn76! How much coding experience do you have?
I think this is more about Googling skills than amazing coding ability. :-) The fixes are all out there somewhere. That said, I've not really had significant prior experience with cmake or Xcode and I've never really used C++ for anything in practice, so I'm a bit proud of myself here that it all works so far.
But perhaps the most important new development for the Minetest Mac port is actually Homebrew. Unlike Fink and Macports, Homebrew does not seem to suck as much and all our dependencies are supported and up to date. That makes everything so much easier.
I suppose now I could best the other builds by including hiredis too? Does anyone actually use redis or is this another of those contests to see who has the biggest, largest, mightiest... ah, umm, database backend? :-)
Morn76 wrote: Maybe you should clone mtmake-osx instead of downloading the ZIP, so you can simply do "git pull" before you build. Nested git repositories seem to work, you just have to be more mindful of which directory you are in before you 'git pull'.
OmniStudent wrote:I switched to homebrew recently on a whim, nice to hear it works better.
OmniStudent wrote:Think I read somewhere about a significant performance improvement with redis.
OmniStudent wrote:I'm starting to suspect that you are, well,... smarter than I am. Don't deny it :-)
xcodebuild ARCHS="x86_64" GCC_OPTIMIZATION_LEVEL="0" -configuration ReleaseMorn76 wrote:
Well, getting ancient, uncommented, hard-to-understand source code to run is certainly something I have experience with. Although in science it's usually Fortran-77 or worse, Fortran-iV. :-)
Morn76 wrote:Strangely enough however, this unoptimized Release build is quite a bit larger than a Debug build (also unoptimized): 14.8 MB vs 10.3 MB! So now I'm trying to figure out if there is a noticeable performance benefit at least.
Morn76 wrote:P.P.S. When I stand in the same place in Stampyworld, I easily get 50 to 60 fps with Debug, while Release seems to stay between 40 and 50 fps and struggles to go above 50. So it really looks like Debug is a bit faster.
OmniStudent wrote:What science? I'm guessing physics or chemistry based on those languages. I'm doing bioinformatic stuff where I seldom have to do more than write python scripts.
OmniStudent wrote:Strange, but I guess that ties in with the optimization problems you mentioned.
raffahacks wrote:The easiest way is to install wine (=a windows software interpreter for mac) and run the windiws version. Everything works (including online features) and the framerate is very good.
Hope to be useful, if you want i can publsh a standalone mac binary built with wine and windows binaries.
Bye
OmniStudent wrote:Would be nice, even if for no other reason than performance comparison. Morn76's version will probably be both faster and less troublesome, it can be downloaded as a regular app. But the more the merrier! And you still need wine if you want to write "merde" on a french keyboard :-)
if(APPLE)
set(CMAKE_OSX_ARCHITECTURES i386 CACHE STRING "do not build for 64-bit" FORCE)
set(ARCH i386)
endif()Morn76 wrote:I've made some progress: Now I can build a 64 bit binary with make instead of xcodebuild. It turns out the crashiness of optimized Release builds was due to these compiler flags: "-ffast-math -Wall -fomit-frame-pointer -pipe -funroll-loops". Remove them and the problems are gone. I just have to test them individually to figure out which flag is the problematic one.
CMakeLists also had this previously overlooked gem: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
if(APPLE)
set(CMAKE_OSX_ARCHITECTURES i386 CACHE STRING "do not build for 64-bit" FORCE)
set(ARCH i386)
endif()
No wonder the static libraries were always stubbornly built for i386! Obviously someone once considered 64 bit builds for OS X a bad idea and put this here. I have no idea why.
OmniStudent wrote:raffahacks wrote:The easiest way is to install wine (=a windows software interpreter for mac) and run the windiws version. Everything works (including online features) and the framerate is very good.
Hope to be useful, if you want i can publsh a standalone mac binary built with wine and windows binaries.
Bye
Would be nice, even if for no other reason than performance comparison. Morn76's version will probably be both faster and less troublesome, it can be downloaded as a regular app. But the more the merrier! And you still need wine if you want to write "merde" on a french keyboard :-)
raffahacks wrote: On my mac Morn76 version doesn't work, will try to recompile his.
hoodedice wrote:AFAIK, the devs here hate 64 bit Minetest, saying that it does not have enough performance benefits to be viable
Morn76 wrote:
I'm working on a make-based "make_mac.sh" that I will push to mdoege/mtmake-osx soon I hope. Without interference from xcodebuild, it should be easier to stick e.g. "-march=core2" in the CMakeLists somewhere and get a build that works on your machine. (Because with Xcode I could not figure out how to do this.)
raffahacks wrote:Thank you Morn76, hope to see your binary soon!
Morn76 wrote:@OmniStudent: Like I said earlier, I think you should use LevelDB for your maps. Slowdowns due to database loading will still happen but not be as bad as with SQLite. I do my Stampy map in LevelDB and only migrate a copy to SQLite for distribution. I hope with the release 0.4.10, all binaries will have LevelDB support on all platform so I can upload the LevelDB version directly.
Users browsing this forum: No registered users and 22 guests