用CMake执行make命令时报错
make: *** No targets specified and no makefile found. Stop.
解决方案:
删掉原有的CMakeCache.txt文件,再重新在build目录下执行
cmake ..
和
make
即可。
报错:
CMake Error: The current CMakeCache.txt directory /home/ys/Desktop/Restart_DC/ZeroOne/build/CMakeCache.txt is different than the directory /home/ys/Desktop/ZeroOne-master/ZeroOne/build where CMakeCache.txt was created. This may result in binaries being created in the wrong place. If you are not sure, reedit the CMakeCache.txt
CMake Error: The source “/home/ys/Desktop/Restart_DC/ZeroOne/CMakeLists.txt” does not match the source “/home/ys/Desktop/ZeroOne-master/ZeroOne/CMakeLists.txt” used to generate cache. Re-run cmake with a different source directory.
解决方案同上。