HP3000-L Archives

June 2001, Week 3

HP3000-L@RAVEN.UTC.EDU

Options: Use Monospaced Font
Show Text Part by Default
Show All Mail Headers

Message: [<< First] [< Prev] [Next >] [Last >>]
Topic: [<< First] [< Prev] [Next >] [Last >>]
Author: [<< First] [< Prev] [Next >] [Last >>]

Print Reply
Subject:
From:
Gavin Scott <[log in to unmask]>
Reply To:
Gavin Scott <[log in to unmask]>
Date:
Mon, 18 Jun 2001 13:13:32 -0700
Content-Type:
text/plain
Parts/Attachments:
text/plain (42 lines)
Lars writes:
> As Mark said, Posix apps won't be able to to open MSG files.
> The Posix API has no idea about such an MPE specific file type.

Specifically all the "Posix" language (HP C, GCC C/C++) runtimes use the
Unix style open() function to access files.  This maps onto an internal MPE
routine called _px_open() (located in XL.PUB.SYS) which does the actual
HPFOPEN call.

_px_open() specifies a very specific and rather restrictive set of HPFOPEN
options, including specifying Posix-only name interpretation, disabling file
equates, and requiring Byte Stream record structure or Byte Stream Emulation
among other things.  Obviously its goal is to return a file descriptor
that's attached to something that a Unix style language runtime library can
simply treat as a stream of bytes.

When this set of options is applied to a message file, the HPFOPEN fails
with:

   The read format option contained an illegal value. (FILE SYSTEM
ERROR -181)

which probably indicates that the byte stream emulator "doesn't do message
files" and gets reported to the calling program as an
"Implementation-defined error" (since there aren't enough errno values to
communicate more information).

So it's not "MPE files" that can't be accessed from "Posix programs" so much
as it's any file type that can't provide either native byte stream record
semantics or an emulation thereof.

Fixing this restriction would require either radical changes to the language
runtime code (which today probably assumes that all of the world consists
solely of byte stream files) or more likely teaching the byte stream
emulator type manager to read message files.  Of course you'd have to figure
out what semantics you wanted from the message file's point of view, too.

G.

* To join/leave the list, search archives, change list settings, *
* etc., please visit http://raven.utc.edu/archives/hp3000-l.html *

ATOM RSS1 RSS2