Modified CmakeLists.txt to be compatible with old CMake.