Skip to content

 

start:

java GNV section

Updated 2021-03-20, by Martin Borgman


 How to enable Java in GNV

This was tested on a zx6000 with:
----------------------------------- ----------- ------------
PRODUCT                             KIT TYPE    STATE
----------------------------------- ----------- ------------
HP I64VMS AVAIL_MAN_BASE V8.2-1     Full LP     Installed
HP I64VMS C V7.1-11                 Full LP     Installed
HP I64VMS CDSA V2.1-355             Full LP     Installed
HP I64VMS CSWS V2.1                 Full LP     Installed
HP I64VMS CSWS_JAVA V3.0            Full LP     Installed
HP I64VMS CSWS_PERL V2.1            Full LP     Installed
HP I64VMS CSWS_PHP V1.3             Full LP     Installed
HP I64VMS CXX V7.1-11               Full LP     Installed
HP I64VMS DWMOTIF V1.5              Full LP     Installed
HP I64VMS GNV V1.6-4                Full LP     Installed
HP I64VMS JAVA142 V1.4-22           Full LP     Installed
HP I64VMS KERBEROS V2.1-75          Full LP     Installed
HP I64VMS OPENVMS V8.2-1            Platform    Installed
HP I64VMS PERL V5.8-6               Full LP     Installed
HP I64VMS TCPIP V5.5-11             Full LP     Installed
HP I64VMS TDC_RT V2.1-78            Full LP     Installed
HP I64VMS VMS V8.2-1                Oper System Installed
JFP I64VMS LIBBZ2 V1.0-2            Full LP     Installed
JFP I64VMS MYSQL V4.1-14            Full LP     Installed
JFP I64VMS PYTHON235 V1.46-0        Full LP     Installed
JFP I64VMS ZLIB V1.2-3              Full LP     Installed
----------------------------------- ----------- ------------

Note1:
I'm using a HP internal version of bash, but I don't think that matters in this
case.


Prerequisites are:
GNV 1.6-2 or better
Java 1.4.2 SDK or better
Alpha or IA64 system
ODS-5 disk with hard links enabled
extended parse style enabled
case blind

What to do:

   1. create a file SYS$LOGIN:JAVA$CONFIG_SETUP.COM with the following content:

