cmake_minimum_required(VERSION 2.8)
PROJECT(hellomain)
INCLUDE_DIRECTORIES(/usr/local/include/hello)
TARGET_LINK_LIBRARIES(hellomain hello)
ADD_EXECUTABLE(hellomain main.cpp)
其中
TARGET_LINK_LIBRARIES(hellomain hello)
这句话的意思不就是为hellomain这个工程添加libhello.so的动态链接库吗?
为什么会出现
Cannot specify link libraries for target "hellomain" which is not built by
this project.
这样的错误?