Skip to content

Commit 60799eb

Browse files
ctpv: add new package
ctpv is a terminal file preview utility designed to work with the lf file manager. Signed-off-by: Valeriy Kosikhin <[email protected]>
1 parent 37bfd2b commit 60799eb

File tree

2 files changed

+67
-0
lines changed

2 files changed

+67
-0
lines changed

utils/ctpv/LICENSE

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
MIT License
2+
3+
Copyright (c) 2022 Nikita Ivanov
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in all
13+
copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21+
SOFTWARE.

utils/ctpv/Makefile

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
include $(TOPDIR)/rules.mk
2+
3+
PKG_NAME:=ctpv
4+
PKG_VERSION:=1.1
5+
PKG_RELEASE:=1
6+
7+
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
8+
PKG_SOURCE_URL:=https://codeload.github.com/NikitaIvanovV/ctpv/tar.gz/v$(PKG_VERSION)?
9+
PKG_HASH:=29e458fbc822e960f052b47a1550cb149c28768615cc2dddf21facc5c86f7463
10+
11+
PKG_MAINTAINER:=
12+
PKG_LICENSE:=MIT
13+
PKG_LICENSE_FILES:=LICENSE
14+
15+
PKG_BUILD_PARALLEL:=1
16+
17+
include $(INCLUDE_DIR)/package.mk
18+
19+
define Package/ctpv
20+
SECTION:=utils
21+
CATEGORY:=Utilities
22+
TITLE:=Terminal file previewer
23+
URL:=https://github.com/NikitaIvanovV/ctpv/
24+
DEPENDS:=+libmagic +libopenssl
25+
endef
26+
27+
define Package/ctpv/description
28+
Terminal file preview utility created with the lf file manager in mind.
29+
endef
30+
31+
TARGET_CFLAGS += -fsigned-char
32+
33+
define Build/Compile
34+
$(MAKE) -C $(PKG_BUILD_DIR)/embed \
35+
CC="$(HOSTCC)" \
36+
CFLAGS="$(HOST_CFLAGS)" \
37+
LDFLAGS="$(HOST_LDFLAGS)"
38+
$(call Build/Compile/Default)
39+
endef
40+
41+
define Package/ctpv/install
42+
$(INSTALL_DIR) $(1)/usr/bin
43+
$(INSTALL_BIN) $(PKG_BUILD_DIR)/ctpv $(1)/usr/bin/
44+
endef
45+
46+
$(eval $(call BuildPackage,ctpv))

0 commit comments

Comments
 (0)