Added fixes to export library in CMakeLists