Next: Running the Example Applications


NOTE: premake4 support is deprecated in the 2021 release and will be removed in a future release. We recommend using CMake for all new projects: Compiling and Installing the SDK - CMake (v8.0.0+).


Compiling for Windows

  1. Install Microsoft Visual Studio (MSVS).
    • Note: Versions 2010, 2012, 2013, and 2015 have all been tested and shown to work.
  2. Open a Windows command prompt.
  3. Navigate to the folder of the library (project) to be compiled.
  4. Generate an MSVS project by running premake4 using the command:
    premake4 vs2010
    • To view available options for premake4 use the --help flag with the premake4 command. Flags to create MSVS projects other than the core libraries are available among other options.
      • Note: Use 'vs2010' even if you're using a newer version of MSVS. The project can be upgraded later using the 'Retarget solution' command in MSVS .
  5. Open the generated solution in MSVS and allow it to automatically upgrade.
  6. Compile the code in MSVS  
    • Note: On some versions of MSVS a fatal error LNK1210 might be encountered while compiling the org.openjaus.iop-v2.cpp project. This can be handled by changing the setting /INCREMENTAL to NO in the Properties->Linker->Enable Incremental Linker setting.


Compiling for Desktop Linux

  1. Install the GNU C and C++ compiler tools.
  2. Open a linux shell.
  3. Navigate to the folder of the library (project) to be compiled.
  4. Generate the necessary Makefiles by running premake4 using the command:
    ./premake4 gmake
    • To view available options for premake4 use the --help flag with the premake4 command.
    • If you have a global version of premake4, make sure to use the local library version - ./premake4
  5. Compile the code using the command
    make all
    • Note: This will build the debug version of the files by default. For a release build the option is ‘config=release’. To explicitly specify a debug build the option is ‘config=debug’.


Cross-Compiling for ARM Linux

  1. Install the GNU C and C++ cross-compiler tools on the host machine.
  2. Open a command prompt/linux shell.
  3. Navigate to the folder of the library (project) to be compiled.
  4. Generate the necessary Makefiles by running premake4 using the command:
    ./premake4 gmake
    • To view available options for premake4 use the --help flag with the premake4 command.
    • If you have a global version of premake4, make sure to use the local library version - ./premake4
  5. Compile the code using the command
    make --config=debugarm all
    • Note: This will build the debug version of the files by default. For a release build the option is ‘config=releasearm’.


Next: Running the Example Applications