Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 17 May 2000 18:12:57 -0700 (PDT)
From:      Arun Sharma <adsharma@sharmas.dhs.org>
To:        FreeBSD-gnats-submit@freebsd.org
Subject:   ports/18633: New port - pyncurses
Message-ID:  <200005180112.SAA68944@sharmas.dhs.org>

next in thread | raw e-mail | index | archive | help

>Number:         18633
>Category:       ports
>Synopsis:       New port pyncurses-0.3
>Confidential:   yes
>Severity:       non-critical
>Priority:       medium
>Responsible:    freebsd-ports
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Wed May 17 18:20:00 PDT 2000
>Closed-Date:
>Last-Modified:
>Originator:     Arun Sharma
>Release:        FreeBSD 4.0-STABLE i386
>Organization:
>Environment:

FreeBSD 4.0-STABLE i386

>Description:

New port.

>How-To-Repeat:

>Fix:

# This is a shell archive.  Save it in a file, remove anything before
# this line, and then unpack it by entering "sh file".  Note, it may
# create directories; files and directories will be owned by you and
# have default permissions.
#
# This archive contains:
#
#	python/pyncurses
#	python/pyncurses/Makefile
#	python/pyncurses/pkg
#	python/pyncurses/pkg/COMMENT
#	python/pyncurses/pkg/DESCR
#	python/pyncurses/pkg/PLIST
#	python/pyncurses/files
#	python/pyncurses/files/md5
#	python/pyncurses/patches
#	python/pyncurses/patches/patch-aa
#
echo c - python/pyncurses
mkdir -p python/pyncurses > /dev/null 2>&1
echo x - python/pyncurses/Makefile
sed 's/^X//' >python/pyncurses/Makefile << 'END-of-python/pyncurses/Makefile'
X# New ports collection makefile for:	pyncurses
X# Version required:	0.3
X# Date created:		Tue May 16 22:15:11 PDT 2000
X# Whom:			adsharma@sharams.dhs.org
X#
X# $FreeBSD: ports/devel/sip/Makefile,v 1.1 2000/04/22 21:27:54 will Exp $
X#
X
XDISTNAME=	pyncurses-0.3
XCATEGORIES=	devel python
XMASTER_SITES=	http://download.sourceforge.net/pyncurses/
X
XMAINTAINER=	adsharma@sharmas.dhs.org
X
XPORTNAME=	pyncurses
XPORTVERSION=	0.3
X
Xdo-build:
X	cd ${WRKSRC}/ncurses; make
X	cd ${WRKSRC}; python setup.py build
X
Xdo-install:
X	cd ${WRKSRC}; python setup.py install
X
X.include <bsd.port.mk>
END-of-python/pyncurses/Makefile
echo c - python/pyncurses/pkg
mkdir -p python/pyncurses/pkg > /dev/null 2>&1
echo x - python/pyncurses/pkg/COMMENT
sed 's/^X//' >python/pyncurses/pkg/COMMENT << 'END-of-python/pyncurses/pkg/COMMENT'
XNcurses binding for Python
END-of-python/pyncurses/pkg/COMMENT
echo x - python/pyncurses/pkg/DESCR
sed 's/^X//' >python/pyncurses/pkg/DESCR << 'END-of-python/pyncurses/pkg/DESCR'
XPyNcurses now requires the Python Distutils to build and install, they can be
Xobtained from the pyncurses ftp site. The INSTALL file included with PyNcurses
Xcan be used as installation instructions for both PyNncurses and the Python
XDistutils.
X
XPyNcurses now includes the C source code generated by SWIG, so SWIG is no
Xlonger required to build the distribution. If you do have SWIG there is now a
Xmakefile included in the ncurses directory which will regenerate C source files
Xfor any interface files that have been altered. This will have to be done
Xbefore running setup.py if you alter any interface files.
X
XIf you get a group of "conflicting types for `*'" errors run the following
Xcommand:
X
Xdebian/apply-patch.sh
X
XThis will apply a patch fixing the problem.
X
XPyNcurses is now complete in the sense that all classes can be initialized. In 
Xaddition the curses module has been tested to make sure it is usable (for me.)
XIf anyone can tell me what places it is not usable for them I will do my best
Xto fix them (especially if you have a fix ready for me to apply :) ) My email
Xaddress is hgebel@inet.net .
X
XRudimentary examples can be found in the examples/ directory . I will gladly
Xaccept any other samples provided.
X
XCVS, a mailing list, and a bug reporting system can be found on the Source
XForge project page, a link to which can be found near the bottom of 
Xhttp://pyncurses.sourceforge.net .
X
XThere are no user pointer functions in this library, if you wish to store date
Xabout an object in that object it is easily accomplished in Python:
X
X# store user data in PANEL:
Xsample = []
Xsample.append(PANEL(10,10,5,5))
Xsample[-1].about = "Keep me"
X
Xsample.append(PANEL(10,20,0,0))
Xsample[-1].about = "Get rid of me"
X
Xsample.append(PANEL(5,15,10,10))
Xsample[-1].about = "Keep me"
X
Xfor index in xrange(len(sample) - 1, -1, -1):
X  if sample[index].about == "Get rid of me":
X    del sample[index]
X
XNote that all objects contain an attribute called user_data (initialized to
XNone) which is intended to be used to store this sort of data. This is to help 
Xprevent NameErrors which could otherwise be caused if you only set an attribute
Xon a few objects.
X
Xcurses:
X no delwin function or method, called automatically when WINDOW class instance
X is garbage collected.
X
X no functions which use SCREEN pointers
X
X no functions which use FILE pointers
X
X no functions documented on the curs_terminfo manual page
X
X few functions implemented as macros.
X
X callback functions except for field validation in libform.
X
X No mouse support.
X
X Note that some of these functions are in the _curses module
X if they are required
X
X If you use any of these often notify me so I can move them into the curses
X module where they will be more convenient.
X
X the ACS constants can be accessed with functions ie to access ACS_LLCORNER
X call ACS_LLCORNER()
X
X My programs do not use color, I would appreciate it if someone who does can
X tell me if this module has sufficient color support.
X
Xpanel:
X panel imports all names in the curses module, so it is not necessary to import
X both curses and panel.
X
X panel.doupdate() automatically calls panel.update_panels() it is not
X necessary to call both.
X
X PANEL classes include a WINDOW object, which is deleted when panel is garbage
X collected.
X
X panel_above and panel_below take as an argument a list of PANELs and return a
X reference to the appropriate PANEL. If you wish to use these functions keep
X your PANELs in a list, take care that when you want to destroy a panel you
X remove all referances to it.
X
X All support for mixing WINDOWs and PANELs has been removed as of version 
X 0.0b3 . I felt that the functions involved, in addition to making the library
X hard to maintain, where unnecessary and needlessly confusing to people trying
X to use the library. If I was wrong and this capability is necessary for some
X reason you will have to tell me.
X
X new functions get_top and get_bottom take a list of PANELs and return a
X reference to the appropriate panel.
X
X I don't use libpanel, so it is up to users to tell me about places where it is
X not effective.
X
Xmenu:
X
X MENU.current_item() no longer requires that a list of ITEMs be provided as an
Xargument, however it still support being called that way for compatability.
X
X menu imports all names from panel. It adds a module level variable called
X "_update_mode" whose default value is "curses" . If it's value is "panel" then
X doupdate will call update_panels, if it is "curses" then it will not. The
X function menu_set_update_mode() and menu_get_update_mode() have been provided
X to access this variable.
X
X Note that the default value of _update_mode was 'panel' in previous releases,
X programs which assume panel is the default mode will have to be altered.
X
Xform:
X form also has and _update_mode variable, it can be accessed with
X form_set_update_mode() and form_get_update_mode.
X
X form has a class LABEL that represents fields to be used as labels, it's
X arguments are different than the FIELD class, read the source for
X documentation.
X
X form now supports field type validation.
X
XThe SWIG pointer manipulation functions can be found in _curses.
X
END-of-python/pyncurses/pkg/DESCR
echo x - python/pyncurses/pkg/PLIST
sed 's/^X//' >python/pyncurses/pkg/PLIST << 'END-of-python/pyncurses/pkg/PLIST'
Xlib/python1.5/site-packages/ncurses/__init__.py
Xlib/python1.5/site-packages/ncurses/curses.py
Xlib/python1.5/site-packages/ncurses/form.py
Xlib/python1.5/site-packages/ncurses/menu.py
Xlib/python1.5/site-packages/ncurses/panel.py
Xlib/python1.5/site-packages/ncurses/__init__.pyc
Xlib/python1.5/site-packages/ncurses/curses.pyc
Xlib/python1.5/site-packages/ncurses/form.pyc
Xlib/python1.5/site-packages/ncurses/menu.pyc
Xlib/python1.5/site-packages/ncurses/panel.pyc
Xlib/python1.5/site-packages/ncurses/_curses.so
Xlib/python1.5/site-packages/ncurses/_panel.so
Xlib/python1.5/site-packages/ncurses/_menu.so
Xlib/python1.5/site-packages/ncurses/_form.so
X@dirrm lib/python1.5/site-packages/ncurses
END-of-python/pyncurses/pkg/PLIST
echo c - python/pyncurses/files
mkdir -p python/pyncurses/files > /dev/null 2>&1
echo x - python/pyncurses/files/md5
sed 's/^X//' >python/pyncurses/files/md5 << 'END-of-python/pyncurses/files/md5'
XMD5 (pyncurses-0.3.tar.gz) = f29dc9704afd9a27ff21c6ad076e2eaa
END-of-python/pyncurses/files/md5
echo c - python/pyncurses/patches
mkdir -p python/pyncurses/patches > /dev/null 2>&1
echo x - python/pyncurses/patches/patch-aa
sed 's/^X//' >python/pyncurses/patches/patch-aa << 'END-of-python/pyncurses/patches/patch-aa'
X--- ncurses/_curses.i	Fri Mar 31 10:38:12 2000
X+++ /home/adsharma/pyncurses-0.3/ncurses/_curses.i	Tue May 16 22:06:25 2000
X@@ -284,7 +284,7 @@
X extern bool isendwin(void);
X extern bool is_linetouched(WINDOW *,int);
X extern bool is_wintouched(WINDOW *);
X-extern const char *keyname(int);
X+extern char *keyname(int);
X extern int keypad(WINDOW *,bool);
X extern char killchar(void);
X extern int leaveok(WINDOW *,bool);
X@@ -295,7 +295,7 @@
X extern int mvwin(WINDOW *,int,int);
X extern int napms(int);
X extern WINDOW *newpad(int,int);
X-extern SCREEN *newterm(const char *,FILE *,FILE *);
X+extern SCREEN *newterm(char *,FILE *,FILE *);
X extern WINDOW *newwin(int,int,int,int);
X extern int nl(void);
X extern int nocbreak(void);
X@@ -345,15 +345,15 @@
X extern int syncok(WINDOW *, bool);
X extern chtype termattrs(void);
X extern char *termname(void);
X-extern int tigetflag(const char *);
X-extern int tigetnum(const char *);
X-extern char *tigetstr(const char *);
X+extern int tigetflag(char *);
X+extern int tigetnum(char *);
X+extern char *tigetstr(char *);
X extern int typeahead(int);
X extern int ungetch(int);
X extern void use_env(bool);
X extern int vidattr(chtype);
X-extern int vwprintw(WINDOW *, const char *,va_list);
X-extern int vwscanw(WINDOW *, const char *,va_list);
X+extern int vwprintw(WINDOW *, char *,va_list);
X+extern int vwscanw(WINDOW *, char *,va_list);
X extern int waddch(WINDOW *, const chtype);
X extern int waddchnstr(WINDOW *,const chtype *,int);
X extern int waddnstr(WINDOW *,const char *,int);
X--- ncurses/_panel.i	Sat Apr 22 01:44:20 2000
X+++ /home/adsharma/pyncurses-0.3/ncurses/_panel.i	Tue May 16 22:07:56 2000
X@@ -35,8 +35,8 @@
X extern  PANEL*  new_panel(WINDOW *);
X extern  PANEL*  panel_above(const PANEL *);
X extern  PANEL*  panel_below(const PANEL *);
X-extern  int     set_panel_userptr(PANEL *, const void *);
X-extern  const void* panel_userptr(const PANEL *);
X+extern  int     set_panel_userptr(PANEL *, void *);
X+extern  void* panel_userptr(const PANEL *);
X extern  int     move_panel(PANEL *, int, int);
X extern  int     replace_panel(PANEL *,WINDOW *);
X extern	int     panel_hidden(const PANEL *);
END-of-python/pyncurses/patches/patch-aa
exit


>Release-Note:
>Audit-Trail:
>Unformatted:


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-ports" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200005180112.SAA68944>