GNOME Bugzilla – Bug 672226
opencv: doesn't build on ubuntu oneiric with opencv 2.1
Last modified: 2012-03-17 14:58:27 UTC
configure: *** for plug-ins: opencv *** checking for OPENCV... yes checking whether we are using the GNU C++ compiler... (cached) yes checking whether g++ accepts -g... (cached) yes checking dependency style of g++... (cached) gcc3 checking highgui.h usability... yes checking highgui.h presence... yes checking for highgui.h... yes checking opencv2/highgui/highgui.hpp usability... no checking opencv2/highgui/highgui.hpp presence... no checking for opencv2/highgui/highgui.hpp... no highgui.h could not be found. configure: *** These plugins will not be built: opencv it builds if I modify configure.ac replacing: AC_CHECK_HEADERS(highgui.h opencv2/highgui/highgui.hpp, HAVE_HIGHGUI="yes", HAVE_HIGHGUI="no") with: AC_CHECK_HEADERS(highgui.h, HAVE_HIGHGUI="yes", HAVE_HIGHGUI="no") this probably break the builds with other opencv version, I'm using opencv 2.1 from ubuntu 11.10 (0.10.22 build fine)
The AC_CHECK_HEADERS check isn't right, because it goes into action-if-not-found if it doesn't find one of the headers. I tried to fix it here: http://paste.debian.net/159969/ but it needs more work (fails to compile like that).
Created attachment 209998 [details] [review] opencv: fix configure check and build with opencv 2.1 Could you try this patch please?
yes it works, thanks
commit 692bf9ba633c909efd313259598202d30ce0bb08 Author: Tim-Philipp Müller <tim.muller@collabora.co.uk> Date: Sat Mar 17 12:47:52 2012 +0000 opencv: fix configure check and build with opencv 2.1 AC_CHECK_HEADERS() calls action-if-not-found also if just one of the headers checked for is missing, which is not what we wanted. Also, check for highgui_c.h instead of highgui.hpp. https://bugzilla.gnome.org/show_bug.cgi?id=672226