DOS, Socket support?

Gerhard Häring gh_pythonlist at gmx.de
Tue Dec 4 20:44:39 CET 2001


On Tue, Dec 04, 2001 at 10:47:37AM -0800, Brian Geddes wrote:
> All -
> 
> I'm searching for a version of Python (1.5.2 or newer, preferably) compiled
> for DOS, that has includes support for TCP/IP sockets (socket.py).  After a
> bit of searching on the web I'm almost convinced that such a version does
> not exist, but I thought I'd check here before I gave up my search, as
> you've all been quite helpful in the past.  :)

I've also never heard of such a best.

> I have found Python 1.5.2 compiled for DOS, but it was the executable only.
> I don't know the internals of socketmodule.c, but does anyone have an idea
> how difficult it would be to modify and recompile it for DOS?

This would be a serious effort, but it is certainly feasible. I don't
have experience as a project manager, so I'm not very qualified for
this, but I'd estimate it would last approx. 6-8 weeks. The toughest
part would be to get a reasonable development environment for DOS up and
running (finding/buying those old compilers), getting Python itself to
compile in it, ...

So it would probably be best to find a programmer who has experience
with DOS programming and already has a development environment set up.

The actual implementation of socketmodule for DOS would hopefully be not
the problem. According to http://www.alumni.caltech.edu/~dank/trumpet/
there are C headers that wrap the Trumpet ABI. This API is almost
certainly a completely different beast than Unix sockets or Winsock, so
the programmer would probably have to #ifdef like hell in the
socketmodule.c file.

Perhaps the following could also work: run the DOS app under Windows 9x
and let a Windows process do the TCP/IP stuff?

Gerhard
-- 
mail:   gerhard <at> bigfoot <dot> de       registered Linux user #64239
web:    http://www.cs.fhm.edu/~ifw00065/    OpenPGP public key id 86AB43C0
public key fingerprint: DEC1 1D02 5743 1159 CD20  A4B6 7B22 6575 86AB 43C0
reduce(lambda x,y:x+y,map(lambda x:chr(ord(x)^42),tuple('zS^BED\nX_FOY\x0b')))




More information about the Python-list mailing list