$! JAVA$CONFIG_SETUP.COM
$!
$! --NOTE:
$! --       THIS FILE WAS ORIGINALLY GENERATED BY
$! --       SYS$COMMON:[JAVA$142.COM]JAVA$CONFIG_WIZARD.COM;1
$! --       ON  7-JAN-2006 21:11:11.40
$! --       IT MAY HAVE BEEN MANUALLY EDITTED SINCE THEN.
$! --
$! --       For more complete description of the logicals shown,
$! --       please read the release notes.
$!
$! The following are useful in all environments.
$!
$ SET PROCESS/PARSE_STYLE=EXTENDED
$ DEFINE/JOB DECC$ARGV_PARSE_STYLE TRUE
$ DEFINE/JOB DECC$EFS_CASE_PRESERVE TRUE
$ DEFINE/JOB JAVA$DAEMONIZE_MAIN_THREAD TRUE
$ DEFINE/JOB JAVA$DISABLE_CMDFILE_WHITESPACE_PARSING TRUE
$ DEFINE/JOB DECC$ENABLE_GETENV_CACHE TRUE
$!
$! Omitting logicals useful in debugging environment.
$!
$! Logicals useful for mimicing UNIX-like environments:
$!
$ DEFINE/JOB JAVA$CREATE_DIR_WITH_OWNER_DELETE TRUE ! make mkdir & rmdir symmetric --
$!  no need to change dir. protection before delete
$ DEFINE/JOB JAVA$DELETE_ALL_VERSIONS TRUE ! delete all copies of file on delete operation
$ DEFINE/JOB JAVA$RENAME_ALL_VERSIONS TRUE ! rename all copies of file on rename operation
$ DEFINE/JOB DECC$POSIX_SEEK_STREAM_FILE TRUE ! make seek() beyond EOF not extend file if no write happened
$!
$! Logicals useful for applications with many children:
$!
$ DEFINE/JOB JAVA$FORK_PIPE_STYLE 2 ! use buffered Mailbox devices and TCP/IP devices for interprocess communication
$ DEFINE/JOB JAVA$FORK_SUPPORT_CHDIR TRUE ! simulate chdir behavior on runtime.exec()
$ DEFINE/JOB JAVA$FORK_MAILBOX_MESSAGES 8  ! default -- increase for better buffering
$ DEFINE/JOB JAVA$WAIT_FOR_CHILDREN 5 ! seconds to delay exiting main to allow children to exit first
$!
$! Logicals useful for supporting file sharing:
$!
$ DEFINE/JOB DECC$FILE_SHARING TRUE  ! ask for C-RTL support for file sharing
$!
$! Omitting logicals useful for bypassing secondary stat() call.
$!
$! Logicals useful to set up caching of file/directory information
$!
$ DEFINE/JOB JAVA$CACHING_INTERVAL 60  ! to disable, undefine logical or set value to 0
$ DEFINE/JOB JAVA$CACHING_DIRECTORY TRUE ! enable special case -- don't look in directory if directory known to be absent
$!
$! Logicals useful for supporting ODS-5 operation only.
$!
$! NOTE:
$! The value of JAVA$FILENAME_CONTROLS generated below is different than the one set in JAVA$142_SETUP.COM
$! To make this new value be in effect, be sure to run JAVA$CONFIG_SETUP.COM after you run JAVA$142_SETUP.COM.
$ DEFINE/JOB DECC$EFS_CHARSET  TRUE  !
$ DEFINE/JOB DECC$EFS_CASE_SPECIAL  TRUE  !
$ DEFINE/JOB JAVA$FILENAME_CONTROLS 8 ! only enable the mixed UNIX/VMS filespec mapping
$ DEFINE/JOB JAVA$READDIR_CASE_DISABLE TRUE ! turns off auto. class/source case-sensitive name extraction
$!
$! See: SYS$COMMON:[JAVA$142.COM]JAVA$FILENAME_CONTROLS.COM for explanation of bits enabled above.
$!
$! Logicals useful for workstations with PC-style keyboard:
$!
$ DEFINE/JOB JAVA$KEYBOARD_TYPE_DEC TRUE ! make PC-style keyboard transmit keycodes like DEC-style keyboard
$!

   2. run SYS$STARTUP:JAVA$142_SETUP.COM (on Alpha with parameter FAST, on
      Itanium with parameter HOTSPOT)
      Note: you way want to add this to your LOGIN.COM
   3. run SYS$LOGIN:JAVA$CONFIG_SETUP.COM
      Note1: you way want to add this to your LOGIN.COM
      Note2: you must add this after @SYS$STARTUP:JAVA$142_SETUP.COM
   4. Create the necessary links in /usr/local/bin

