Elektron SDK - C/C++

API Family: Elektron

EMA C++ Compiler Settings

The following guides provide the necessary compiler and environment settings required to build and run an EMA C++ application.

*Important Note*

In versions prior to 1.2, the ESDK APIs were built without a CMake harness (i.e., developers used the static build files with other utilities such as Visual Studio or Linux make to build the APIs). As of open-source version 1.2 ESDK release, developers use CMake to dynamically generate the build files.  Refer to the generated build files for up-to-date project settings for your compiler and environment.  Prior to ESDK 1.2, refer to the project setting details below.

 

 

Note: EMA is packaged as part of the Elektron SDK bundle.  Refer to the README file within the Ema subfolder of the Elektron SDK bundle for the complete list of OS and compiler support.

The EMA packages provide the ability to:

  • Build statically linked and dynamically linked binaries
  • Support for debug and release build types
  • Support for 64-bit architectures

Choose your development environment:

  EMA static libraries EMA shared libraries
Visual Studio Statically Linked Binary Dynamically Linked Binary
Linux Statically Linked Binary Dynamically Linked Binary

Windows - Visual Studio - Statically Linked Binary

Note: <EMA root> is a directory which is located within your Elektron SDK installation package


Include Path Within Properties: VC++ Directories -> Include Directories define the following:
  • <EMA root>\Src;<EMA root>\Src\Include
Lib Path

VS2015

(EMA 1.0.2 or greater)
Within Properties: VC++ Directories -> Library Directories define only one based on your build preference:
  • <EMA root>\Libs\WIN_64_VS140\Debug_MDd
  • <EMA root>\Libs\WIN_64_VS140\Release_MD
  • <EMA root>\Libs\WIN_64_VS140\Release_MD_Assert
Lib Path

VS2013
Within Properties: VC++ Directories -> Library Directories define only one based on your build preference:
  • <EMA root>\Libs\WIN_64_VS120\Debug_MDd
  • <EMA root>\Libs\WIN_64_VS120\Release_MD
  • <EMA root>\Libs\WIN_64_VS120\Release_MD_Assert
Lib Path

VS2012
Within Properties: VC++ Directories -> Library Directories define only one based on your build preference:
  • <EMA root>\Libs\WIN_64_VS110\Debug_MDd
  • <EMA root>\Libs\WIN_64_VS110\Release_MD
  • <EMA root>\Libs\WIN_64_VS110\Release_MD_Assert
Lib Path

VS2010
Within Properties: VC++ Directories -> Library Directories define only one based on your build preference:
  • <EMA root>\Libs\WIN_64_VS100\Debug_MDd
  • <EMA root>\Libs\WIN_64_VS100\Release_MD
  • <EMA root>\Libs\WIN_64_VS100\Release_MD_Assert
Libs Within Properties: Linker -> Input -> Additional Dependencies include the entry below:
  • libema.lib
Compiler Settings Within Properties define all settings below:
  • C/C++ -> Precompiled Headers define: Precompiled Header: Not using Precompiled Headers
  • Linker -> Advanced: Ensure Image Has Safe Exception Handlers is blank
Runtime Environment No runtime environment settings required.

Windows - Visual Studio - Dynamically Linked Binary

Note: <EMA root> is a directory which is located within your Elektron SDK installation package


Include Path Within Properties: VC++ Directories -> Include Directories define the following:
  • <EMA root>\Src;<EMA root>\Src\Include
Lib Path

VS2015

(EMA 1.0.2 or greater)
Within Properties: VC++ Directories -> Library Directories define only one based on your build preference:
  • <EMA root>\Libs\WIN_64_VS140\Debug_MDd\Shared
  • <EMA root>\Libs\WIN_64_VS140\Release_MD\Shared
  • <EMA root>\Libs\WIN_64_VS140\Release_MD_Assert\Shared
Lib Path

