Bug 1416555 - cmake CppMt using opencv-devel complains non-existent path
Summary: cmake CppMt using opencv-devel complains non-existent path
Keywords:
Status: CLOSED WORKSFORME
Alias: None
Product: Fedora
Classification: Fedora
Component: opencv
Version: 25
Hardware: Unspecified
OS: Linux
unspecified
unspecified
Target Milestone: ---
Assignee: Nicolas Chauvet (kwizart)
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2017-01-25 19:29 UTC by Martin
Modified: 2017-02-20 05:27 UTC (History)
9 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2017-02-20 05:27:02 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Martin 2017-01-25 19:29:27 UTC
Description of problem:

Running cmake to build CppMt downloaded from github causes the following error:
CMake Error in CMakeLists.txt:
  Imported target "opencv_xphoto" includes non-existent path
    "//include/opencv"

Version-Release number of selected component (if applicable):
opencv-devel-3.1.0-8.fc25.x86_64

How reproducible:
Always

Steps to Reproduce:
1. git clone GITHUBCOM_URL_TO_CppMt.git
2. cd CppMt*; mkdir build; cd build
3. cmake ..

Actual results:
CMake Error in CMakeLists.txt:
  Imported target "opencv_xphoto" includes non-existent path
    "//include/opencv"

Expected results:
Cmake should use /usr/include/opencv

This works in Fedora 23 x86_64 using opencv-devel-2.4.

Additional info:

Adding the following line in CppMT*/CMakeLists.txt:
message(STATUS "OpenCV_CONFIG_PATH=" ${OpenCV_CONFIG_PATH} " OpenCV_INSTALL_PATH=" ${OpenCV_INSTALL_PATH})

In Fedora 25, I get
-- OpenCV_CONFIG_PATH=/lib64/OpenCV OpenCV_INSTALL_PATH=/

In Fedora 23, I get
-- OpenCV_CONFIG_PATH=/usr/lib64/OpenCV OpenCV_INSTALL_PATH=/usr

It looks like /usr/lib64/OpenCV/OpenCVConfig.cmake finds itself to be in /lib64 rather than /usr/lib64/

Comment 1 Sergio Basto 2017-01-31 17:16:32 UTC
CppMt supports opencv-3 ?

Comment 2 Martin 2017-02-02 01:40:15 UTC
(In reply to Sergio Monteiro Basto from comment #1)
> CppMt supports opencv-3 ?

Yes. That's according to CppMT/README.md:
Dependencies

    OpenCV (>= 2.4.8), OpenCV 3 is supported

Comment 3 Rich Mattes 2017-02-19 16:20:29 UTC
I'm unable to reproduce this in fedora 25, assuming you're getting CppMT from:
https://github.com/gnebehay/CppMT

Are you still seeing this issue?  Do you have a conflicting installation of opencv somewhere?

Comment 4 Martin 2017-02-20 05:27:02 UTC
Thank you so much for verifying this.

It turns out it was a user error: my login profile setting had PATH=/bin:/usr/bin.. instead of PATH=/usr/bin.. for Fedora 25 (my Fedora 23 was setup correctly.)

I got rid of /bin in PATH and that worked fine. Sorry for the bandwidth.


Note You need to log in before you can comment on or make changes to this bug.