lebeg commented on a change in pull request #9799: Cleaned up image classification cpp example URL: https://github.com/apache/incubator-mxnet/pull/9799#discussion_r170885861
########## File path: example/image-classification/predict-cpp/CMakeLists.txt ########## @@ -1,34 +1,28 @@ -if(USE_OPENCV) - find_package(OpenCV QUIET COMPONENTS core highgui imgproc imgcodecs) - if(NOT OpenCV_FOUND) # if not OpenCV 3.x, then imgcodecs are not found - find_package(OpenCV REQUIRED COMPONENTS core highgui imgproc) - endif() - - if(NOT MSVC) - set(UNITTEST_STATIC_LINK ON) - endif() +# ---[ OpenCV +if(NOT USE_OPENCV OR NOT OpenCV_FOUND) + message(WARNING "\ +OpenCV should be enabled and found to build image classification example, skipping...") Review comment: It is not about static, it's an early return from this cmake file. The example can not be built if there is no OpenCV and will not be added to the main project. That's it. ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org With regards, Apache Git Services