All of lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCH 1/1] package/tesseract-ocr: fix build on uclibc
@ 2019-07-17 18:17 Fabrice Fontaine
  0 siblings, 0 replies; only message in thread
From: Fabrice Fontaine @ 2019-07-17 18:17 UTC (permalink / raw)
  To: buildroot

Fixes:
 - http://autobuild.buildroot.org/results/bdfbafa105ddf0b9b9399d94b557d318ad587d79

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
---
 ...01-scanutils.cpp-include-sys-types.h.patch | 38 +++++++++++++++++++
 1 file changed, 38 insertions(+)
 create mode 100644 package/tesseract-ocr/0001-scanutils.cpp-include-sys-types.h.patch

diff --git a/package/tesseract-ocr/0001-scanutils.cpp-include-sys-types.h.patch b/package/tesseract-ocr/0001-scanutils.cpp-include-sys-types.h.patch
new file mode 100644
index 0000000000..bbacfb7a86
--- /dev/null
+++ b/package/tesseract-ocr/0001-scanutils.cpp-include-sys-types.h.patch
@@ -0,0 +1,38 @@
+From 0172d83d500a1287b1403e7b9398a1bcd417fdb7 Mon Sep 17 00:00:00 2001
+From: Fabrice Fontaine <fontaine.fabrice@gmail.com>
+Date: Wed, 17 Jul 2019 20:10:23 +0200
+Subject: [PATCH] scanutils.cpp: include sys/types.h
+
+Include sys/types.h (if available) to avoid the following build failure:
+
+scanutils.cpp: In function 'int tvfscanf(FILE*, const char*, va_list)':
+scanutils.cpp:217:3: error: 'off_t' was not declared in this scope
+   off_t start_off = ftell(stream)
+
+Fixes:
+ - http://autobuild.buildroot.org/results/bdfbafa105ddf0b9b9399d94b557d318ad587d79
+
+Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
+[Upstream status: https://github.com/tesseract-ocr/tesseract/pull/2579]
+---
+ src/ccutil/scanutils.cpp | 4 ++++
+ 1 file changed, 4 insertions(+)
+
+diff --git a/src/ccutil/scanutils.cpp b/src/ccutil/scanutils.cpp
+index da0c6918..5c2af6da 100644
+--- a/src/ccutil/scanutils.cpp
++++ b/src/ccutil/scanutils.cpp
+@@ -26,6 +26,10 @@
+ #include <cstring>
+ #include <limits>       // for std::numeric_limits
+ 
++#ifdef HAVE_SYS_TYPES_H
++#include <sys/types.h>  // for off_t
++#endif
++
+ #include "scanutils.h"
+ 
+ enum Flags {
+-- 
+2.20.1
+
-- 
2.20.1

^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2019-07-17 18:17 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-07-17 18:17 [Buildroot] [PATCH 1/1] package/tesseract-ocr: fix build on uclibc Fabrice Fontaine

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.