mirror of
https://github.com/openwrt/packages.git
synced 2025-07-17 16:54:45 +00:00
Assign some PKG_CPE_IDs to enhance CVE coverage. https://nvd.nist.gov/products/cpe/search/results?namingFormat=2.3&keyword=aardvark-dns https://nvd.nist.gov/products/cpe/search/results?namingFormat=2.3&keyword=alpine_project https://nvd.nist.gov/products/cpe/search/results?namingFormat=2.3&keyword=boringssl https://nvd.nist.gov/products/cpe/search/results?namingFormat=2.3&keyword=ecdsautils https://nvd.nist.gov/products/cpe/search/results?namingFormat=2.3&keyword=file_project https://nvd.nist.gov/products/cpe/search/results?namingFormat=2.3&keyword=knot_resolver https://nvd.nist.gov/products/cpe/search/results?namingFormat=2.3&keyword=libwrap https://nvd.nist.gov/products/cpe/search/results?namingFormat=2.3&keyword=lsof_project https://nvd.nist.gov/products/cpe/search/results?namingFormat=2.3&keyword=nfdump https://nvd.nist.gov/products/cpe/search/results?namingFormat=2.3&keyword=nlnetlabs%20name_server_daemon https://nvd.nist.gov/products/cpe/search/results?namingFormat=2.3&keyword=rclone https://nvd.nist.gov/products/cpe/search/results?namingFormat=2.3&keyword=setserial https://nvd.nist.gov/products/cpe/search/results?namingFormat=2.3&keyword=tang_project https://nvd.nist.gov/products/cpe/search/results?namingFormat=2.3&keyword=tesseract_project https://nvd.nist.gov/products/cpe/search/results?namingFormat=2.3&keyword=tmate-ssh-server https://nvd.nist.gov/products/cpe/search/results?namingFormat=2.3&keyword=ttyd https://nvd.nist.gov/products/cpe/search/results?namingFormat=2.3&keyword=uw-imap https://nvd.nist.gov/products/cpe/search/results?namingFormat=2.3&keyword=v2ray-core https://nvd.nist.gov/products/cpe/search/results?namingFormat=2.3&keyword=zstandard Signed-off-by: Wei-Ting Yang <williamatcg@gmail.com>
64 lines
1.9 KiB
Makefile
64 lines
1.9 KiB
Makefile
# Copyright (C) 2019 Valentin Kivachuk <vk18496@gmail.com>
|
|
#
|
|
# This is free software, licensed under the GNU General Public License v2.
|
|
# See /LICENSE for more information.
|
|
#
|
|
|
|
include $(TOPDIR)/rules.mk
|
|
|
|
PKG_NAME:=tesseract
|
|
PKG_VERSION:=5.4.1
|
|
PKG_RELEASE:=1
|
|
|
|
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
|
|
PKG_SOURCE_URL:=https://codeload.github.com/tesseract-ocr/tesseract/tar.gz/$(PKG_VERSION)?
|
|
PKG_HASH:=c4bc2a81c12a472f445b7c2fb4705a08bd643ef467f51ec84f0e148bd368051b
|
|
|
|
PKG_MAINTAINER:=Valentin Kivachuk <vk18496@gmail.com>
|
|
PKG_LICENSE:=Apache-2.0
|
|
PKG_LICENSE_FILES:=LICENSE
|
|
PKG_CPE_ID:=cpe:/a:tesseract_project:tesseract
|
|
|
|
CMAKE_BINARY_SUBDIR:=openwrt-build
|
|
|
|
include $(INCLUDE_DIR)/package.mk
|
|
include $(INCLUDE_DIR)/cmake.mk
|
|
|
|
define Package/tesseract
|
|
MENU:=1
|
|
SECTION:=utils
|
|
CATEGORY:=Utilities
|
|
TITLE:=Tesseract Open Source OCR Engine
|
|
URL:=https://github.com/tesseract-ocr/tesseract
|
|
DEPENDS:=+libleptonica +libarchive +libpthread +libstdcpp
|
|
endef
|
|
|
|
TARGET_CFLAGS:=$(filter-out -O%,$(TARGET_CFLAGS)) -O3
|
|
|
|
CMAKE_OPTIONS += \
|
|
-DAUTO_OPTIMIZE=OFF \
|
|
-DBUILD_SHARED_LIBS=ON \
|
|
-DBUILD_TRAINING_TOOLS=OFF \
|
|
-DHAVE_NEON=$(if $(or $(findstring aarch64,$(CONFIG_ARCH)),$(findstring neon,$(CONFIG_CPU_TYPE))),TRUE,FALSE) \
|
|
-DDISABLE_CURL=ON
|
|
|
|
define Build/InstallDev
|
|
$(INSTALL_DIR) $(1)/usr/include
|
|
$(CP) $(PKG_INSTALL_DIR)/usr/include/tesseract $(1)/usr/include/
|
|
$(INSTALL_DIR) $(1)/usr/lib
|
|
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libtesseract.so* $(1)/usr/lib/
|
|
$(INSTALL_DIR) $(1)/usr/lib/cmake/tesseract
|
|
$(CP) $(PKG_INSTALL_DIR)/usr/lib/cmake/tesseract/*.cmake $(1)/usr/lib/cmake/tesseract
|
|
$(INSTALL_DIR) $(1)/usr/lib/pkgconfig
|
|
$(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/tesseract.pc $(1)/usr/lib/pkgconfig/
|
|
endef
|
|
|
|
define Package/tesseract/install
|
|
$(INSTALL_DIR) $(1)/usr/bin
|
|
$(CP) $(PKG_INSTALL_DIR)/usr/bin/* $(1)/usr/bin/
|
|
$(INSTALL_DIR) $(1)/usr/lib
|
|
$(CP) $(PKG_INSTALL_DIR)/usr/lib/lib*.so.* $(1)/usr/lib/
|
|
endef
|
|
|
|
$(eval $(call BuildPackage,tesseract))
|