automake: Flat build for src/opencl

Signed-off-by: Stefan Weil <sw@weilnetz.de>
This commit is contained in:
Stefan Weil 2019-11-26 14:46:35 +01:00
parent 6eeb486b77
commit 558462358a
3 changed files with 18 additions and 17 deletions

View File

@ -20,7 +20,7 @@ endif
.PHONY: doc install-langs ScrollView.jar install-jars training
SUBDIRS = src/viewer src/opencl
SUBDIRS = src/viewer
SUBDIRS += src/wordrec src/textord
SUBDIRS += . tessdata doc unittest
@ -150,11 +150,11 @@ libtesseract_la_LIBADD += libtesseract_dict.la
libtesseract_la_LIBADD += libtesseract_lstm.la
libtesseract_la_LIBADD += libtesseract_main.la
libtesseract_la_LIBADD += libtesseract_native.la
libtesseract_la_LIBADD += libtesseract_opencl.la
libtesseract_la_LIBADD += \
src/textord/libtesseract_textord.la \
src/wordrec/libtesseract_wordrec.la \
src/viewer/libtesseract_viewer.la \
src/opencl/libtesseract_opencl.la
src/viewer/libtesseract_viewer.la
if AVX_OPT
libtesseract_la_LIBADD += libtesseract_avx.la
@ -655,6 +655,21 @@ if TENSORFLOW
libtesseract_lstm_la_SOURCES += src/lstm/tfnetwork.pb.cc
endif
# Rules for src/opencl.
libtesseract_opencl_la_CPPFLAGS = $(AM_CPPFLAGS)
libtesseract_opencl_la_CPPFLAGS += $(OPENCL_CFLAGS)
libtesseract_opencl_la_CPPFLAGS += -I$(top_srcdir)/src/ccutil
libtesseract_opencl_la_CPPFLAGS += -I$(top_srcdir)/src/ccstruct
libtesseract_opencl_la_CPPFLAGS += -I$(top_srcdir)/src/ccmain
noinst_HEADERS += src/opencl/openclwrapper.h
noinst_HEADERS += src/opencl/oclkernels.h
noinst_LTLIBRARIES += libtesseract_opencl.la
libtesseract_opencl_la_SOURCES = src/opencl/openclwrapper.cpp
# Rules for tesseract executable.
bin_PROGRAMS = tesseract

View File

@ -488,7 +488,6 @@ fi
# Output files
AC_CONFIG_FILES([include/tesseract/version.h])
AC_CONFIG_FILES([Makefile tesseract.pc])
AC_CONFIG_FILES([src/opencl/Makefile])
AC_CONFIG_FILES([src/textord/Makefile])
AC_CONFIG_FILES([src/viewer/Makefile])
AC_CONFIG_FILES([src/wordrec/Makefile])

View File

@ -1,13 +0,0 @@
AM_CPPFLAGS += $(OPENCL_CFLAGS) \
-I$(top_srcdir)/include \
-I$(top_srcdir)/src/ccutil \
-I$(top_srcdir)/src/ccstruct \
-I$(top_srcdir)/src/ccmain
noinst_HEADERS = \
openclwrapper.h oclkernels.h
noinst_LTLIBRARIES = libtesseract_opencl.la
libtesseract_opencl_la_SOURCES = \
openclwrapper.cpp