Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

tesseract:

 * add language files


git-svn-id: file:///var/svn/freetz/trunk@10113 149334a1-2f27-0410-a3b9-fc62619ac1e6
  • Loading branch information...
commit 97421deaa3a85dfa301a307456bcdc7cf3e7045f 1 parent 237bbff
er13 authored
View
30 make/tesseract-deu/tesseract-deu.mk
@@ -0,0 +1,30 @@
+$(call PKG_INIT_BIN, 3.02)
+$(PKG)_SOURCE:=tesseract-ocr-$($(PKG)_VERSION).deu.tar.gz
+$(PKG)_SOURCE_MD5:=57bdb26ec7c767e126ff97776d8bfb10
+$(PKG)_SITE:=http://tesseract-ocr.googlecode.com/files
+
+$(PKG)_TARGET_BINARY:=$($(PKG)_DEST_DIR)/usr/share/tessdata/deu.traineddata
+
+define $(PKG)_CUSTOM_UNPACK
+mkdir -p $($(PKG)_DIR); $(call UNPACK_CMD,$(1),$($(PKG)_DIR))
+endef
+
+$(PKG_SOURCE_DOWNLOAD)
+$(PKG_UNPACKED)
+$(PKG_CONFIGURED_NOP)
+
+$($(PKG)_TARGET_BINARY): $($(PKG)_DIR)/.configured
+ @mkdir -p $(dir $@); \
+ cp $(TESSERACT_DEU_DIR)/tesseract-ocr/tessdata/deu.* $(dir $@); \
+ touch -c $@
+
+$(pkg):
+
+$(pkg)-precompiled: $($(PKG)_TARGET_BINARY)
+
+$(pkg)-clean:
+
+$(pkg)-uninstall:
+ $(RM) -r $(dir $(TESSERACT_DEU_TARGET_BINARY))
+
+$(PKG_FINISH)
View
30 make/tesseract-eng/tesseract-eng.mk
@@ -0,0 +1,30 @@
+$(call PKG_INIT_BIN, 3.02)
+$(PKG)_SOURCE:=tesseract-ocr-$($(PKG)_VERSION).eng.tar.gz
+$(PKG)_SOURCE_MD5:=3562250fe6f4e76229a329166b8ae853
+$(PKG)_SITE:=http://tesseract-ocr.googlecode.com/files
+
+$(PKG)_TARGET_BINARY:=$($(PKG)_DEST_DIR)/usr/share/tessdata/eng.traineddata
+
+define $(PKG)_CUSTOM_UNPACK
+mkdir -p $($(PKG)_DIR); $(call UNPACK_CMD,$(1),$($(PKG)_DIR))
+endef
+
+$(PKG_SOURCE_DOWNLOAD)
+$(PKG_UNPACKED)
+$(PKG_CONFIGURED_NOP)
+
+$($(PKG)_TARGET_BINARY): $($(PKG)_DIR)/.configured
+ @mkdir -p $(dir $@); \
+ cp $(TESSERACT_ENG_DIR)/tesseract-ocr/tessdata/eng.* $(dir $@); \
+ touch -c $@
+
+$(pkg):
+
+$(pkg)-precompiled: $($(PKG)_TARGET_BINARY)
+
+$(pkg)-clean:
+
+$(pkg)-uninstall:
+ $(RM) -r $(dir $(TESSERACT_ENG_TARGET_BINARY))
+
+$(PKG_FINISH)
View
11 make/tesseract/Config.in
@@ -5,10 +5,21 @@ config FREETZ_PACKAGE_TESSERACT
bool "Tesseract OCR 3.02.02 (binary only)"
depends on FREETZ_STDCXXLIB_USE_GNULIBSTDCXX
select FREETZ_PACKAGE_TESSERACT_tesseract
+ select FREETZ_PACKAGE_TESSERACT_ENG
default n
help
Tesseract is an Open Source OCR engine
+menu Languages
+ depends on FREETZ_PACKAGE_TESSERACT
+
+ config FREETZ_PACKAGE_TESSERACT_ENG
+ bool "English"
+
+ config FREETZ_PACKAGE_TESSERACT_DEU
+ bool "German"
+endmenu
+
config FREETZ_PACKAGE_TESSERACT_tesseract
bool "tesseract"
depends on FREETZ_PACKAGE_TESSERACT
Please sign in to comment.
Something went wrong with that request. Please try again.