$CREATE/DIRECTORY GNU:[usr.local.bin]
$SET FILE /ENTER=GNU:[usr.local.bin]appletviewer. SYS$COMMON:[JAVA$142.BIN]JAVA$APPLETVIEWER.EXE
$SET FILE /ENTER=GNU:[usr.local.bin]extcheck. SYS$COMMON:[JAVA$142.BIN]JAVA$EXTCHECK.EXE
$SET FILE /ENTER=GNU:[usr.local.bin]idlj. SYS$COMMON:[JAVA$142.BIN]JAVA$IDLJ.EXE
$SET FILE /ENTER=GNU:[usr.local.bin]jar. SYS$COMMON:[JAVA$142.BIN]JAVA$JAR.EXE
$SET FILE /ENTER=GNU:[usr.local.bin]jarsigner. SYS$COMMON:[JAVA$142.BIN]JAVA$JARSIGNER.EXE
$SET FILE /ENTER=GNU:[usr.local.bin]java. SYS$COMMON:[JAVA$142.BIN]JAVA$JAVA.EXE
$SET FILE /ENTER=GNU:[usr.local.bin]javac. SYS$COMMON:[JAVA$142.BIN]JAVA$JAVAC.EXE
$SET FILE /ENTER=GNU:[usr.local.bin]javadoc. SYS$COMMON:[JAVA$142.BIN]JAVA$JAVADOC.EXE
$SET FILE /ENTER=GNU:[usr.local.bin]javah. SYS$COMMON:[JAVA$142.BIN]JAVA$JAVAH.EXE
$SET FILE /ENTER=GNU:[usr.local.bin]javap. SYS$COMMON:[JAVA$142.BIN]JAVA$JAVAP.EXE
$SET FILE /ENTER=GNU:[usr.local.bin]jdb. SYS$COMMON:[JAVA$142.BIN]JAVA$JDB.EXE
$SET FILE /ENTER=GNU:[usr.local.bin]keytool. SYS$COMMON:[JAVA$142.BIN]JAVA$KEYTOOL.EXE
$SET FILE /ENTER=GNU:[usr.local.bin]native2ascii. SYS$COMMON:[JAVA$142.BIN]JAVA$NATIVE2ASCII.EXE
$SET FILE /ENTER=GNU:[usr.local.bin]ordb. SYS$COMMON:[JAVA$142.BIN]JAVA$ORDB.EXE
$SET FILE /ENTER=GNU:[usr.local.bin]orbd. SYS$COMMON:[JAVA$142.BIN]JAVA$ORBD.EXE
$SET FILE /ENTER=GNU:[usr.local.bin]policytool. SYS$COMMON:[JAVA$142.BIN]JAVA$POLICYTOOL.EXE
$SET FILE /ENTER=GNU:[usr.local.bin]rmic. SYS$COMMON:[JAVA$142.BIN]JAVA$RMIC.EXE
$SET FILE /ENTER=GNU:[usr.local.bin]rmid. SYS$COMMON:[JAVA$142.BIN]JAVA$RMID.EXE
$SET FILE /ENTER=GNU:[usr.local.bin]rmiregistry. SYS$COMMON:[JAVA$142.BIN]JAVA$RMIREGISTRY.EXE
$SET FILE /ENTER=GNU:[usr.local.bin]serialver. SYS$COMMON:[JAVA$142.BIN]JAVA$SERIALVER.EXE
$SET FILE /ENTER=GNU:[usr.local.bin]servertool. SYS$COMMON:[JAVA$142.BIN]JAVA$SERVERTOOL.EXE
$SET FILE /ENTER=GNU:[usr.local.bin]tnameserv. SYS$COMMON:[JAVA$142.BIN]JAVA$TNAMESERV.EXE
$SET FILE /ENTER=GNU:[usr.local.bin]kinit. SYS$COMMON:[JAVA$142.BIN]JAVA$KINIT.EXE
$SET FILE /ENTER=GNU:[usr.local.bin]klist. SYS$COMMON:[JAVA$142.BIN]JAVA$KLIST.EXE
$SET FILE /ENTER=GNU:[usr.local.bin]ktab. SYS$COMMON:[JAVA$142.BIN]JAVA$KTAB.EXE
$SET FILE /ENTER=GNU:[usr.local]java142.DIR SYS$COMMON:[000000]JAVA$142.DIR

   5. Make sure /usr/local/bin is in your PATH
   6. Set the JAVA_HOME environment variable in bash to /usr/local/java142:
      export JAVA_HOME=/usr/local/java142
      Note you may want to add this to you .bashrc

Now you can add Apache Ant to your bash environment.

   1. Download the Apache Ant 1.6.5 binary distribution from the apache web
      site http://ant.apache.org/
   2. Start bash
   3. cd 
   4. gunzip apache-ant-1.6.5-bin.tar.gz or bunzip2 apache-ant-1.6.5-bin.tar.bz2
   5. cd /usr/local
   6. gnutar xf /apache-ant-1.6.5-bin.tar
   7. Add the following to your environment:
      export ANT_HOME=/usr/local/apache-ant-1.6.5
      export PATH=$ANT_HOME/bin:$PATH
      Note: you want to add these lines to your .bashrc

And now you can use java and ant from within bash.

Regards,

Martin Borgman,
OpenOffice.org On OpenVMS porting group


Maintained by the OpenOffice on OpenVMS porting Project.