diff options
author | wg <wg@FreeBSD.org> | 2013-12-19 02:50:29 +0800 |
---|---|---|
committer | wg <wg@FreeBSD.org> | 2013-12-19 02:50:29 +0800 |
commit | fd65fbf4623933d4681bc70a626b43fbc26ab21b (patch) | |
tree | 1a07ae7d9def23a59fdf057535afce5bdc1a64ca | |
parent | 04c7bbf3304c8076d8e43d608b29a71a58773526 (diff) | |
download | freebsd-ports-gnome-fd65fbf4623933d4681bc70a626b43fbc26ab21b.tar.gz freebsd-ports-gnome-fd65fbf4623933d4681bc70a626b43fbc26ab21b.tar.zst freebsd-ports-gnome-fd65fbf4623933d4681bc70a626b43fbc26ab21b.zip |
devel/py-snack: Not Eriks Windowing Toolkit Python bindings
Newt is a windowing toolkit for text mode built from the slang
library. It allows color text mode applications to easily use
stackable windows, push buttons, check boxes, radio buttons, lists,
entry fields, labels, and displayable text. Scrollbars are supported,
and forms may be nested to provide extra functionality.
WWW: https://fedorahosted.org/newt/
-rw-r--r-- | devel/Makefile | 1 | ||||
-rw-r--r-- | devel/py-snack/Makefile | 42 | ||||
-rw-r--r-- | devel/py-snack/distinfo | 2 | ||||
-rw-r--r-- | devel/py-snack/files/setup.py.in | 15 | ||||
-rw-r--r-- | devel/py-snack/pkg-descr | 14 |
5 files changed, 74 insertions, 0 deletions
diff --git a/devel/Makefile b/devel/Makefile index 33855696e9b0..a155f9ae8308 100644 --- a/devel/Makefile +++ b/devel/Makefile @@ -3782,6 +3782,7 @@ SUBDIR += py-sip SUBDIR += py-six SUBDIR += py-smmap + SUBDIR += py-snack SUBDIR += py-snackwich SUBDIR += py-spark SUBDIR += py-speaklater diff --git a/devel/py-snack/Makefile b/devel/py-snack/Makefile new file mode 100644 index 000000000000..265e8f1dfd27 --- /dev/null +++ b/devel/py-snack/Makefile @@ -0,0 +1,42 @@ +# $FreeBSD$ + +PORTNAME= snack +PORTVERSION= 0.52.16 +CATEGORIES= devel +MASTER_SITES= https://fedorahosted.org/releases/n/e/newt/ +PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX} +DISTNAME= newt-${PORTVERSION} + +MAINTAINER= python@FreeBSD.org +COMMENT= Not Eriks Windowing Toolkit Python bindings + +LIB_DEPENDS= libslang.so:${PORTSDIR}/devel/libslang2 \ + libpopt.so:${PORTSDIR}/devel/popt \ + libnewt.so:${PORTSDIR}/devel/newt + +OPTIONS_DEFINE= EXAMPLES + +GNU_CONFIGURE= yes +CONFIGURE_ARGS= --disable-nls + +USE_PYTHON= 2 +USE_PYDISTUTILS=yes +PYDISTUTILS_AUTOPLIST= yes +PYSETUP= ${WRKDIR}/setup.py + +SUB_FILES= setup.py +SUB_LIST= VERSION=${PORTVERSION} + +PORTEXAMPLES= peanuts.py \ + popcorn.py + +post-patch: apply-slist + @${REINPLACE_CMD} -e 's|/usr/bin/python|${PYTHON_CMD}|' \ + ${WRKSRC}/popcorn.py \ + ${WRKSRC}/peanuts.py + +post-install: + @${MKDIR} ${STAGEDIR}${EXAMPLESDIR} + ${INSTALL_SCRIPT} ${PORTEXAMPLES:S,^,${WRKSRC}/,} ${STAGEDIR}${EXAMPLESDIR} + +.include <bsd.port.mk> diff --git a/devel/py-snack/distinfo b/devel/py-snack/distinfo new file mode 100644 index 000000000000..ea4758162722 --- /dev/null +++ b/devel/py-snack/distinfo @@ -0,0 +1,2 @@ +SHA256 (newt-0.52.16.tar.gz) = 1b9574bc9c8fb7b25cd26e5c3f2840e8c17fde5dd09c759604925919b3589cd3 +SIZE (newt-0.52.16.tar.gz) = 183487 diff --git a/devel/py-snack/files/setup.py.in b/devel/py-snack/files/setup.py.in new file mode 100644 index 000000000000..19ca2cd435f0 --- /dev/null +++ b/devel/py-snack/files/setup.py.in @@ -0,0 +1,15 @@ +from distutils.core import setup, Extension + +setup( + name='snack', + version='%%VERSION%%', + description='Python interface to Newt module', + py_modules=['snack'], + ext_modules=[ Extension( + name='_snack', + sources=['snackmodule.c'], + include_dirs=['.', '%%LOCALBASE%%'+'/include', '%%PREFIX%%'+'/include'], + library_dirs=['.', '%%LOCALBASE%%'+'/lib', '%%PREFIX%%'+'/lib'], + libraries=['newt', 'popt', 'slang', 'ncurses'] + )] +) diff --git a/devel/py-snack/pkg-descr b/devel/py-snack/pkg-descr new file mode 100644 index 000000000000..7af21d278cd8 --- /dev/null +++ b/devel/py-snack/pkg-descr @@ -0,0 +1,14 @@ +Python bindings for Newt toolkit. + +Newt is a windowing toolkit for text mode built from the slang +library. It allows color text mode applications to easily use +stackable windows, push buttons, check boxes, radio buttons, lists, +entry fields, labels, and displayable text. Scrollbars are supported, +and forms may be nested to provide extra functionality. + +Besides the newt library, this port provides whiptail, which may +be used from shell scripts similarly to Savio Lam's "dialog". Newt +provides the textual interface for the Red Hat and Debian boot +disks. + +WWW: https://fedorahosted.org/newt/ |