To build a VR-Link application, you must tell the compiler where to find the VR-Link header files (and for HLA, the RTI header files).
In addition, you must link with VR-Link's libraries (and for HLA, the RTI's libraries). If you are not using a C++ linker to link, you must explicitly link with C++ system libraries such as libC.so.
VR-Link consists of four libraries: mtl, vl, matrix, vlpi, and vlutil. The following versions of the vl library are provided:
| Versions of the vl Library | ||
|---|---|---|
| Simulation standard | UNIX | Windows |
| HLA | libvlHLA13.so, libvlHLA1516.so, libvlHLA1516e.so | vlHLA13.lib, vlHLA1516.lib, vlHLA1516e.lib |
| DIS | libvlDIS.so | vlDIS.lib |
On Windows:
Microsoft Visual C++ 8 Express Edition links against a different set of default libraries than Microsoft Visual Studio 2005 Professional does. Therefore, you might experience linking problems if you use Express Edition. If you have linking problems, add the following libraries to your link line:
VR-Link uses the third-party libraries libXml2, boost, and iconv. If you are building a VR-Link application, you must include them on your link line. The libXml2 library is part of the Red Hat Linux distribution. It is distributed with VR-Link for all other operating systems. For details about boost, please go to http://www.boost.org.
To build a VR-Link application for Linux using MAK's build system, you must use gmake 3.81 or later. You can download it from http://savannah.gnu.org/projects/make/
You can select DIS or HLA at compile time by using the flags described in the following sections. vlhome represents your VR-Link home directory.
After you install VR-Link, create a symbolic link called RTI in the top level VR-Link directory. Point the link to the RTI distribution that you are using.
-I{VLHOME}/include (VR-Link headers)
-I{VLHOME}/RTI/include (path to MAK RTI include directory)
-DDtHLA=1 for conditional compilation)
-DDtHLA_1516=1 Use only if compiling for IEEE 1516 - 2000.
-DDtHLA_1516_EVOLVED=1 Use only if compiling for IEEE 1516 - 2010 (HLA Evolved).
The compile and link flags for DIS are:
-Ivlhome/include (VR-Link headers)
-DDtDIS=1 (for conditional compilation)
Under Windows, you can set your program's protocol following the procedures in this section. You need to provide build settings in Microsoft Developer Studio to define constants and specify paths for header files and RTI libraries.
VR-Link includes project files for DIS and the three HLA versions. If you are building for HLA, make sure to point to the correct location of the RTI include and library directories. The default is to use the value in the MAK_RTIDIR environment variable.
Enter the following #define symbols in the space provided for preprocessor definitions:
In the C/C++ -> General section, in the space provided for additional include libraries, enter your VR-Link include path and the path to your RTI include directory, for example:
or:
In the Linker -> Input section, in the space provided for additional dependencies, enter the appropriate RTI, VR-Link and Visual C++ library files, for example:
Also, make sure you list the appropriate paths to these files in the "Additional Library Directories" box in the Linker -> General section, for example:
In the C/C++ -> General section, in the space provided for additional include libraries, enter your VR-Link include path, for example:
In the Linker -> Input section, enter the appropriate VR-Link and Visual C++ library files, for example:
Also, make sure you list the appropriate paths to these files in the "Additional Library Directories" box in the Linker -> General section, for example:
[Home] [Top of Page] [Using VR-Link from C >>]