diff -Nru php-facedetect-1.1.0-19-g135c72a/debian/changelog php-facedetect-1.1.0-19-g135c72a/debian/changelog --- php-facedetect-1.1.0-19-g135c72a/debian/changelog 2020-03-02 08:37:04.000000000 +0000 +++ php-facedetect-1.1.0-19-g135c72a/debian/changelog 2021-01-07 23:16:01.000000000 +0000 @@ -1,3 +1,9 @@ +php-facedetect (1.1.0-19-g135c72a-1+rpi1) bullseye-staging; urgency=medium + + * Fix build with opencv 4.5 (Closes: 977248) + + -- Peter Michael Green Thu, 07 Jan 2021 23:16:01 +0000 + php-facedetect (1.1.0-19-g135c72a-1) unstable; urgency=medium * New upstream version 1.1.0-19-g135c72a (used git describe to gen vernum) diff -Nru php-facedetect-1.1.0-19-g135c72a/debian/patches/fix-build-opencv-4.5 php-facedetect-1.1.0-19-g135c72a/debian/patches/fix-build-opencv-4.5 --- php-facedetect-1.1.0-19-g135c72a/debian/patches/fix-build-opencv-4.5 1970-01-01 00:00:00.000000000 +0000 +++ php-facedetect-1.1.0-19-g135c72a/debian/patches/fix-build-opencv-4.5 2021-01-07 23:15:46.000000000 +0000 @@ -0,0 +1,15 @@ +--- php-facedetect-1.1.0-19-g135c72a.orig/config.m4 ++++ php-facedetect-1.1.0-19-g135c72a/config.m4 +@@ -17,7 +17,11 @@ if test "$PHP_FACEDETECT" != "no"; then + PHP_ADD_INCLUDE($CV_INCLUDE) + else + if test -x "$PKG_CONFIG" && $PKG_CONFIG --exists opencv4; then +- CV_INCLUDE=`$PKG_CONFIG opencv4 --variable=includedir_new` ++ if $PKG_CONFIG opencv4 --atleast-version=4.5.0 ; then ++ CV_INCLUDE=`$PKG_CONFIG opencv4 --variable=includedir` ++ else ++ CV_INCLUDE=`$PKG_CONFIG opencv4 --variable=includedir_new` ++ fi + CV_LIBRARY=`$PKG_CONFIG opencv4 --libs` + CV_VERSION=`$PKG_CONFIG opencv4 --modversion` + if $PKG_CONFIG opencv4 --atleast-version=3.0.0 ; then diff -Nru php-facedetect-1.1.0-19-g135c72a/debian/patches/series php-facedetect-1.1.0-19-g135c72a/debian/patches/series --- php-facedetect-1.1.0-19-g135c72a/debian/patches/series 1970-01-01 00:00:00.000000000 +0000 +++ php-facedetect-1.1.0-19-g135c72a/debian/patches/series 2021-01-07 23:15:20.000000000 +0000 @@ -0,0 +1 @@ +fix-build-opencv-4.5