I am fairly new to the Qt environment and I am running into an error when I try to build. I am also new to StackOverflow so pardon me if I miss format. When I run qmake
from the command line it finds the opencv
package and generates a Makefile, however when I run it from Qt Creator, it fails to find OpenCV.
Here is my .pro file
#-------------------------------------------------
#
# Project created by QtCreator 2013-03-24T21:23:01
#
#-------------------------------------------------
QT += core
QT -= gui
TARGET = cvtest
CONFIG += console
CONFIG -= app_bundle
CONFIG+=link_pkgconfig
PKGCONFIG+=opencv
TEMPLATE = app
SOURCES += main.cpp
I think it has to do with fully qualifying the path to qmake. If I run
qmake /Users/matt/untitled1/untitled1.pro -r -spec macx-g++ CONFIG+=x86_64
on the command line it works fine, however if I fully qualify the path to qmake in the manner that Qt Creator does it;
/Users/matt/Qt5.0.0/5.0.0/clang_64/bin/qmake /Users/matt/untitled1/untitled1.pro
I get the following error:
Project ERROR: Package opencv not found
Any ideas on how to make this work in Qt Creator without going to the command line?