Skip to main content

Building an Example Application on Unix for PL/I

  • January 23, 2015
  • 0 replies
  • 0 views

Problem: 

In the documentation, the link below incorrectly specifies the location of the OPEN-PLI files:
http://documentation.microfocus.com/help/topic/com.microfocus.eclipse.infocenter.enterpriseserver.unix/GUID-C115837C-8E4C-466A-A060-94B63E442660.html

Resolution:

At the top of the page, it says: " To illustrate better how the functionality works, you can use the sample application located in:  C:\\Program Files\\Micro Focus\\Studio Enterprise Edition 6.0\\Examples\\OPEN-PLI\\Dynamic Subroutines"  

The correct location for the PL/I Dynamic Subroutine applications is:
/home/products/ed22upd2/demo/Open-PLI/Dynamic Subroutines 
Note:  You may need to modify the above path, according to your actual installed location.

In addition, the "ld" commands on this page will need to be modified when referring to" dllmain.o, nojw.o, noofm.o and libmf.so, as shown below:

From:

ld -shared  --warn-unresolved-symbols -o A.so A.o B.so  -melf_i386  -rpath .  B.so $MFPLI_PRODUCT_DIR/lib/dllmain.o $MFPLI_PRODUCT_DIR/lib/nojw.o $MFPLI_PRODUCT_DIR/lib/noofm.o $MFPLI_PRODUCT_DIR/lib/libmf.so *.so $HOME/staff/opli/DMFTEST/debug/

To be this…

ld -shared  --warn-unresolved-symbols -o A.so A.o B.so  -melf_i386  -rpath .  B.so $MFPLI_PRODUCT_DIR/lib/32/dllmain.o $MFPLI_PRODUCT_DIR/lib/32/nojw.o $MFPLI_PRODUCT_DIR/lib/32/noofm.o $MFPLI_PRODUCT_DIR/lib/libmfpli.so *.so 
<NOTICE that the $HOME…paramter has been removed>

Summary of the above changes: 

1. The dllmain.o, nojw.o & noofm.o files are now in /lib/32/ vs. just /lib/

2. The module libmf.so, is now called, libmfpli.so

The other 2 "ld" commands on this page will need to be similarly modified.

Also, using "ldpli", instead of the above "ld" commands will also create an executable with the results shown below:

ldpli -o A.exe A.o B.o C.o

To execute A.exe, run:

 ./A.exe   (Note the "." before the "/")

Output:

BEGIN A BEGIN B BEGIN C END C Signal Error triggered in C, drives ON ERROR in B END B END A

 


#DynamicSubroutines
#ld
#PL1
#Open-PLI
#ldpli
#Enterprise
#PLI
#Server
#EnterpriseServer

0 replies

Be the first to reply!