Python 0.9.9 runs on NeXT (black, 3.0, mouse-X)

George White 6-8509 (gwhite@trevnx.bio.dfo.ca)
Wed, 8 Sep 93 16:52:31 -0300

Like many people, I'm looking at tools to help my Internet grazing,
provide better documentation, etc.

It wasn't hard getting stdwin 0.9.8 and python 0.9.9 to run under NS
3.0. I used Mouse-X libraries (no Motif) but run X clients on an NCD
X-terminal rather than the Mouse-X server.

Compilation details:

I followed the suggestion to make a basic version of python in order
to use the interactive configuration. The hardest part was remembering
the "-m" flag to permit linking with the provided version of strtol.c
because the first attempt (using NeXT's strtol) didn't pass the "make test"
tests.

$ grep "^[^#]" Makefile
CFLAGS= $(THREAD_USE) $(ADDCFLAGS) $(X11_INCL)
ARCH= next
CC= cc
AR= ar
ADDCFLAGS=
WAITDEF= -DNO_WAITPID
LIBMATH= -lm
DESTDIR=/usr/local
BINDESTDIR=$(DESTDIR)/bin
BINDEST=$(BINDESTDIR)/python
MANDESTDIR=$(DESTDIR)/man/man1
MANDEST=$(MANDESTDIR)/python.1
LIBDESTDIR=$(DESTDIR)/lib
LIBDEST=$(LIBDESTDIR)/python
DOCDEST=$(LIBDEST)/doc
DEMODEST=$(LIBDEST)/demo
DEFPYTHONPATH= .:$(LIBDEST):$(LIBDEST)/$(ARCH)
STRERROR_SRC= strerror.c
STRERROR_OBJ= strerror.o
FMOD_SRC= fmod.c
FMOD_OBJ= fmod.o
STRTOL_SRC= strtol.c
STRTOL_OBJ= strtol.o
GETCWD_SRC= getcwd.c
GETCWD_OBJ= getcwd.o
SIGTYPEDEF= -DSIGTYPE=int
BSDTIMEDEF= -DBSD_TIME
TIMESDEF= -DDO_TIMES
RE_USE= -DUSE_REGEX
RE_SRC= regexpr.c regexmodule.c
RE_OBJ= regexpr.o regexmodule.o
LIBREADLINE= /usr/local/lib/libreadline.a
LIBTERMCAP= -ltermcap
RL_USE = -DUSE_READLINE
RL_LIBS= $(LIBREADLINE)
RL_LIBDEPS= $(LIBREADLINE)
ADDLIBS=-m # so that we can use strtol.c
STDWINDIR= ../../stdwin
LIBSTDWIN= $(STDWINDIR)/Build/$(ARCH)/x11/lib/lib.a
LIBX11 = -lX11
STDW_INCL= -I$(STDWINDIR)/H
STDW_USE= -DUSE_STDWIN
STDW_LIBS= $(LIBSTDWIN)
STDW_LIBDEPS= $(LIBSTDWIN)
STDW_SRC= stdwinmodule.c
STDW_OBJ= stdwinmodule.o
X11_USE= -DUSE_X11
X11_INCL=
X11_LIBDIRS=
XT_USE= -DUSE_XT
XT_LIBS= -lXmu -lXt -lX11 -lXext
XT_OBJ= Xtmodule.o Xttypes.o GCobject.o Fontobject.o \
widgetobject.o wclassobject.o
XT_SRC= Xtmodule.c Xttypes.c GCobject.c Fontobject.c \
widgetobject.c wclassobject.c
EDITRES_USE= -DUSE_EDITRES
XAW_USE= -DUSE_XAW
XAW_LIBS= -lXaw
XAW_OBJ= Xawmodule.o
XAW_SRC= Xawmodule.c
HTML_USE= -DUSE_HTML
HTML_OBJ= HTMLmodule.o
HTML_SRC= HTMLmodule.c
HTML_LIBS= /usr/local/lib/libhtmlw.a
X11_USE= $(XT_USE) $(XAW_USE) $(XM_USE) $(GLX_USE) $(HTML_USE)
X11_LIBS= $(X11_LIBDIRS) \
$(XAW_LIBS) $(XM_LIBS) $(GLX_LIBS) $(HTML_LIBS) $(XT_LIBS)
X11_OBJ= $(XT_OBJ) $(XAW_OBJ) $(XM_OBJ) $(GLX_OBJ) $(HTML_OBJ)
X11_SRC= $(XT_SRC) $(XAW_SRC) $(XM_SRC) $(GLX_SRC) $(HTML_SRC)
FCNTL_USE= -DUSE_FCNTL
FCNTL_SRC= fcntlmodule.c
FCNTL_OBJ= fcntlmodule.o
FCNTL_LIBS=
FCNTL_LIBDEPS=
DBM_USE= -DUSE_DBM
DBM_SRC= dbmmodule.c
DBM_OBJ= dbmmodule.o
DBM_LIBS=
DBM_LIBDEPS=
STROP_USE= -DUSE_STROP
STROP_SRC= stropmodule.c
STROP_OBJ= stropmodule.o
STROP_LIBS=
STROP_LIBDEPS=
IMAGEOP_USE= -DUSE_IMAGEOP
IMAGEOP_SRC= imageopmodule.c
IMAGEOP_OBJ= imageopmodule.o
IMAGEOP_LIBS=
IMAGEOP_LIBDEPS=
ARRAY_USE= -DUSE_ARRAY
ARRAY_SRC= arraymodule.c
ARRAY_OBJ= arraymodule.o
ARRAY_LIBS=
ARRAY_LIBDEPS=

A few hacks in posixmodule.c:

#ifdef NeXT
#define mode_t int
#define NO_UNAME
#define HZ 60
typedef int clock_t;
#endif /* NeXT */

So far I have used the www client, ibrowse, and texi2html as well
as a bit of interactive messing around with no serious unpleasantness.
Python certainly looks like something I will use. Thanks to
Guido Rossum and crew.

/George White <GWhite@BIOnet.BIO.DFO.ca> Bedford Inst. of Oceanography