Modified CMakeLists.txt to support compilation with emscripten