NonStop Server for Java 4.2 Programmer's Reference

Directories of Binary Files Moved
If your NonStop Server for Java programs have references to bin/oss/posix_threads in Pathway
configuration files or elsewhere, you must change them to use the NonStop Server for Java 4 installation
bin directory.
In previous versions of NonStop Server for Java, the bin and jre/bin directories contained a shell
script that ran the real executable that was located in bin/oss/posix_threads. In the
NonStop Server for Java 4 version, the bin directory contains the real executable, no shell script
wrapper, and no bin/oss/posix_threads directory. The jre/bin directory contains symbolic
links to the executables in the bin directory.
Compiling C++ Native Code with the
-Wversion3 Option
If the code is written in C++, user native code that is to be linked into the java executable must be
compiled using the -Wversion3 option. C++ has three C++ runtime libraries, one library for each
version: version 1, version 2, and version 3. These versions are incompatible with each other. Version 1
of the NonStop Server for Java 4 uses C++ version 2. Version 2 of the NonStop Server for Java 4 uses
C++ version 3 (version 3 makes C++ more standard than version 2).
If, however, you are migrating to TNS/E systems, see the discussion under Migrating Applications to
TNS/E Systems.
The VERSION3 directive specifies the use of the Standard C++ Library ISO/IEC version 3 and the C++
Standard headers. VERSION3 enforces the ISO/IEC IS 14882:1998 standard for C++. The ISO C++
standard is identical to the ANSI C++ standard.
Whether your native code needs source-code changes depends on whether the code uses C++ features
that have changed in version 3. To identify needed source-code changes, run a migration check on your
source code by invoking the version 2 compiler and using the pragma MIGRATION_CHECK. Running
this migration check causes the compiler to issue a warning when a class or member function is present
that has changed or become obsolete for version 3. See the C/C++ Programmers Guide for more
information about this pragma and the warnings it can produce.
For invocation API users, the switch to version 3 affects which shared run-time libraries (SRLs) are
specified in the link step to create the executable. See the invocation API demo provided by NonStop
Server for Java 4 in install_dir/demo/invocation_api for the correct SRL to link to.
For more information, see Linker and Compiler Options.