?
Solved

Compile RGP program to a different library

Posted on 2010-11-11
4
Medium Priority
?
602 Views
Last Modified: 2012-05-10
Copied an RPG program to a different member/library (QRPGSRC/DLLSRC37). Now i want to compile that member to DLLOBJ37 (library for compiled object storage). Using STRPDM, I enter 14 in front of the member and press F4. Screen appears with the following. How can I tell the system to compile to DLLOBJ37 instead of DLLSRC37?
Program... APCKTFR
 Library..... DLLSRC37
Source.....  QRPGSRC
  Library....  DLLSRC37
Source Member.. APCKTFR
Generation Sec Level.. 9
Replace Program.. NO
F10 Additional Parameters
  Source listing options
  Generation options
  Source Listing indentation
0
Comment
Question by:rodneygray
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
4 Comments
 
LVL 2

Expert Comment

by:dcgrindle
ID: 34116941
Program... APCKTFR
 Library..... DLLOBJ37
Source.....  QRPGSRC
  Library....  DLLSRC37

The library name under the Program name tells the compiler where to place the object.  

Note:  You have to be sure all the objects the program references exist in your library list when you compile the program.
0
 
LVL 5

Expert Comment

by:stevebowdoin
ID: 34117677
You can do the 14/F4 each time you compile or...
F18 then key the target lib.
That is where all 14s will go.

Steve Bowdoin
0
 
LVL 14

Expert Comment

by:daveslater
ID: 34256950
Hi
what I do is in PDM is:
F18 -  change detauts

set the
Object library . . . . . . .   *CURLIB      

then in F16 (Work with User-Defined Options) i have and option CL  chgcurlib &l    

I simply use CL F4 and put the object library in the library name
then option 14 always compiles into the current library.


Dave
0
 
LVL 16

Accepted Solution

by:
theo kouwenhoven earned 2000 total points
ID: 34367326
The problem of using F18 to set the library is, that if you forget to reset it to the default, all programs in the future will be stored there.

What you also can do is create your own compile option like e.g.  MC (My Compiler)  instead of option 14.
To do so, go to PDM and press F16 (Shift+F4), brows through the optiins to see if MC is not used already.

Press F6 to create a new function:
Type after Option:  MC   (or any other code you like to use)
Type as command :
CRTBNDRPG PGM(DLLOBJ37/&N) SRCFILE(&L/&F) AUT(*ALL)

Now if you put the new created option in front of a source it will start the compiler.
You also able to prompt it by F4 so that you see the values.

For an automatig prompt after enter, just place a questionmark infront of the command while creating the option, so
CRTBNDRPG PGM(DLLOBJ37/&N) SRCFILE(&L/&F)
can be changed into
?CRTBNDRPG PGM(DLLOBJ37/&N) SRCFILE(&L/&F)

If you need otheroptions for the compiler, just enter them while creating this PDM-option.


Good luck
Murph

0

Featured Post

Efficient way to get backups off site to Azure

This user guide provides instructions on how to deploy and configure both a StoneFly Scale Out NAS Enterprise Cloud Drive virtual machine and Veeam Cloud Connect in the Microsoft Azure Cloud.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

An introduction to the wonderful sport of Scam Baiting.  Learn how to help fight scammers by beating them at their own game. This great pass time helps the world, while providing an endless source of entertainment. Enjoy!
Active Directory can easily get cluttered with unused service, user and computer accounts. In this article, I will show you the way I like to implement ADCleanup..
This tutorial will teach you the special effect of super speed similar to the fictional character Wally West aka "The Flash" After Shake : http://www.videocopilot.net/presets/after_shake/ All lightning effects with instructions : http://www.mediaf…
In this video, Percona Solution Engineer Dimitri Vanoverbeke discusses why you want to use at least three nodes in a database cluster. To discuss how Percona Consulting can help with your design and architecture needs for your database and infras…
Suggested Courses

777 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question