Remove most libtiff dependencies

libtiff is no longer needed for OpenCL, so remove that dependency.

It is still suggested for Windows to redirect warning messages
from the tesseract executable to the console.

Signed-off-by: Stefan Weil <sw@weilnetz.de>
This commit is contained in:
Stefan Weil 2017-05-12 09:36:04 +02:00
parent 2b373d1cca
commit 5e3665c6ae
3 changed files with 3 additions and 11 deletions

View File

@ -85,9 +85,8 @@ tesseract_LDFLAGS = $(OPENCL_LDFLAGS)
tesseract_LDADD += $(LEPTONICA_LIBS) tesseract_LDADD += $(LEPTONICA_LIBS)
tesseract_LDADD += $(OPENMP_CXXFLAGS) tesseract_LDADD += $(OPENMP_CXXFLAGS)
tesseract_LDADD += -ltiff
if T_WIN if T_WIN
tesseract_LDADD += -ltiff
tesseract_LDADD += -lws2_32 tesseract_LDADD += -lws2_32
libtesseract_la_LDFLAGS += -no-undefined -Wl,--as-needed -lws2_32 libtesseract_la_LDFLAGS += -no-undefined -Wl,--as-needed -lws2_32
endif endif

View File

@ -78,7 +78,7 @@ AM_CONDITIONAL([GRAPHICS_DISABLED], false)
AC_SUBST([AM_CPPFLAGS]) AC_SUBST([AM_CPPFLAGS])
OPENCL_INC="/opt/AMDAPP/include" OPENCL_INC="/opt/AMDAPP/include"
OPENCL_LIBS="-lOpenCL -ltiff" OPENCL_LIBS="-lOpenCL"
############################# #############################
# #
# Platform specific setup # Platform specific setup
@ -226,7 +226,7 @@ case "${host_os}" in
fi fi
AM_CPPFLAGS="-DUSE_OPENCL $AM_CPPFLAGS" AM_CPPFLAGS="-DUSE_OPENCL $AM_CPPFLAGS"
OPENCL_CPPFLAGS="" OPENCL_CPPFLAGS=""
OPENCL_LDFLAGS="-framework OpenCL -ltiff" OPENCL_LDFLAGS="-framework OpenCL"
fi fi
;; ;;
*) *)
@ -240,9 +240,6 @@ case "${host_os}" in
if !($have_opencl_lib); then if !($have_opencl_lib); then
AC_MSG_ERROR([Required OpenCL library not found!]) AC_MSG_ERROR([Required OpenCL library not found!])
fi fi
if !($have_tiff); then
AC_MSG_ERROR([Required TIFF headers not found! Try to install libtiff-dev?? package.])
fi
AM_CPPFLAGS="-DUSE_OPENCL $AM_CPPFLAGS" AM_CPPFLAGS="-DUSE_OPENCL $AM_CPPFLAGS"
OPENCL_CPPFLAGS="-I${OPENCL_INC}" OPENCL_CPPFLAGS="-I${OPENCL_INC}"
OPENCL_LDFLAGS="${OPENCL_LIBS}" OPENCL_LDFLAGS="${OPENCL_LIBS}"

View File

@ -14,10 +14,6 @@
#include <stdio.h> #include <stdio.h>
#include "allheaders.h" #include "allheaders.h"
#include "pix.h" #include "pix.h"
#ifdef USE_OPENCL
#include "tiff.h"
#include "tiffio.h"
#endif
#include "tprintf.h" #include "tprintf.h"
// including CL/cl.h doesn't occur until USE_OPENCL defined below // including CL/cl.h doesn't occur until USE_OPENCL defined below