Linking errors when I compiling minetest on Mac OSX

glut32
New member
 
Posts: 5
Joined: Wed Feb 01, 2017 09:46
IRC: glut32

Linking errors when I compiling minetest on Mac OSX

by glut32 » Wed Mar 29, 2017 08:53

Hi all,

I compile Irrlicht 1.9 this morning and I have 3 linking errors when I want to generate the minetest's executable. CIrrDeviceOSX.mm file is an objective-c code. I think that the errors are inside inside "std::map<int,int> KeyCodes;" inside https://github.com/zaki/irrlicht/blob/master/source/Irrlicht/CIrrDeviceOSX.h and used by https://github.com/zaki/irrlicht/blob/master/source/Irrlicht/CIrrDeviceOSX.mm

There are a strange thing is that there are no problem for other code inside irrlicht 1.9. Maybe it's that the file is Objective-C the problem and the signature of methods are different??? or it's a different version of c++ (c++11 or more)

Thanks in advance for your help

This the linking error message
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
Ld bin/Debug/minetest normal x86_64
    cd /Users/bluholm/Desktop/minetest-release/minetest
    export MACOSX_DEPLOYMENT_TARGET=10.12
    /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++ -arch x86_64 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.12.sdk -L/Users/bluholm/Desktop/minetest-release/minetest/bin/Debug -F/Users/bluholm/Desktop/minetest-release/minetest/bin/Debug -filelist /Users/bluholm/Desktop/minetest-release/minetest-osx/src/minetest.build/Debug/minetest.build/Objects-normal/x86_64/minetest.LinkFileList -mmacosx-version-min=10.12 -Xlinker -object_path_lto -Xlinker /Users/bluholm/Desktop/minetest-release/minetest-osx/src/minetest.build/Debug/minetest.build/Objects-normal/x86_64/minetest_lto.o -Xlinker -no_deduplicate -lc++ -pagezero_size 10000 -image_base 100000000 -Wl,-search_paths_first -Wl,-headerpad_max_install_names /usr/lib/libz.dylib /usr/local/Cellar/irrlicht/1.9/lib/libIrrlicht.a -framework OpenGL -framework OpenAL /usr/local/lib/libvorbisfile.dylib /usr/local/lib/libvorbis.dylib /usr/local/lib/libogg.dylib /usr/lib/libsqlite3.dylib /usr/local/lib/libluajit-5.1.dylib /Users/bluholm/Desktop/minetest-release/minetest-osx/src/gmp/Debug/libgmp.a /Users/bluholm/Desktop/minetest-release/minetest-osx/src/jsoncpp/json/Debug/libjsoncpp.a -framework CoreFoundation -lpthread /usr/lib/libiconv.dylib -framework Carbon -framework Cocoa -framework IOKit /usr/lib/libiconv.dylib /usr/lib/libcurl.dylib /usr/local/lib/libfreetype.dylib /Users/bluholm/Desktop/minetest-release/minetest-osx/src/cguittfont/Debug/libcguittfont.a /usr/lib/libcurses.dylib /usr/lib/libform.dylib /usr/local/lib/libhiredis.dylib -framework Carbon -framework Cocoa -framework IOKit /usr/lib/libcurl.dylib /usr/lib/libcurses.dylib /usr/lib/libform.dylib /usr/local/lib/libhiredis.dylib /usr/lib/libz.dylib /usr/local/Cellar/irrlicht/1.9/lib/libIrrlicht.a /usr/local/lib/libfreetype.dylib -Xlinker -dependency_info -Xlinker /Users/bluholm/Desktop/minetest-release/minetest-osx/src/minetest.build/Debug/minetest.build/Objects-normal/x86_64/minetest_dependency_info.dat -o /Users/bluholm/Desktop/minetest-release/minetest/bin/Debug/minetest

Undefined symbols for architecture x86_64:
  "std::_Rb_tree_decrement(std::_Rb_tree_node_base*)", referenced from:
      std::_Rb_tree_iterator<std::pair<int const, int> >::operator--() in libIrrlicht.a(CIrrDeviceOSX.o)
  "std::_Rb_tree_increment(std::_Rb_tree_node_base*)", referenced from:
      std::_Rb_tree_iterator<std::pair<int const, int> >::operator++() in libIrrlicht.a(CIrrDeviceOSX.o)
  "std::_Rb_tree_insert_and_rebalance(bool, std::_Rb_tree_node_base*, std::_Rb_tree_node_base*, std::_Rb_tree_node_base&)", referenced from:
      std::_Rb_tree<int, std::pair<int const, int>, std::_Select1st<std::pair<int const, int> >, std::less<int>, std::allocator<std::pair<int const, int> > >::_M_insert(std::_Rb_tree_node_base*, std::_Rb_tree_node_base*, std::pair<int const, int> const&) in libIrrlicht.a(CIrrDeviceOSX.o)
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
 

Return to Minetest Engine

Who is online

Users browsing this forum: No registered users and 5 guests

cron