On 2016-01-20 15:28, Farley, Peter x23353 wrote: > Doesn't z/OS Unix have the equivalent of /etc/profile? > It has.
> And doesn't Java installation create an entry or invoked script in > /etc/profile >to set the JAVAHOME environment variable > it doesn't > as every other *ix system does? > I don't see that in a couple other *ix systems. But those keep java ,or at least a symlink in a stable path. Presumably updating java updates the symlink. > Shouldn't that be the preferred method for compatibility with every other *ix > Java environment? > IBM has a strict policy of not updating anything in /etc lest they override a user mod. > Just asking . . . > More: user@OS/390.25.00: grep java /etc/* 2>/dev/null /etc/csh.cshrc:set path = ( /bin /usr/lpp/java/J6.0.1/bin /usr/bin /usr/sbin .) /etc/profile:PATH=/bin:/usr/lpp/java/J6.0.1/bin:/usr/lpp/sasc/bin:/usr/bin:/usr/sbin:. user@OS/390.25.00: ls -ald /usr/lpp/java/* drwxr-xr-x 11 OMVSKERN OMVS 8192 Jul 8 2015 /usr/lpp/java/J6.0.1_64 drwxr-xr-x 11 OMVSKERN OMVS 8192 Jul 8 2015 /usr/lpp/java/J6.0_64 drwxr-xr-x 12 OMVSKERN OMVS 8192 Jul 8 2015 /usr/lpp/java/J7.1_64 drwxr-xr-x 12 OMVSKERN OMVS 8192 Jul 16 2015 /usr/lpp/java/J8.0_64 user@OS/390.25.00: ... no match for z/OS 2.2. user@OS/390.25.00: ls -al /etc/csh.cshrc /etc/profile -rw-r--r-- 1 OMVSKERN OMVS 2208 Apr 22 2013 /etc/csh.cshrc -rwxr-xr-x 1 OMVSKERN OMVS 10315 Apr 19 2013 /etc/profile user@OS/390.25.00: ... of course. So, I might try: user@OS/390.25.00: cat `whence findjava` /* Rexx */ signal on novalue; /* Find newest Java library: */ trace R JavaCmd = 'set -x; ls -1dt /usr/lpp/java/J*/bin |' , ' sed -n ''1 s/\/bin$//p''' RC = BPXWUNIX( JavaCmd, , 'OUT.' ) say value( 'OUT.1' ) user@OS/390.25.00: findjava 6 *-* JavaCmd = 'set -x; ls -1dt /usr/lpp/java/J*/bin |' ,'?sed -n ''1 s/\/bin$//p''' >>> "set -x; ls -1dt /usr/lpp/java/J*/bin | ?sed -n '1 s/\/bin$//p'" 8 *-* RC = BPXWUNIX( JavaCmd, , 'OUT.' ) sh:0+ ls -1dt /usr/lpp/java/J6.0.1_64/bin /usr/lpp/java/J6.0_64/bin /usr/lpp/java/J7.1_64/bin /usr/lpp/java/J8.0_64/bin sh:0+ sed -n 1 s/\/bin$//p >>> "0" 10 *-* say value( 'OUT.1' ) >>> "/usr/lpp/java/J8.0_64" /usr/lpp/java/J8.0_64 user@OS/390.25.00: Grrr..., gil ---------------------------------------------------------------------- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN