Felix Fietkau be31d44bd9 ucode-mod-uline: add package for ucode terminal line editing
It provides a ucode module with similar functionality as libreadline,
however with much smaller code and no dependencies aside from ucode and
libubox.
It also provides shell-style parsing/escaping code useful for building
a CLI.

Signed-off-by: Felix Fietkau <nbd@nbd.name>
2025-02-13 19:00:30 +01:00

33 lines
805 B
Makefile

include $(TOPDIR)/rules.mk
PKG_NAME:=ucode-mod-uline
PKG_RELEASE:=$(AUTORELEASE)
PKG_LICENSE:=GPL-2.0-or-later
PKG_MAINTAINER:=Felix Fietkau <nbd@nbd.name>
include $(INCLUDE_DIR)/package.mk
include $(INCLUDE_DIR)/cmake.mk
CMAKE_INSTALL := 1
define Package/ucode-mod-uline
SECTION:=utils
CATEGORY:=Utilities
TITLE:=ucode module for terminal line editing
DEPENDS:=+libucode +libubox
endef
CMAKE_OPTIONS += -DUSE_SYSTEM_WCHAR=ON
define Package/ucode-mod-uline/description
This module provides similar functionality as libreadline for ucode, without
depending on other libraries like ncurses.
endef
define Package/ucode-mod-uline/install
$(INSTALL_DIR) $(1)/usr/lib/ucode
$(CP) $(PKG_INSTALL_DIR)/usr/lib/ucode/uline.so $(1)/usr/lib/ucode/
endef
$(eval $(call BuildPackage,ucode-mod-uline))