fix cmake bug, fix log bug, add log messages