mirror of
https://github.com/novatiq/packages.git
synced 2026-04-29 15:08:40 +01:00
Merge pull request #8862 from jefferyto/byobu
byobu: Add new package and dependencies
This commit is contained in:
@@ -0,0 +1,128 @@
|
||||
#
|
||||
# Copyright (C) 2006-2011 OpenWrt.org
|
||||
# Copyright (C) 2011 SMBPhone Inc.
|
||||
# Copyright (C) 2019 Jeffery To
|
||||
#
|
||||
# This is free software, licensed under the GNU General Public License v2.
|
||||
# See /LICENSE for more information.
|
||||
#
|
||||
|
||||
include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG_NAME:=newt
|
||||
PKG_VERSION:=0.52.20
|
||||
PKG_RELEASE:=1
|
||||
|
||||
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
|
||||
PKG_SOURCE_URL:=https://releases.pagure.org/newt
|
||||
PKG_HASH:=8d66ba6beffc3f786d4ccfee9d2b43d93484680ef8db9397a4fb70b5adbb6dbc
|
||||
|
||||
PKG_LICENSE:=LGPL-2.0
|
||||
PKG_LICENSE_FILES:=COPYING
|
||||
PKG_CPE_ID:=cpe:/a:fedorahosted:newt
|
||||
PKG_MAINTAINER:=Jeffery To <jeffery.to@gmail.com>
|
||||
|
||||
PKG_BUILD_PARALLEL:=1
|
||||
PKG_INSTALL:=1
|
||||
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
include ../../lang/python/python3-package.mk
|
||||
|
||||
define Package/newt/Default
|
||||
TITLE:=Newt
|
||||
URL:=https://pagure.io/newt
|
||||
endef
|
||||
|
||||
define Package/newt/Default/description
|
||||
Newt is a programming library for color text mode, widget based user
|
||||
interfaces. Newt can be used to add stacked windows, entry widgets,
|
||||
checkboxes, radio buttons, labels, plain text fields, scrollbars, etc.,
|
||||
to text mode user interfaces. Newt is based on the slang library.
|
||||
endef
|
||||
|
||||
define Package/libnewt
|
||||
$(call Package/newt/Default)
|
||||
SECTION:=libs
|
||||
CATEGORY:=Libraries
|
||||
TITLE+= library
|
||||
DEPENDS:=+libslang2
|
||||
endef
|
||||
|
||||
define Package/libnewt/description
|
||||
$(call Package/newt/Default/description)
|
||||
endef
|
||||
|
||||
define Package/whiptail
|
||||
$(call Package/newt/Default)
|
||||
SECTION:=utils
|
||||
CATEGORY:=Utilities
|
||||
TITLE:=Display dialog boxes from shell scripts
|
||||
DEPENDS:=+libnewt +libpopt +libslang2
|
||||
endef
|
||||
|
||||
define Package/whiptail/description
|
||||
A lightweight replacement for the dialog command (dialog boxes from shell
|
||||
scripts), based on libnewt.
|
||||
endef
|
||||
|
||||
define Package/python3-newt
|
||||
$(call Package/newt/Default)
|
||||
SECTION:=lang
|
||||
CATEGORY:=Languages
|
||||
SUBMENU:=Python
|
||||
TITLE+= module for Python
|
||||
DEPENDS:=+libnewt +python3-light
|
||||
VARIANT:=python3
|
||||
endef
|
||||
|
||||
define Package/python3-newt/description
|
||||
$(call Package/newt/Default/description)
|
||||
|
||||
This is the Newt module for Python 3.
|
||||
endef
|
||||
|
||||
TARGET_CFLAGS+= $(FPIC)
|
||||
|
||||
CONFIGURE_ARGS+= \
|
||||
--enable-largefile \
|
||||
--with-python \
|
||||
--without-tcl \
|
||||
--without-gpm-support \
|
||||
--with-colorsfile=/etc/newt/palette
|
||||
|
||||
CONFIGURE_VARS+= PYTHONVERS="python$(PYTHON3_VERSION)"
|
||||
|
||||
MAKE_VARS+= PYTHON_CONFIG_PATH="$(STAGING_DIR)/usr/bin"
|
||||
|
||||
Build/Compile=$(call Build/Compile/Default,)
|
||||
|
||||
define Build/InstallDev
|
||||
$(INSTALL_DIR) $(1)/usr/include
|
||||
$(CP) $(PKG_INSTALL_DIR)/usr/include/newt.h $(1)/usr/include/
|
||||
|
||||
$(INSTALL_DIR) $(1)/usr/lib
|
||||
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libnewt.{a,so*} $(1)/usr/lib/
|
||||
|
||||
$(INSTALL_DIR) $(1)/usr/lib/pkgconfig
|
||||
$(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/libnewt.pc $(1)/usr/lib/pkgconfig/
|
||||
endef
|
||||
|
||||
define Package/libnewt/install
|
||||
$(INSTALL_DIR) $(1)/usr/lib
|
||||
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libnewt.so* $(1)/usr/lib/
|
||||
endef
|
||||
|
||||
define Package/whiptail/install
|
||||
$(INSTALL_DIR) $(1)/usr/bin
|
||||
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/whiptail $(1)/usr/bin/
|
||||
endef
|
||||
|
||||
# Don't install files from usr/bin
|
||||
Py3Package/python3-newt/install:=:
|
||||
|
||||
$(eval $(call BuildPackage,libnewt))
|
||||
$(eval $(call BuildPackage,whiptail))
|
||||
|
||||
$(eval $(call Py3Package,python3-newt))
|
||||
$(eval $(call BuildPackage,python3-newt))
|
||||
$(eval $(call BuildPackage,python3-newt-src))
|
||||
@@ -0,0 +1,10 @@
|
||||
--- a/configure
|
||||
+++ b/configure
|
||||
@@ -3957,7 +3957,6 @@ if test "x$with_python" = "xno"; then
|
||||
$as_echo "skipped" >&6; }
|
||||
PYTHONVERS=
|
||||
else
|
||||
- PYTHONVERS=$(ls /usr/include/python*/Python.h 2> /dev/null | sed 's|.*\(python[0-9]*\.[0-9]*\).*|\1|g' | tr '\n' ' ')
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $PYTHONVERS" >&5
|
||||
$as_echo "$PYTHONVERS" >&6; }
|
||||
fi
|
||||
@@ -0,0 +1,25 @@
|
||||
--- a/Makefile.in
|
||||
+++ b/Makefile.in
|
||||
@@ -84,12 +84,7 @@ showkey: showkey.o $(LIBNEWT)
|
||||
|
||||
_snack.$(SOEXT): snack.c $(LIBNEWTSH)
|
||||
@[ -n "$(PYTHONVERS)" ] && for ver in $(PYTHONVERS); do \
|
||||
- pyconfig=$$ver-config; \
|
||||
- if ! $$pyconfig --cflags > /dev/null 2>&1 && \
|
||||
- python-config --cflags > /dev/null 2>&1; then \
|
||||
- echo $$pyconfig not found, using python-config; \
|
||||
- pyconfig=python-config; \
|
||||
- fi; \
|
||||
+ pyconfig=$(PYTHON_CONFIG_PATH)/$$ver-config; \
|
||||
mkdir -p $$ver; \
|
||||
PCFLAGS=`$$pyconfig --cflags`; \
|
||||
PIFLAGS=`$$pyconfig --includes`; \
|
||||
@@ -109,7 +104,7 @@ whiptcl.$(SOEXT): $(WHIPTCLOBJS) $(LIBNE
|
||||
$(CC) -shared $(SHCFLAGS) $(LDFLAGS) -o whiptcl.$(SOEXT) $(WHIPTCLOBJS) -L. -lnewt $(LIBTCL) -lpopt $(LIBS)
|
||||
|
||||
$(LIBNEWT): $(LIBOBJS)
|
||||
- ar rv $@ $^
|
||||
+ $(AR) rv $@ $^
|
||||
|
||||
newt.o $(SHAREDDIR)/newt.o: newt.c Makefile
|
||||
|
||||
@@ -0,0 +1,24 @@
|
||||
Author: Alastair McKinstry <mckinstry@debian.org>
|
||||
Description: newtInit() should only be called once
|
||||
Bug-Debian: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=557960
|
||||
Forwarded: no
|
||||
Last-Updated: 2014-06-11
|
||||
|
||||
--- a/snack.c
|
||||
+++ b/snack.c
|
||||
@@ -377,10 +377,15 @@ static snackWidget * snackWidgetNew (voi
|
||||
}
|
||||
|
||||
static PyObject * initScreen(PyObject * s, PyObject * args) {
|
||||
+ static int init_newt = 1;
|
||||
suspend.cb = NULL;
|
||||
suspend.data = NULL;
|
||||
|
||||
newtInit();
|
||||
+ if (init_newt) {
|
||||
+ newtInit();
|
||||
+ init_newt = 0;
|
||||
+ }
|
||||
newtCls();
|
||||
|
||||
Py_INCREF(Py_None);
|
||||
@@ -0,0 +1,35 @@
|
||||
Author: Thomas Viehmann <tv@beamnet.de>
|
||||
Description: Fix for python memory handling
|
||||
Bug-Debian: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=445392
|
||||
Last-Updated: 2014-06-11
|
||||
Forwarded: no
|
||||
|
||||
--- a/snack.c
|
||||
+++ b/snack.c
|
||||
@@ -366,7 +366,7 @@ static PyTypeObject snackWidgetType = {
|
||||
static snackWidget * snackWidgetNew (void) {
|
||||
snackWidget * widget;
|
||||
|
||||
- widget = PyObject_NEW(snackWidget, &snackWidgetType);
|
||||
+ widget = PyObject_New(snackWidget, &snackWidgetType);
|
||||
if (!widget)
|
||||
return NULL;
|
||||
|
||||
@@ -937,7 +937,7 @@ static snackForm * formCreate(PyObject *
|
||||
if (help == Py_None)
|
||||
help = NULL;
|
||||
|
||||
- form = PyObject_NEW(snackForm, &snackFormType);
|
||||
+ form = PyObject_New(snackForm, &snackFormType);
|
||||
form->fo = newtForm(NULL, help, 0);
|
||||
|
||||
return form;
|
||||
@@ -949,7 +949,7 @@ static snackGrid * gridCreate(PyObject *
|
||||
|
||||
if (!PyArg_ParseTuple(args, "ii", &cols, &rows)) return NULL;
|
||||
|
||||
- grid = PyObject_NEW(snackGrid, &snackGridType);
|
||||
+ grid = PyObject_New(snackGrid, &snackGridType);
|
||||
grid->grid = newtCreateGrid(cols, rows);
|
||||
|
||||
return grid;
|
||||
@@ -0,0 +1,176 @@
|
||||
#
|
||||
# Copyright (C) 2006-2011 Openwrt.org
|
||||
# Copyright (C) 2011 SMBPhone Inc.
|
||||
# Copyright (C) 2019 Jeffery To
|
||||
#
|
||||
# This is free software, licensed under the GNU General Public License v2.
|
||||
# See /LICENSE for more information.
|
||||
#
|
||||
|
||||
include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG_NAME:=slang
|
||||
PKG_VERSION:=2.3.2
|
||||
PKG_RELEASE:=1
|
||||
|
||||
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
|
||||
PKG_SOURCE_URL:=https://www.jedsoft.org/releases/slang \
|
||||
https://www.jedsoft.org/releases/slang/old
|
||||
PKG_HASH:=fc9e3b0fc4f67c3c1f6d43c90c16a5c42d117b8e28457c5b46831b8b5d3ae31a
|
||||
|
||||
PKG_LICENSE:=GPL-2.0+
|
||||
PKG_LICENSE_FILES:=COPYING
|
||||
PKG_MAINTAINER:=Jeffery To <jeffery.to@gmail.com>
|
||||
|
||||
PKG_BUILD_PARALLEL:=1
|
||||
|
||||
SLANG_MODULES:= base64 chksum csv fcntl fork histogram iconv json pcre png \
|
||||
rand select slsmg socket stats sysconf termios varray zlib
|
||||
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
|
||||
define Package/libslang2/Default
|
||||
SECTION:=libs
|
||||
CATEGORY:=Libraries
|
||||
TITLE:=S-Lang Programmer's Library
|
||||
URL:=https://www.jedsoft.org/slang/
|
||||
endef
|
||||
|
||||
define Package/libslang2/Default/description
|
||||
Multi-platform programmer's library providing facilities for interactive
|
||||
applications. Includes such things as display/screen management,
|
||||
keyboard input, keymaps, etc. Includes the embeddable S-Lang interpreter.
|
||||
endef
|
||||
|
||||
define Package/libslang2
|
||||
$(call Package/libslang2/Default)
|
||||
DEPENDS:=+terminfo
|
||||
endef
|
||||
|
||||
define Package/libslang2/description
|
||||
$(call Package/libslang2/Default/description)
|
||||
endef
|
||||
|
||||
define Package/libslang2-modules
|
||||
$(call Package/libslang2/Default)
|
||||
TITLE+= (all modules)
|
||||
DEPENDS:=$(foreach mod,$(SLANG_MODULES),+libslang2-mod-$(mod))
|
||||
endef
|
||||
|
||||
define Package/libslang2-modules/description
|
||||
$(call Package/libslang2/Default/description)
|
||||
|
||||
This installs all of S-Lang's bundled modules.
|
||||
endef
|
||||
|
||||
define Package/libslang2-mod-pcre
|
||||
$(call Package/libslang2/Default)
|
||||
TITLE+= (pcre module)
|
||||
DEPENDS:=+libpcre
|
||||
endef
|
||||
|
||||
define Package/libslang2-mod-png
|
||||
$(call Package/libslang2/Default)
|
||||
TITLE+= (png module)
|
||||
DEPENDS:=+libpng
|
||||
endef
|
||||
|
||||
define Package/libslang2-mod-zlib
|
||||
$(call Package/libslang2/Default)
|
||||
TITLE+= (zlib module)
|
||||
DEPENDS:=+zlib
|
||||
endef
|
||||
|
||||
define Package/slsh
|
||||
SECTION:=lang
|
||||
CATEGORY:=Languages
|
||||
TITLE:=S-Lang shell
|
||||
URL:=https://www.jedsoft.org/slang/slsh.html
|
||||
DEPENDS:=+libslang2 +libslang2-modules
|
||||
endef
|
||||
|
||||
define Package/slsh/description
|
||||
This is a shell which is mostly just a wrapper around the S-Lang Interpreter,
|
||||
which is part of the S-Lang Library.
|
||||
endef
|
||||
|
||||
TARGET_CFLAGS+= $(FPIC)
|
||||
|
||||
CONFIGURE_ARGS+= \
|
||||
--enable-largefile \
|
||||
--enable-warnings \
|
||||
--with-terminfo=default \
|
||||
--with-readline=slang \
|
||||
--with-pcre="$(STAGING_DIR)/usr" \
|
||||
--with-png="$(STAGING_DIR)/usr" \
|
||||
--with-z="$(STAGING_DIR)/usr" \
|
||||
--without-onig \
|
||||
--without-x
|
||||
|
||||
define Build/Compile
|
||||
$(call Build/Compile/Default,)
|
||||
$(call Build/Compile/Default,static)
|
||||
endef
|
||||
|
||||
# Default install last, so that the dynamic slsh is installed
|
||||
define Build/Install
|
||||
$(call Build/Install/Default,install-static)
|
||||
$(call Build/Install/Default,)
|
||||
endef
|
||||
|
||||
define Build/InstallDev
|
||||
$(INSTALL_DIR) $(1)/usr/include
|
||||
$(CP) $(PKG_INSTALL_DIR)/usr/include/*.h $(1)/usr/include/
|
||||
|
||||
$(INSTALL_DIR) $(1)/usr/lib
|
||||
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libslang.{a,so*} $(1)/usr/lib/
|
||||
|
||||
$(INSTALL_DIR) $(1)/usr/lib/pkgconfig
|
||||
$(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/slang.pc $(1)/usr/lib/pkgconfig/
|
||||
endef
|
||||
|
||||
define Package/libslang2/install
|
||||
$(INSTALL_DIR) $(1)/usr/lib
|
||||
$(CP) $(PKG_INSTALL_DIR)/usr/lib/libslang.so* $(1)/usr/lib/
|
||||
endef
|
||||
|
||||
Package/libslang2-modules/install:=:
|
||||
|
||||
define Package/slsh/install
|
||||
$(INSTALL_DIR) $(1)/etc
|
||||
$(CP) $(PKG_INSTALL_DIR)/etc/slsh.rc $(1)/etc/
|
||||
|
||||
$(INSTALL_DIR) $(1)/usr/bin
|
||||
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/slsh $(1)/usr/bin/
|
||||
|
||||
$(INSTALL_DIR) $(1)/usr/share
|
||||
$(CP) $(PKG_INSTALL_DIR)/usr/share/slsh/ $(1)/usr/share/
|
||||
endef
|
||||
|
||||
define BuildModule
|
||||
ifndef Package/libslang2-mod-$(1)
|
||||
define Package/libslang2-mod-$(1)
|
||||
$$(call Package/libslang2/Default)
|
||||
TITLE+= ($(1) module)
|
||||
endef
|
||||
endif
|
||||
|
||||
define Package/libslang2-mod-$(1)/description
|
||||
$$(call Package/libslang2/Default/description)
|
||||
|
||||
This contains the $(1) module.
|
||||
endef
|
||||
|
||||
define Package/libslang2-mod-$(1)/install
|
||||
$$(INSTALL_DIR) $$(1)/usr/lib/slang/v2/modules
|
||||
$$(CP) $$(PKG_INSTALL_DIR)/usr/lib/slang/v2/modules/$(1)-module.so $$(1)/usr/lib/slang/v2/modules/
|
||||
endef
|
||||
|
||||
$$(eval $$(call BuildPackage,libslang2-mod-$(1)))
|
||||
endef
|
||||
|
||||
$(foreach mod,$(SLANG_MODULES),$(eval $(call BuildModule,$(mod))))
|
||||
|
||||
$(eval $(call BuildPackage,libslang2))
|
||||
$(eval $(call BuildPackage,libslang2-modules))
|
||||
$(eval $(call BuildPackage,slsh))
|
||||
@@ -0,0 +1,11 @@
|
||||
--- a/configure
|
||||
+++ b/configure
|
||||
@@ -7029,7 +7029,7 @@ TERMCAP=-ltermcap
|
||||
|
||||
for terminfo_dir in $JD_Terminfo_Dirs
|
||||
do
|
||||
- if test -d $terminfo_dir
|
||||
+ if true
|
||||
then
|
||||
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
|
||||
$as_echo "yes" >&6; }
|
||||
@@ -0,0 +1,11 @@
|
||||
--- a/src/Makefile.in
|
||||
+++ b/src/Makefile.in
|
||||
@@ -73,7 +73,7 @@ INSTALL_DATA = @INSTALL_DATA@
|
||||
MKINSDIR = @CONFIG_DIR@/autoconf/mkinsdir.sh
|
||||
RM = rm -f
|
||||
RM_R = rm -rf
|
||||
-AR_CR = ar cr
|
||||
+AR_CR = $(AR) cr
|
||||
RMDIR = rmdir
|
||||
LN = /bin/ln -sf
|
||||
CP = cp
|
||||
Reference in New Issue
Block a user