mirror of
https://github.com/tesseract-ocr/tesseract.git
synced 2025-06-07 18:02:40 +08:00
Fix missing "allheaders.h" when compiling with --enable-opencl on OS X
This commit is contained in:
parent
98292ae435
commit
8f6ebc95c0
@ -219,10 +219,12 @@ case "${host_os}" in
|
|||||||
if test $my_cv_framework_OpenCL = yes; then
|
if test $my_cv_framework_OpenCL = yes; then
|
||||||
have_opencl_lib=true
|
have_opencl_lib=true
|
||||||
fi
|
fi
|
||||||
|
AC_SUBST(OPENCL_OSX, [yes])
|
||||||
;;
|
;;
|
||||||
*)
|
*)
|
||||||
# default
|
# default
|
||||||
AC_CHECK_LIB(OpenCL, clGetPlatformIDs, have_opencl_lib=true, have_opencl_lib=false)
|
AC_CHECK_LIB(OpenCL, clGetPlatformIDs, have_opencl_lib=true, have_opencl_lib=false)
|
||||||
|
AC_SUBST(OPENCL_OSX, [no])
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
|
@ -1,6 +1,10 @@
|
|||||||
AM_CPPFLAGS += -I$(top_srcdir)/ccutil -I$(top_srcdir)/ccstruct -I$(top_srcdir)/ccmain
|
AM_CPPFLAGS += -I$(top_srcdir)/ccutil -I$(top_srcdir)/ccstruct -I$(top_srcdir)/ccmain
|
||||||
if USE_OPENCL
|
if USE_OPENCL
|
||||||
AM_CPPFLAGS += -I$(OPENCL_HDR_PATH)
|
if OPENCL_OSX
|
||||||
|
AM_CFLAGS += -framework OpenCL
|
||||||
|
else
|
||||||
|
AM_CPPFLAGS += -I$(OPENCL_HDR_PATH)
|
||||||
|
endif
|
||||||
endif
|
endif
|
||||||
noinst_HEADERS = \
|
noinst_HEADERS = \
|
||||||
openclwrapper.h oclkernels.h opencl_device_selection.h
|
openclwrapper.h oclkernels.h opencl_device_selection.h
|
||||||
@ -14,7 +18,11 @@ libtesseract_opencl_la_LIBADD = \
|
|||||||
../ccutil/libtesseract_ccutil.la \
|
../ccutil/libtesseract_ccutil.la \
|
||||||
../viewer/libtesseract_viewer.la
|
../viewer/libtesseract_viewer.la
|
||||||
if USE_OPENCL
|
if USE_OPENCL
|
||||||
libtesseract_opencl_la_LDFLAGS += $(OPENCL_LIB)
|
if OPENCL_OSX
|
||||||
|
libtesseract_opencl_la_LDFLAGS += -framework OpenCL
|
||||||
|
else
|
||||||
|
libtesseract_opencl_la_LDFLAGS += $(OPENCL_LIB)
|
||||||
|
endif
|
||||||
endif
|
endif
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user