Can't build after opencv upgrade

Open
#7 2 comments 0 reactions 1 assignee View on GitHub

@jonsneyers is already working on this.

Since Jan 11, 2019.

Assessment

This issue has not been assessed yet.

Description

OS X / 10.14.2

$ make
g++ -std=c++11 -O2 -fstrict-aliasing -ffast-math `pkg-config --cflags opencv` ssimulacra.cpp `pkg-config --libs-only-L opencv` -lopencv_core -lopencv_highgui -lopencv_imgcodecs -lopencv_imgproc -o ssimulacra
Package opencv was not found in the pkg-config search path.
Perhaps you should add the directory containing `opencv.pc'
to the PKG_CONFIG_PATH environment variable
No package 'opencv' found
Package opencv was not found in the pkg-config search path.
Perhaps you should add the directory containing `opencv.pc'
to the PKG_CONFIG_PATH environment variable
No package 'opencv' found
ssimulacra.cpp:81:10: fatal error: 'cv.hpp' file not found
#include <cv.hpp>
         ^~~~~~~~
1 error generated.
make: *** [ssimulacra] Error 1

I’m guessing this is related to the fact that Homebrew recently upgraded my OpenCV to version 4.0.1. I took a stab at fixing it by finding something that looked like opencv.pc and symlinking it to that path:

$ ln -s /usr/local/Cellar/opencv/4.0.1/lib/pkgconfig/opencv4.pc /usr/local/lib/pkgconfig/opencv.pc

That got rid of the first error, but did not fix the second (fatal error: 'cv.hpp' file not found).

Any advice? Should I try to install an earlier version of OpenCV?

Dominant language
C++
Stars
101
Forks
14
PR merge metrics
No merged PRs in 30d

Getting set up

This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from cloudinary/ssimulacra

All issues in cloudinary/ssimulacra

Similar issues

More C++ issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.