fix mutex issue and c++11 support on Ubuntu — remove stray EOL marker