I created modules.
I created a binding directory.
I bound them together into a service program. CRTSRVPGM
SRVPGM(V64BPCSUSR/SRVINV) MODULE(V64BPCSUSR/SRVINV)
BNDDIR(V64BPCSUSR/SRVINV)
I have a binder language source
I have this as the header in my ILE program:
H BNDDIR('SRVINV')
H Option(*srcstmt : *nodebugio)
/If Defined(*CRTBNDRPG)
H DftActGrp(*NO) ActGrp('qiqe')
/EndIf
I compile using option 14(Compile)
The Binding Directory is convenient - but not essential - to the "build
process". However, the Binder (source) Language, (however you choose to
use it) is encouraged.
I suggest the the flow should be:
1). Code modules as normal in source files, (QRPGLESRC, QCLSRC, etc.)
2). Compile module source to create *MODULE objects using CRTxxxMOD
command(s)
3). Code Binder Language (usually in QSRVSRC)
4). Bind required *MODULE objects into Service program (*SRVPGM) referiing
to Binder Language in QSRVSRC on the CRTSRVPGM.
5). Bind required *MODULES and *SRVPGM objects into final Program (*PGM)
using CRTPGM
IF you wish to use Binding Directories (*BNDDIR) to streamline (4) and
(5), reference on CRTSRVPGM and/or CRTPGM commands. For RPG IV only, you
can specify the *BNDDIR in the H-spec using the BNDDIR keyword. No such
facility for CL.
NOTE: I suggest CRTBNDxxx commands (PDM Option 14.) be reserved for
non-ILE compile/bind.
When adding new procedures, (to an existing or new *MODULE) for external
use you should amend the list of Procedure Exports. Add new procedure
names (Exports) to the END of the Exports Symbols listed in the Binder
Language.
The archives contain a wealth of information - this subject has been
discussed in the past..
Brian Parkins
Unless stated otherwise above:
IBM United Kingdom Limited - Registered in England and Wales with number
741598.
Registered office: PO Box 41, North Harbour, Portsmouth, Hampshire PO6 3AU
As an Amazon Associate we earn from qualifying purchases.