建立一个新工程文件,更换其文件夹位置后,导致无法编译的问题,问题窗口显示如下:
CMake Error: The current CMakeCache.txt directory /home/hy/桌面/car/build/CMakeCache.txt is different than the directory /root/car/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
错误问题原因:build文件编译后的是根据原有的文件位置进行编译,更换位置后不再适用。
解决方法:先删除build文件,再次编译。问题解决.