linnx88 Posted May 19, 2014 Share Posted May 19, 2014 Greetings,I'm trying to compile the latest GemRB from source. I have all the dependencies, following the INSTALL instructions. Using g++ and cmake + make. Running Linux Mint 16 64x.Everything went fine until I issued the make command and got to 81% of compilation. I get the following error: [ 79%] Built target DirectoryImporter Linking CXX shared module ../EFFImporter.so /usr/lib/i386-linux-gnu/libc_nonshared.a(stack_chk_fail_local.oS): In function `__stack_chk_fail_local': (.text+0x10): undefined reference to `__stack_chk_fail' collect2: error: ld returned 1 exit status make[2]: *** [gemrb/plugins/EFFImporter.so] Error 1 make[1]: *** [gemrb/plugins/EFFImporter/CMakeFiles/EFFImporter.dir/all] Error 2 make: *** [all] Error 2 I found that this is a new feature built into the newer kernels to avoid stack collision. I also found directions to issue -CFLAGS="-fno-stack-protector -fno-stack-protector-all", but this is for C. How do I issue a similar command for the g++ compiler?! Thanks! Link to comment
linnx88 Posted May 20, 2014 Author Share Posted May 20, 2014 I added these flags to the configure.in file and I still get the same error. Please help. Link to comment
lynx Posted May 20, 2014 Share Posted May 20, 2014 you're using cmake, so changing configure.in or configure has no effect. Either change the generated makefile in the build dir of EFFImporter directly or run ccmake in it to change the vars (and rebuild). Link to comment
linnx88 Posted May 20, 2014 Author Share Posted May 20, 2014 you're using cmake, so changing configure.in or configure has no effect. Either change the generated makefile in the build dir of EFFImporter directly or run ccmake in it to change the vars (and rebuild). Thank you. Using ccmake helped, after I set those flags there! ccmake should be run from the build directory! I also had SDL1 & SDL2 installed, which is incorrect. So I uninstalled SDL1 and everything worked after that. Also the INSTALL directions might need to be updated to reflect this stack issue. Link to comment
lynx Posted May 20, 2014 Share Posted May 20, 2014 Having both sdls installed shouldn't be a problem, unless you provided incompatible options. This stack protector issue sounds like an upstream thing, but we'll mitigate if it stays a problem. Link to comment
Recommended Posts
Archived
This topic is now archived and is closed to further replies.