VS2013
Within Properties: VC++ Directories -> Library Directories define only one based on your build preference:
  • <EMA root>\Libs\WIN_64_VS120\Debug_MDd\Shared
  • <EMA root>\Libs\WIN_64_VS120\Release_MD\Shared
  • <EMA root>\Libs\WIN_64_VS120\Release_MD_Assert\Shared
Lib Path

VS2012
Within Properties: VC++ Directories -> Library Directories define only one based on your build preference:
  • <EMA root>\Libs\WIN_64_VS110\Debug_MDd\Shared
  • <EMA root>\Libs\WIN_64_VS110\Release_MD\Shared
  • <EMA root>\Libs\WIN_64_VS110\Release_MD_Assert\Shared
Lib Path

VS2010
Within Properties: VC++ Directories -> Library Directories define only one based on your build preference:
  • <EMA root>\Libs\WIN_64_VS100\Debug_MDd\Shared
  • <EMA root>\Libs\WIN_64_VS100\Release_MD\Shared
  • <EMA root>\Libs\WIN_64_VS100\Release_MD_Assert\Shared
Libs Within Properties: Linker -> Input -> Additional Dependencies include the entry below:
  • libema.lib
Compiler Settings Within Properties define all settings below:
  • C/C++ -> Precompiled Headers define: Precompiled Header: Not using Precompiled Headers
  • Linker -> Advanced: Ensure Image Has Safe Exception Handlers is blank
Runtime Environment Ensure the selected Lib Path detailed above is defined within your system path

Linux - Statically Linked Binary

Note: <EMA root> is a directory which is located within your Elektron SDK installation package


Include Path Using the header include flag (-I):
  • <EMA root>/Src;<EMA root>/Src/Include
Lib Path Using the library include flag (-L), choose one based on your compiler:

Compiler EMA Lib Path
GCC suite 4.4.4 or higher for RHAS 6.0 (64-bit)
  • -L<EMA root>/Libs/RHEL6_64_GCC444/Optimized
  • -L<EMA root>/Libs/RHEL6_64_GCC444/Optimized_Assert
GCC suite 4.8.2 or higher for Oracle Linux 7.0 (64-bit)
  • -L<EMA root>/Libs/OL7_64_GCC482/Optimized
  • -L<EMA root>/Libs/OL7_64_GCC482/Optimized_Assert

Note: Oracle Linux 7.0 libraries are fully compatible with RHEL7.

Libs Libraries to be linked using (-l):
  • -lema
  • -lrsslVA
  • -lrssl
  • -lxml2
Compiler Settings Compiler flags (-D): -DLinux
Runtime Environment No runtime environment settings required.

Linux - Dynamically Linked Binary

Note: <EMA root> is a directory which is located within your Elektron SDK installation package

EMA contains a convenient script within the Libs subfolder called: createSharedLibraryLinks.sh.  Before building your applications using shared libraries, execute this command from the EMA root folder, i.e.

<ema root>: sh Libs/createSharedLibraryLinks.sh

Include Path Using the header include flag (-I):
  • <EMA root>/Src;<EMA root>/Src/Include
Lib Path Using the library include flag (-L), choose one based on your compiler:

Compiler EMA Lib Path
GCC suite 4.4.4 or higher for RHAS 6.0 (64-bit)
  • -L<EMA root>/Libs/RHEL6_64_GCC444/Optimized/Shared
  • -L<EMA root>/Libs/RHEL6_64_GCC444/Optimized_Assert/Shared
GCC suite 4.8.2 or higher for Oracle Linux 7.0 (64-bit)
  • -L<EMA root>/Libs/OL7_64_GCC482/Optimized/Shared
  • -L<EMA root>/Libs/OL7_64_GCC482/Optimized_Assert/Shared

Note: Oracle Linux 7.0 libraries are fully compatible with RHEL7.

Libs Libraries to be linked using (-l):
  • -lema
Compiler Settings Compiler flags (-D): -DLinux
Runtime Environment Ensure the selected Lib Path detailed above is defined within your library path environment variable: LD_LIBRARY_PATH