Configuring and Managing MPE/iX Internet Services (July 2001)
180 Chapter9
Apache for MPE/iX
Major Components
a - /APACHE/PUB/hw/hw.o
1 OBJECT FILE HAS BEEN ADDED.
shell/iX> callci linkedit
HP Link Editor/iX (HP30315A.06.15) Copyright Hewlett-Packard Co 1986
LinkEd> buildxl xl=./mod_hw.so;limit=5
LinkEd> addxl from=./mod_hw.o;to=./mod_hw.so;merge;share;rl=./hw.a,/lib/libm.a,
/lib/libc.a
1 OBJECT FILE HAS BEEN ADDED.
Shared libraries
Shared libraries (XLs) can also be used for resolving external function
calls from a DSO. One method is to relink the Apache program with an
XL list of the required shared libraries and to copy each shared library
into MPE/iX namespace. Another method is to link a DSO using
dependent libraries the (altxl option to the LinkEditor) and to copy
each shared library into MPE/iX namespace. Either way, all shared
libraries must reside in an MPE/iX group and account and must follow
the MPE/iX naming conventions. This is necessary because Apache is a
Privileged Mode (PM) program.
Symbolic links from the MPE/iX namespace to a shared library in the
HFS namespace will not satisfy the PM capability constraint. Each
shared library must actually reside in MPE/iX namespace. The
following commands show how to copy the libm and libc system
shared libraries into MPE/iX namespace and how to use the altprog
option to LinkEditor to add these shared libraries to the Apache
program file:
:HELLO MGR.APACHE
:XEQ SH.HPBIN.SYS -L
shell/iX> cp /lib/libm.sl XLM
shell/iX> cp /lib/libc.sl XLC
shell/iX> callci linkedit
LinkEd> buildxl xl=./hw/mod_hw.so;limit=10
LinkEd> addxl from=./hw/mod_hw.o,./hw/hw.o;to=./hw/mod_hw.so;merge;share
LinkEd> altprog ./HTTPD;cap=ia,ba,ph,pm;xl=XLM,XLC
When using system libraries as XLs, such as libm.sl and libc.sl,
remember to recopy these libraries after a system update in order to get
their new versions. To verify that HTTPD has been successfully
relinked with your NMXL(s):
LinkEd> listprog ./HTTPD
PROGRAM : ./HTTPD
XL LIST : XLM XLC
CAPABILITIES : BA, IA, PM, PH