summaryrefslogtreecommitdiffstats
path: root/package/opencv/0003-avoid-sysctl_h.patch
diff options
context:
space:
mode:
authorWaldemar Brodkorb <wbx@openadk.org>2016-04-05 13:16:17 +0200
committerThomas Petazzoni <thomas.petazzoni@free-electrons.com>2016-05-01 23:50:13 +0200
commitf195aad4588e8511d7221c1d9cbfdb370fee1958 (patch)
tree42c8803808498b862e8dcc368b4ecb9c1bec938f /package/opencv/0003-avoid-sysctl_h.patch
parent1a97d49f61e28858e07576a71c64e50b137ceac8 (diff)
downloadbuildroot-f195aad4588e8511d7221c1d9cbfdb370fee1958.tar.gz
buildroot-f195aad4588e8511d7221c1d9cbfdb370fee1958.zip
opencv: fix compile issues
The first patch from Debian fixes following autobuild failure: http://autobuild.buildroot.net/results/eda5c6c43da40a342e0f545a348d2f865eb5ccf2/ Tested with ARM build without a regression. The second patch fixes musl arm autobuild failure: http://autobuild.buildroot.net/results/6a397de789c809984b851a304078e26b2ac58974/ Signed-off-by: Waldemar Brodkorb <wbx@openadk.org> Tested-by: Bernd Kuhls <bernd.kuhls@t-online.de> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Diffstat (limited to 'package/opencv/0003-avoid-sysctl_h.patch')
-rw-r--r--package/opencv/0003-avoid-sysctl_h.patch31
1 files changed, 31 insertions, 0 deletions
diff --git a/package/opencv/0003-avoid-sysctl_h.patch b/package/opencv/0003-avoid-sysctl_h.patch
new file mode 100644
index 0000000000..603220549e
--- /dev/null
+++ b/package/opencv/0003-avoid-sysctl_h.patch
@@ -0,0 +1,31 @@
+From upstream master branch:
+https://github.com/Itseez/opencv/blob/master/modules/core/src/
+
+Do not include sysctl.h targeting Linux systems.
+
+Signed-off-by: Waldemar Brodkorb <wbx@openadk.org>
+
+diff -Nur opencv-2.4.12.3.orig/modules/core/src/parallel.cpp opencv-2.4.12.3/modules/core/src/parallel.cpp
+--- opencv-2.4.12.3.orig/modules/core/src/parallel.cpp 2015-10-26 08:56:34.000000000 +0100
++++ opencv-2.4.12.3/modules/core/src/parallel.cpp 2016-04-05 12:59:37.750143762 +0200
+@@ -56,7 +56,7 @@
+ #include <sys/types.h>
+ #if defined ANDROID
+ #include <sys/sysconf.h>
+- #else
++ #elif defined __APPLE__
+ #include <sys/sysctl.h>
+ #endif
+ #endif
+diff -Nur opencv-2.4.12.3.orig/modules/core/src/system.cpp opencv-2.4.12.3/modules/core/src/system.cpp
+--- opencv-2.4.12.3.orig/modules/core/src/system.cpp 2015-10-26 08:56:34.000000000 +0100
++++ opencv-2.4.12.3/modules/core/src/system.cpp 2016-04-05 13:05:22.468323717 +0200
+@@ -163,7 +163,7 @@
+ #include <sys/types.h>
+ #if defined ANDROID
+ #include <sys/sysconf.h>
+-#else
++#elif defined __APPLE__
+ #include <sys/sysctl.h>
+ #endif
+ #endif
OpenPOWER on IntegriCloud