Subject: | |
From: | |
Reply To: | |
Date: | Thu, 20 Apr 2000 10:58:03 -0700 |
Content-Type: | text/plain |
Parts/Attachments: |
|
|
Jason Pilgrim wrote:
> I am attempting to write a C++ program that will call a procedure from a NM XL file.
> The purpose of this is to create a pipe that will allow data to be passed from the
> procedure to the C++ program and vice-versa. I am using the GCC compiler on MPE/iX
> version 6.0.
>
> If anyone has any idea how to call an individual procedure from a NM XL file, their
> help would be greatly appreciated.
The simple way is to declare the procedure just like any other external
procedure, and then at program load time the procedure will be resolved to one
of the NMXLs that you either linked with at :LINKEDIT time, or specified at
:RUN time.
The somewhat more involved way is to use the HPGETPROCPLABEL intrinsic, which
is described at:
http://docs.hp.com:80/dynaweb/smpe/b1019/556/@Generic__BookTextView/42820
HPGETPROCPLABEL has some extra enhancements that are still not listed in the
above 6.5 Intrinsics manual, though they should be included in the next release
of the manual. Those enhancements are described at:
http://docs.hp.com/mpeix/communicator/ix55/ct31900d.html#tag7
When you say "pipe", do you mean a true POSIX pipe, as in the pipe() function
or the "|" shell operator? If so, doing this involves pipe(), fork(), and
optionally dup2().
- Mark B.
|
|
|