Aislinn Report post Posted May 13, 2018 I've been trying to compile for about a week now and just can't get past the cal3d errors. I don't know if it's an easy fix for an include that wasn't included, or if my cal3d is malfunctioning. Any input appreciated. https://pastebin.com/vDebsvNc Hmm, I guess we can't use code option anymore. At least I can't find it. Share this post Link to post Share on other sites
Ben Report post Posted May 13, 2018 I'm seeing identical errors while trying to compile for macOS: Undefined symbols for architecture i386: "CalCoreMesh::setFilename(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&)", referenced from: _CalLoader_ELLoadCoreMesh in cal3d_io_wrapper.o _CalCoreModel_ELLoadCoreMesh in cal3d_io_wrapper.o "CalCoreMaterial::setFilename(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&)", referenced from: _CalLoader_ELLoadCoreMaterial in cal3d_io_wrapper.o _CalCoreModel_ELLoadCoreMaterial in cal3d_io_wrapper.o "CalCoreAnimation::setFilename(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&)", referenced from: _CalLoader_ELLoadCoreAnimation in cal3d_io_wrapper.o CalAnimationCache::loadAnimation(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, float) in cal3d_io_wrapper.o ld: symbol(s) not found for architecture i386 clang: error: linker command failed with exit code 1 (use -v to see invocation) Share this post Link to post Share on other sites
bluap Report post Posted May 13, 2018 Is this on Arch Aislinn? What version of cal3d library are you using? Ben, your errors look different how are you compiling? Share this post Link to post Share on other sites
Ben Report post Posted May 13, 2018 (edited) I'm using Xcode, the usual method for the macOS client. Edited May 13, 2018 by Ben Share this post Link to post Share on other sites
Aislinn Report post Posted May 13, 2018 3 minutes ago, bluap said: Is this on Arch Aislinn? What version of cal3d library are you using? Ben, your errors look different how are you compiling? I'm so sorry, I thought my specs were in my signature and they're not. Yes, this is on Arch. My cal3d version is 0.11.0, release 6. Share this post Link to post Share on other sites
bluap Report post Posted May 13, 2018 I have an Arch install that I use now and again. That clean compiles and is using the same cal3d version. I'm in the process of updating the packages so I'll see what happens after that is done. Share this post Link to post Share on other sites
bluap Report post Posted May 13, 2018 Well after a full update and reboot, and rebuild. It all compiles fine on my Arch box with a minor warning in Achievements.cpp. What is your GCC version? (gcc -v) Just guessing here, but when did you last recompile the cal3d package. It could be the cxx abi changes are the problem. Assuming you are using AUR, can recompile and reinstall cal3d? Share this post Link to post Share on other sites
Aislinn Report post Posted May 13, 2018 gcc version 8.1.0 (GCC) Yes, I use AUR, I'll recompile and reinstall and will report what happens. Thank you for looking into this! Share this post Link to post Share on other sites
Aislinn Report post Posted May 13, 2018 Well, this is not going well. The package in AUR is empty. So trying to use an outside download here and will need to install with Makefile instead of makepkg and pacman. So first round of errors give me many that look like this: hardwaremodel.cpp:754:3: error: ‘memcpy’ was not declared in this scope memcpy(&m_pVertexBuffer[(hardwareMesh.baseVertexIndex+i)*m_vertexStride],&vectorVertex[indice].position,sizeof(CalVector)); ^~~~~~ hardwaremodel.cpp:754:3: note: ‘memcpy’ is defined in header ‘<cstring>’; did you forget to ‘#include <cstring>’? So I added #include <cstring> to hardwaremodel.cpp and ran make again. That seemed to fix that problem. I ran make again. That brought me to many errors like this: loader.cpp: In static member function ‘static CalCoreKeyframe* CalLoader::loadCoreKeyframe(CalDataSource&)’: loader.cpp:889:12: error: cannot convert ‘bool’ to ‘CalCoreKeyframe*’ in return return false; ^~~~~ loader.cpp: In static member function ‘static CalCoreSkeletonPtr CalLoader::loadXmlCoreSkeleton(const string&)’: loader.cpp:1341:11: error: could not convert ‘false’ from ‘bool’ to ‘CalCoreSkeletonPtr’ {aka ‘cal3d::RefPtr<CalCoreSkeleton>’} return false; loader.cpp:1347:11: error: could not convert ‘false’ from ‘bool’ to ‘CalCoreSkeletonPtr’ {aka ‘cal3d::RefPtr<CalCoreSkeleton>’} return false; ^~~~~ loader.cpp:1356:10: error: could not convert ‘false’ from ‘bool’ to ‘CalCoreSkeletonPtr’ {aka ‘cal3d::RefPtr<CalCoreSkeleton>’} return false; ^~~~~ And now I'm stuck. Share this post Link to post Share on other sites
bluap Report post Posted May 14, 2018 Hmm. I did a clean build of the AUR package I already had built and I get those same errors about false to bool (not the memcpy which is probably sorted by the AUR config script). I've not got time now but you could try replacing false with 0, as its actually a pointer value I think. Otherwise, I'll see if I can get it working when I get home tonight. Share this post Link to post Share on other sites
bluap Report post Posted May 14, 2018 I could not resist check, the false -> 0 works. Here's a very hacked AUR package tree that includes the missing download and patch file. I'll do a proper patch later. I built and installed this with "makepkg -sri -f" Share this post Link to post Share on other sites
revi Report post Posted May 14, 2018 (edited) You might have a problem with the C++ language version used: G++ 8.1 uses the 2014 standard of C++, and one of the things that changed there is pointer comparisons and conversions. In this case, the funtions return "0" on error, and should return "nullptr" (or throw an exception). Try using "-std=c++98", "-std=c++03", or "-std=c++11" when compiling the library (and possibly the client!) Edited May 14, 2018 by revi Share this post Link to post Share on other sites
Aislinn Report post Posted May 14, 2018 So far, cal3d compiled successfully with your fix, bluap. Will try the client again. Whoa, hallelujah, it works! Client compiled and I'm on it. Thank you SO much! Share this post Link to post Share on other sites
bluap Report post Posted May 14, 2018 Good news, I'm glad its working. I'll see if I can submit a patch to get the AUR updated. Share this post Link to post Share on other sites