[FreeVMS] Re: Announcing the VNIX project


Subject: [FreeVMS] Re: Announcing the VNIX project
From: David Wijnants (dwijnants@askalix.com)
Date: Thu May 16 2002 - 09:32:25 CEST


> Harold L Hunt wrote:
> VNIX is a project to provide a library that is compatible with the VMS
> (http://www.openvms.compaq.com/) runtime libraries for use on POSIX systems.

I've been thinking about that myself; it should be possible to emulate
the behaviour of most of the RTL and system services in a library, and
have cooperating processes pretending to run in a VMS environment, so
long as they all play by the rules (and most UNIXes should be capable of
giving you at least some user/group/world protection).

The main difficulty I've got is in the way real OpenVMS (as presumeably
FreeVMS will) enforces the rules for you. For example, filenames passed
to fopen() go through logical name translations automatically, stdout
can be redirected to a mailbox without having to use sys$qiow(), logical
names are copied to subprocesses but processes cannot interfere with
each others logicals.

Most people probably have their favourite VMS features. The string
handling routines should be very straightforward, but I've never used
them myself; I've certainly never used Fortran (no offence intended).
Global sections should not be too difficult to fit onto mmap() shared
memory. Event flags could be emulated with mutexes and shared memory.
Locks could be done with fcntl() record locking or pthread_rwlock_*()
functions. My own favourite, mailboxes, should be possible with either
pipes, UNIX domain sockets or message queues (roll your own with shared
memory); or perhaps as a device driver (but that's a bit too scary...).

Most of the VMS commands (directory, copy, search, sort, ...) should not
take very long to write, given a VNIX library or FreeVMS kernel with the
necessary system services and RTL, and should in theory work fine on
both. Even DCL, as far as I can see, is just another shell but with some
rather cleverer command line parsing than your average UNIX shell.

Another idea I'm toying with is a DEC C frontend to gcc, so you can
compile the usual VMS-isms (command line switches, taking the address of
a numeric literal to pass by reference, #pragma dictionary, additional
(RMS) parameters to fopen, VMS file specifications, etc.).

Still haven't done anything about it, though...

Davygoat.

-- 
Liste de diffusion FreeVMS
Pour se désinscrire : mailto:freevms-request@ml.free.fr?subject=unsubscribe



This archive was generated by hypermail 2b25 : Thu May 16 2002 - 09:35:17 CEST