Build ACE and SmartSoft on Windows using VisualStudio

1) Get ACE and SmartSoft sources + cmake

The first step is to download the packages for ACE and SmartSoft.

2) Extract the archives / checkout the repos

The location to extract the ACE archive should be carefully prudent. This path will be used later as central library among developers. Having said this, the ACE archive can be extracted in any path on the hard disk (e.g. C:\ACE_wrappers). This will be later the ACE root folder (see step 3).

SmartSoft sources can be extracted everywhere (e.g. C:\smartsoft-ace). This will be not necessarily the library path yet (see step 3 for more details).

3) Define ACE_ROOT and SMART_ROOT_ACE environment variables

This step decides where the libraries will be accessible for library users.

On Windows go to "System Properties", choose "Advanced" and click on "Environment Variables". Create two new environment variables with the following values:

  • 1. Variable:
    • Variable Name: ACE_ROOT
    • Variable Value: e.g. C:\ACE_wrappers
  • 2. Variable:
    • Variable Name: SMART_ROOT_ACE
    • Variable Value: e.g. C:\smartsoft-ace

The SMART_ROOT_ACE variable will be used later by VisualStudio to store the libraries, headers and binaries (that will be generated during the build proces).

4) Compile ACE library

General information on how to compile ACE on different platforms can be found here

A) First a %ACE_ROOT%\ace\config.h file has to be created with following content:

#include "ace/config-win32.h"

Make sure you have a newline at the end of the file!

B) Open the solution file correspoding to the used VisualStudio version. (ACE_vc_14.sln for VS2015)

C) Build ACE project as Release version (and as Debug version if wanted). 

5) Build SmartSoft-kernel library

Go to extracted SmartSoft-kernel directory and create a build directory for cmake:
(e.g. in C:\smartsoft-ace\src\smartSoftKernel\build
and call cmake with the parameters that match the VS version:
(e.g. cmake .. -G "Visual Studio 14 2015 Win64").

Open the generated VS solution file and compile all projects in the solution (Press F7 button to build the entire workspace).

If the INSTALL project or traget will install the following files created during the build process:

%SMART_ROOT_ACE%\bin\: This folder will store the ExampleComponents and the NamingService binaries (later own component-binaries can be also stored here).

%SMART_ROOT_ACE%\lib\: This folder contains the library files (e.g. SmartSoftKernel and ExampleInterfaceClasses).

%SMART_ROOT_ACE%\include\SmartSoftKernel\: During build process the header files from SmartSoftKernel will be generated into this folder. Thus this folder (together with the library folder) can be used to build own components.

%SMART_ROOT_ACE%\include\: This folder contains all other include files that are also copied during build process (e.g. Header files of Communication-Object classes).

By choosing Debug version each folder (shown above) will be enriched with a Debug subfolder.

6) Add ACE_ROOT\lib to the PATH

To run any binary compiled with SmartSoft you have to add  %ACE_ROOT%\lib to your System Path

On Windows 10 enter "environment variables" to the search field in the start menu, and select "Edit the system environment variables". Click on "Environment Variables"  and add the %ACE_ROOT%\lib as entry to the Path variable.

Installation Done!

7) Run NamingService

To start the NamingService-Daemon run the NS-Daemon.exe binary. The NamingService can be started with following commands out of a console:

# set PATH=%PATH%;%ACE_ROOT%\lib
# cd %SMART_ROOT_ACE%\bin\NamingService\
# SmartSoftNamingService.exe

7) Test some example-components

The smartsoft-kernel includes several example components, to test the installation or to demonstrate how to use smartsoft on a code and library level. For the development of "full-fetch" smartsoft components we offer our robotics IDE SmartMDSD Toolchain.
To start the example-components use a new console for each component: 

# cd %SMART_ROOT_ACE%\bin\
# exampleComponent01.exe
# exampleComponent02.exe