2019-07-14 15:45:10 +00:00
|
|
|
#
|
|
|
|
# Copyright (C) 2019 Valentín Kivachuk <vk18496@gmail.com>
|
|
|
|
#
|
|
|
|
# This is free software, licensed under the GNU General Public License v3.
|
|
|
|
# See /LICENSE for more information.
|
|
|
|
#
|
|
|
|
|
|
|
|
include $(TOPDIR)/rules.mk
|
|
|
|
|
|
|
|
PKG_NAME:=leptonica
|
2021-03-15 02:05:34 +00:00
|
|
|
PKG_VERSION:=1.80.0
|
treewide: remove AUTORELEASE
Automatically compute and substitute current values for all
$(AUTORELEASE) instances as this feature is deprecated and shouldn't be
used.
The following temporary change was made to the core:
diff --git a/rules.mk b/rules.mk
index 57d7995d4fa8..f16367de87a8 100644
--- a/rules.mk
+++ b/rules.mk
@@ -429,7 +429,7 @@ endef
abi_version_str = $(subst -,,$(subst _,,$(subst .,,$(1))))
COMMITCOUNT = $(if $(DUMP),0,$(call commitcount))
-AUTORELEASE = $(if $(DUMP),0,$(call commitcount,1))
+AUTORELEASE = $(if $(DUMP),0,$(shell sed -i "s/\$$(AUTORELEASE)/$(call commitcount,1)/" $(CURDIR)/Makefile))
all:
FORCE: ;
And this command used to fix affected packages:
for i in $(cd feeds/packages; git grep -l PKG_RELEASE:=.*AUTORELEASE | \
sed 's^.*/\([^/]*\)/Makefile^\1^';);
do
make package/$i/download
done
Signed-off-by: Paul Fertser <fercerpav@gmail.com>
2023-04-21 16:32:27 +00:00
|
|
|
PKG_RELEASE:=2
|
2019-07-14 15:45:10 +00:00
|
|
|
|
|
|
|
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
|
|
|
|
PKG_SOURCE_URL:=http://www.leptonica.org/source/
|
2021-03-15 02:05:34 +00:00
|
|
|
PKG_HASH:=ec9c46c2aefbb960fb6a6b7f800fe39de48343437b6ce08e30a8d9688ed14ba4
|
2019-07-14 15:45:10 +00:00
|
|
|
|
|
|
|
PKG_MAINTAINER:=Valentín Kivachuk <vk18496@gmail.com>
|
|
|
|
PKG_LICENSE:=BSD-2-Clause
|
|
|
|
PKG_LICENSE_FILES:=leptonica-license.txt
|
|
|
|
|
2020-07-04 20:34:48 +00:00
|
|
|
CMAKE_BINARY_SUBDIR:=openwrt-build
|
2019-07-14 15:45:10 +00:00
|
|
|
|
|
|
|
include $(INCLUDE_DIR)/package.mk
|
2021-06-10 23:27:06 +00:00
|
|
|
include $(INCLUDE_DIR)/cmake.mk
|
2019-07-14 15:45:10 +00:00
|
|
|
|
|
|
|
define Package/libleptonica
|
|
|
|
SECTION:=libs
|
|
|
|
CATEGORY:=Libraries
|
|
|
|
TITLE:=A library for efficient image processing and image analysis operations
|
|
|
|
URL:=http://www.leptonica.org/
|
2019-09-13 20:02:46 +00:00
|
|
|
DEPENDS:=+giflib +libjpeg +libpng +libtiff +libwebp +zlib
|
2019-07-14 15:45:10 +00:00
|
|
|
endef
|
|
|
|
|
2021-03-15 02:05:34 +00:00
|
|
|
CMAKE_OPTIONS += \
|
|
|
|
-DBUILD_SHARED_LIBS=ON \
|
|
|
|
-DWEBPMUX_INCLUDE_DIR=$(STAGING_DIR)/usr/include
|
|
|
|
|
2019-07-14 15:45:10 +00:00
|
|
|
TARGET_CFLAGS:=$(filter-out -O%,$(TARGET_CFLAGS)) -O3
|
|
|
|
|
|
|
|
define Build/InstallDev
|
2020-07-04 20:34:48 +00:00
|
|
|
$(INSTALL_DIR) $(1)/usr/include/leptonica
|
|
|
|
$(CP) $(PKG_INSTALL_DIR)/usr/include/leptonica/*.h $(1)/usr/include/leptonica/
|
2019-07-14 15:45:10 +00:00
|
|
|
$(INSTALL_DIR) $(1)/usr/lib
|
2020-07-04 20:34:48 +00:00
|
|
|
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libleptonica.so* $(1)/usr/lib/
|
|
|
|
$(INSTALL_DIR) $(1)/usr/lib/cmake
|
|
|
|
$(CP) $(PKG_INSTALL_DIR)/usr/cmake/*.cmake $(1)/usr/lib/cmake/
|
2019-07-14 15:45:10 +00:00
|
|
|
$(INSTALL_DIR) $(1)/usr/lib/pkgconfig
|
|
|
|
$(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/lept.pc $(1)/usr/lib/pkgconfig/
|
|
|
|
endef
|
|
|
|
|
|
|
|
define Package/libleptonica/install
|
|
|
|
$(INSTALL_DIR) $(1)/usr/lib
|
2020-07-04 20:34:48 +00:00
|
|
|
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libleptonica.so.* $(1)/usr/lib/
|
2019-07-14 15:45:10 +00:00
|
|
|
endef
|
|
|
|
|
|
|
|
$(eval $(call BuildPackage,libleptonica))
|