IMPORTED_LOCATION not set for imported target "opencv_core".

I’m cross-compiling a Linux library for ARM using dockcross and linking to OpenCV. OpenCV builds and installs successfully, but configuring my library gives me errors like this:

CMake Error in build/_deps/mylib-src/CMakeLists.txt:
      IMPORTED_LOCATION not set for imported target "opencv_core"

I’m finding the OpenCV package like this:

find_package( OpenCV REQUIRED )

And linking like this:

target_link_libraries( ${PROJECT_NAME} ${OpenCV_LIBS})

I didn’t find the documentation for IMPORTED_LOCATION very helpful. What does this error mean, and how do I fix it?

This worked:

set_target_properties(opencv_core PROPERTIES IMPORTED_LOCATION ${CMAKE_SYSROOT}/usr/local/lib/

But I still don’t know why I needed it…

It seems like a botched install. Is there anything under the OpenCV install prefix that sets IMPORTED_LOCATION?