Bug 592255
| Summary: | Linker shows an error when trying to link cv::imwrite | ||||||
|---|---|---|---|---|---|---|---|
| Product: | [Fedora] Fedora | Reporter: | Anonymous account <M8R-7fin56> | ||||
| Component: | opencv | Assignee: | Rakesh Pandit <rpandit> | ||||
| Status: | CLOSED RAWHIDE | QA Contact: | Fedora Extras Quality Assurance <extras-qa> | ||||
| Severity: | medium | Docs Contact: | |||||
| Priority: | low | ||||||
| Version: | 13 | CC: | karlthered, kklic, kwizart, nomis80, rpandit | ||||
| Target Milestone: | --- | ||||||
| Target Release: | --- | ||||||
| Hardware: | x86_64 | ||||||
| OS: | Linux | ||||||
| Whiteboard: | |||||||
| Fixed In Version: | Doc Type: | Bug Fix | |||||
| Doc Text: | Story Points: | --- | |||||
| Clone Of: | Environment: | ||||||
| Last Closed: | 2011-01-07 08:38:29 UTC | Type: | --- | ||||
| Regression: | --- | Mount Type: | --- | ||||
| Documentation: | --- | CRM: | |||||
| Verified Versions: | Category: | --- | |||||
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||
| Cloudforms Team: | --- | Target Upstream Version: | |||||
| Embargoed: | |||||||
| Attachments: |
|
||||||
Sorry for the late answear: Your code worked with : g++ $(pkg-config --cflags opencv) $(pkg-config --libs opencv) opencv_bug.cpp Only tested on OpenCV 2.2 just updated in Rawhide. So At least Closing to Rawhide. |
Created attachment 414014 [details] The cpp code to reproduce the error. Description of problem: If you try to link a C Plus Plus file, which uses the openCv function cv:: imwrite, it gets an undefined reference error. undefined reference to `cv::imwrite(std::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, cv::Mat const&, std::vector<int, std::allocator<int> > const&)' The strange thing is, that it links all other tested opencv functions like cv::imread successfully. Version-Release number of selected component (if applicable): 2.0.0-7.fc13 How reproducible: Try to compile and link the code in the attachment. Steps to Reproduce: 1. Download the attached code 2. Try to compile and link it: g++ -I/usr/include/opencv -lcxcore -lcv -lhighgui -lcvaux -lml opencv_bug.cpp 3. Actual results: []$ g++ -I/usr/include/opencv -lcxcore -lcv -lhighgui -lcvaux -lml opencv_bug.cpp /tmp/ccBD9wCz.o: In function `main': opencv_bug.cpp:(.text+0xfa): undefined reference to `cv::imwrite(std::basic_string<char, std::char_traits<char>, std::allocator<char> > const&, cv::Mat const&, std::vector<int, std::allocator<int> > const&)' collect2: ld returned 1 exit status Expected results: Compile and link sucessfully. Additional info: