VR-Exchange 2.9 API Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
11 - Building and Compiling Brokers

Table of Contents

VR-Exchange includes solution and project files in the example directories of the Windows version and makefiles in the example directories for the Linux version.

Please examine these files for a full picture of the build process.

11.1 VR-Exchange Libraries

VR-Exchange has the following libraries:

11.2 Third Party Libraries

VR-Exchange brokers require third party libraries.

VR-Link - The non-HLA components use vl, vlutil, xml, and matrix. The libHlaBroker library uses vlHLA13 or vlHLA1516. The libDisBroker library uses vlDIS.

Note
Use of VR-Link is not covered by the VR-Exchange license; you must purchase a separate license to use it. Please see your MAK sales representative for details.

Boost. Boost header files are included with VR-Exchange. They are in include/boost.

If you want to rebuild GUI components of the Portal or the brokers supplied with VR-Exchange, you need Qt. Qt is available as a free download under the LGPL version 2.1 license at www.qtsoftware.com. This version should be satisfactory for most VR-Exchange customers. If you need a Qt commercial license, you must purchase the license from Qt Software.

You do not need Qt to build new brokers or build the Portal without its GUI. You can purchase a Qt license from Trolltech: www.qtsoftware.com. Please see VR-Exchange Release Notes for the required version of Qt.

TENA users must install TENA middleware and any libraries required by their LROM. HLA users must install an RTI. DDS users must install OpenSplice.

11.3 Building Brokers

There are no special pre-processor flags required to build a broker. VR-Exchange includes release and debug versions of Windows libraries. Debug versions use the naming convention library_named.lib. The table lists the libraries required to build brokers for Windows and Linux.

Libraries Required to Build Brokers
Windows Libraries Linux Libraries
vl{protocol}.lib libvl{protocol}
vl.lib libvl
vlutil.lib libvlutil
matrix.lib libmatrix
mtl.lib libmtl
lib{protocol}Broker.lib lib{protocol}Broker
libBroker.lib libBroker
libPortal.lib libPortal
libwidgets.lib libwidgets
QtCore4.lib libQtCore
QtGui4.lib libQtGui
libxml2.lib libxml2
libboost_date_time_{compiler}.lib libboost_date_time_{compiler}

On Windows, the simpleBroker example requires the library vl5.

11.3.1 Building Brokers for Linux

To build a broker on Linux, be sure that your VR-Exchange installation path does not contain spaces.

  1. Set environment variables, as follows:
    • Set MAK_VRLDIR to the location of your VR-Link installation.
    • Set QTDIR to the location of your Qt installation. (You must do this even if you are not building the GUI.)
    • If you are building the HLA Broker, set MAK_RTIDIR environment variable to your RTI install directory.
    • If you are building the DDS Broker, set OSPL_HOME to your OpenSplice install directory.
    • If you are building the TENA Broker, set MAK_TENADIR to your TENA install directory.
  2. cd to the directory of the broker you want to build, for example brokers/disBroker.
  3. Run make. For 64-bit Linux builds, run "make all64".

11.3.2 Building Brokers for Windows

  1. Set environment variables, as follows:
    • Set MAK_VRLDIR to the location of your VR-Link installation.
    • Set QTDIR to the location of your Qt installation. (You must do this even if you are not building the GUI.)
    • If you are building the HLA Broker, set MAK_RTIDIR environment variable to your RTI install directory.
    • If you are building the DDS Broker, set OSPL_HOME to your OpenSplice install directory.
    • If you are building the TENA Broker, set MAK_TENADIR to your TENA install directory.
  2. Open the solution file for the broker you want to build.
  3. Build the solution.

11.4 Rebuilding the HLA Broker

The table lists the libraries you need to rebuild the HLA broker.

Libraries Required to Build the HLA Broker
Windows Libraries Linux Libraries
vlHLA13.lib, vlHLA1516.lib, or vlHLA1516e.lib libvlHLA13, libvlHLA1516, or libvlHLA1516e
vl.lib libvl
vlutil.lib libvlutil
matrix.lib libmatrix
mtl.lib libmtl
libRprHla13Broker.lib, libRprHla1516Broker.lib, or libRprHla1516eBroker.lib libRprHla13Broker, libRprHla1516Broker, or libRprHla1516eBroker
libBroker.lib libBroker
libPortal.lib libPortal
libwidgets.lib libwidgets
QtCore4.lib libQtCore
QtGui4.lib libQtGui
libxml2.lib libxml2
libboost_date_time_{compiler}.lib libboost_date_time_{compiler}

To rebuild the HLA broker on Windows, you must have the following RTI libraries (included with your RTI):

For the HLA broker several VR-Link compiler flags are required. Please consult the VR-Link documentation for instructions about how to build a VR-Link HLA federate.

11.5 Rebuilding the DIS Broker

To build the DIS broker, you must specify several VR-Link compiler flags. Please consult the VR-Link documentation for instructions about how to build a VR-Link application for DIS.

Libraries Required to Build the DIS Broker
Windows Libraries Linux Libraries
vlDIS.lib libvlDIS
vl.lib libvl
vlutil.lib libvlutil
matrix.lib libmatrix
mtl.lib libmtl
libDisBroker.lib libDisBroker
libBroker.lib libBroker
libPortal.lib libPortal
libwidgets.lib libwidgets
QtCore4.lib libQtCore
QtGui4.lib libQtGui
libxml2.lib libxml2
libboost_date_time_{compiler}.lib libboost_date_time_{compiler}

11.6 Rebuilding the DDS Broker

The DDS broker needs to link against the VR-Link vlDIS library in order to use the DIS state repository to store entity and interaction attributes. No additional compiler flags are necessary for this, as the source automatically defines the necessary flags.

Note
The source for the vlOpenSplice library is part of the DDS broker, and this library is included in the DDS broker's solution. The vlOpenSplice library automatically builds and links into the DDS Broker when building. However, for Windows, you must make the following changes to include/include/os_stdlib.h in the OpenSplice install.

Comment out the following lines:

OS_API extern char *optarg;
OS_API extern int optind, opterr;
OS_API int getopt( int argc, char **argv, const char* options );

The commented lines should look like this:

// MAK FIX: getopt is declared in vlMachineTypes, this declaration interferes.
// OS_API extern char *optarg;
// OS_API extern int optind, opterr;
// OS_API int getopt( int argc, char **argv, const char* options );


Libraries Required to Build the DDS Broker
Windows Libraries Linux Libraries
libvlOpenSplice.lib libvlOpenSplice
vlDIS.lib libvlDIS
vl.lib libvl
vlutil.lib libvlutil
matrix.lib libmatrix
mtl.lib libmtl
libDdsBroker.lib libDdsBroker
libBroker.lib libBroker
libPortal.lib libPortal
libwidgets.lib libwidgets
QtCore4.lib libQtCore
QtGui4.lib libQtGui
libxml2.lib libxml2
libboost_date_time_{compiler}.lib libboost_date_time_{compiler}

11.7 LROM Mapper Library Dependencies

VR-Exchange includes release and debug versions of the following LROM Mappers: coLromMapper and makLromMapper. You can use VR-Link to build custom LROM Mappers.

The LROM mapper files have several dynamic library dependencies that are not supplied with either VR-Link or VR-Exchange. You can get these libraries the following ways from the TENA SDA web site:

11.8 Rebuilding the TENA Broker

If you build a TENA broker, you must set the VR-Link compiler flag DtTENA. This library has the dynamic library dependencies listed in this section. The libraries are available from the indicated sources.

The TENA broker also needs to link against the VR-Link vlDIS library in order to use the DIS state repository to store entity and interaction attributes. Please consult the VR-Link documentation for instructions about how to build a VR-Link application for DIS for these flags.

Libraries required for each platform are essentially the same. The libraries supplied with TENA Middleware and the MAK Object Model use the following naming convention:

Library_name-os-[d-]version.extension

where:

The following libraries are supplied with the TENA Middleware:

The following libraries are supplied with the MAK Object Model:

The following MAK libraries are provided with VR-Exchange. On Windows, debug libraries have a "d" before the extension, for example, vlTenad.lib.

Note
The source for the vlTena library is part of the TENA broker, and this library is included in the TENA broker's solution. The vlTena library automatically builds and links into the TENA Broker when building.
Libraries Required to Build the TENA Broker
Windows Libraries Linux Libraries
libvlTena.lib libvlTena
vlDIS.lib libvlDIS
vl.lib libvl
vlutil.lib libvlutil
matrix.lib libmatrix
mtl.lib libmtl
libTenaBroker.lib libTenaBroker
libBroker.lib libBroker
libPortal.lib libPortal
libwidgets.lib libwidgets
QtCore4.lib libQtCore
QtGui4.lib libQtGui
libxml2.lib libxml2
libboost_date_time_{compiler}.lib libboost_date_time_{compiler}

[<< Extending the Portal Application] [Home] [Top of Page]


Document ID: Generated on Tue Jun 25 16:45:35 EDT 2024 from SVN revision 267383
Copyright © 2005-2024 MAK Technologies. All Rights Reserved (www.mak.com)