1836462 Members
2029 Online
110101 Solutions
New Discussion

Re: compile question

 
Jeffrey F. Goldsmith
Super Advisor

compile question

I have a user that is trying to compile some programs on my rp3440-4 server. The OS is HP-UX 11.i23. Here is the programers notes and the error that she received during the last compile.

It looks like I am still missing some pieces to do the compiles. The commands/scripts compile and cob are missing. I can only cob has something to do with the cobol compiler.



[gravina] source$ compile gl995.cbl

+ compile gl995.cbl

sh: compile: not found.

[gravina] source$





[gravina] /apps/testifas/xport/src/sl$ make sy800.o

+ make -k sy800.o

echo Making sy800.o, will copy to /tmp

Making sy800.o, will copy to /tmp

cp sy800.cbl /tmp

(cd /tmp; cob -cx -Oe "" -X ANIM -X COBCOMMS -X RTSCALL -C sign=ebcdic s

y800.cbl 2> /apps/testifas/xport/src/sl/sy800.err)

*** Error exit code 127 (ignored)

rm -f /tmp/sy800.cbl

rm -f /tmp/sy800.idy

rm -f /tmp/sy800.int

[ -s sy800.err ] && exit 1 || rm sy800.err

*** Error exit code 1

[gravina] /apps/testifas/xport/src/sl$ more sy800.err

+ more sy800.err

sh: cob: not found.


Thanks for any and all help.

Jeff
4 REPLIES 4
James R. Ferguson
Acclaimed Contributor

Re: compile question

Hi Jeff:

Did you install the Cobol compiler? Does your PATH properly reflect its location? If the compiler is installed and the PATH has been updated, have you logged-out and back in to fetch the updated PATH into your environment?

Regards!

...JRF...
A. Clay Stephenson
Acclaimed Contributor

Re: compile question

Both of these point to the same problem. "compile" (whatever that is) and "cob" (MicroFocus COBOL Compiler?) are either non-existant or more-likely not in $PATH.

I would first do a swlist to see if a COBOL compiler is actually installed. Typically not only does cob (/opt/cobol/bin/cob) have to be in $PATH but also a COBDIR (e.g. /opt/cobol/cobdir) COBOL base directory environment variable needs to be set.
If it ain't broke, I can fix that.
Jeffrey F. Goldsmith
Super Advisor

Re: compile question

I did a swlist and found that the Micro Focus COBOL compiler isnâ t listed. I did an install of the software from their instructions a couple of weeks ago. Should I have done an SWINSTALL instead?

I found some of the COBOL software located at /opt/bin/cobol.
A. Clay Stephenson
Acclaimed Contributor

Re: compile question

The last time I installed a MF COBOL compiler (~5 years ago), it used swinstall but if you followed the instructions then you should be ok. (Did I mention that of all languages - with the possible exception of RPG [which is imcomprehensible to me]) - I hate COBOL the most?) In any event there were probably a few other instructions about setting up the environment that you missed or failed to add to the .profile of this user.

Almost certainly, you will need COBDIR defined and cob in the PATH.
If it ain't broke, I can fix that.