Skip to content

Configure CAF build CMake vs SNocs

Oleg edited this page Apr 19, 2015 · 16 revisions

The configure script has a lot of options which help you to customize your build. This is the list of all configure options available in CMake and their analogues in SNocs (configuration options for CMake can be found here)

Build Options

  • --generator=GENERATOR set CMake generator. No analogue in SNocs now, for building in IDE you need to create Makefiles project and specify the build arguments for snocs
  • --build-type=TYPE set CMake build type (Default: RelWithDebInfo).
  • Debug debugging flags enabled
    • configuration=Debug in SNocs
  • MinSizeRel minimal output size
    • configuration=Release cppflag=-Os in SNocs
  • Release optimizations on, debugging off
    • configuration=Release cppflag=-O3 in SNocs
  • RelWithDebInfo release flags plus debugging
    • configuration=Debug cppflag=-O2 in SNocs
  • --build-dir=DIR place build files in given directory (Default: build)
    • In SNocs all object files stored in separated *.tmp directories along with the source code
  • --bin-dir=DIR executable directory (Default: build/bin)
    • SNOCS_INSTALL_BIN_PATH environment variable in SNocs (Default: build/bin)
  • --lib-dir=DIR library directory (Default: build/lib)
    • SNOCS_INSTALL_LIB_PATH environment variable in SNocs (Default: build/lib)
  • --with-clang=FILE path to clang++ executable
    • compiler=clangpp compiler_path=FULL_PATH_TO_CLANG++ in SNocs
  • --with-gcc=FILE path to g++ executable
    • compiler=gpp compiler_path=FULL_PATH_TO_G++ in SNocs
  • --dual-build build using both gcc and clang
    • execute the build twice with gpp and clangpp compiler options in SNocs
  • --build-static build as static and shared library
    • by default the build is static shared=0 in SNocs, to get also shared libs execute snocs with shared=1
  • --build-static-only build as static library only
    • by default the build is static: shared=0 in SNocs
  • --more-warnings enables most of Clang's/GCC's warning flags
    • exactly the same flag --more-warnings available in SNocs
  • --no-compiler-check disable compiler version check
    • not implemented in SNocs
  • --warnings-as-errors enables -Werror
  • exactly the same flag --warnings-as-errors available in SNocs

Installation Directories

  • --prefix=PREFIX installation directory (Default: /usr/local)
  • for SNocs set the SNOCS_INSTALL_BIN_PATH and SNOCS_INSTALL_LIB_PATH environment variables

Optional Features

  • --enable-perftools build with Google perftools
  • not implemented in SNocs

Disable Features

  • --no-memory-management build without memory management
  • define=CAF_NO_MEM_MANAGEMENT in Snocs
  • --no-examples build without examples
  • in Snocs to skip any project set --no-PROJECT_NAME or without=PROJECT_NAME for examples without=*libcaf_examples, * is necessary for correct filtering project names like NAME_libcaf_examples
  • --no-qt-examples build without Qt examples
  • --no-qt_group_chat or without=qt_group_chat in SNocs
  • --no-protobuf-examples build without Google Protobuf examples
  • --no-protobuf_broker or without=protobuf_broker in SNocs
  • --no-curl-examples build without libcurl examples
  • --no-curl_fuse or without=curl_fuse in SNocs
  • --no-unit-tests build without unit tests
  • --no-*unit_test or without=*unit_test in SNocs
  • --no-opencl build without opencl
  • --no-*opencl or without=*opencl in SNocs
  • --no-nexus build without nexus
  • --no-nexus or without=nexus in SNocs
  • --no-cash build without shell (cash)
  • --no-cash or without=cash in SNocs
  • --no-benchmarks build without benchmarks
  • No benchmarks are implemented in SNocs
  • --no-riac build without riac
  • --no-libcaf_riac or without=libcaf_riac in SNocs

Debugging

  • --with-runtime-checks build with requirement checks at runtime
    • define=CAF_ENABLE_RUNTIME_CHECKS in SNocs
  • --with-log-level=LVL build with debugging output
  • ERROR
    • define="CAF_LOG_LEVEL=0" define="LOG_LEVEL_STR=\"ERROR\"" in SNocs
  • WARNING
    • define="CAF_LOG_LEVEL=1" define="LOG_LEVEL_STR=\"WARNING\"" in SNocs
  • INFO
    • define="CAF_LOG_LEVEL=2" define="LOG_LEVEL_STR=\"INFO\"" in SNocs
  • DEBUG
    • define="CAF_LOG_LEVEL=3" define="LOG_LEVEL_STR=\"DEBUG\"" in SNocs
  • TRACE
    • define="CAF_LOG_LEVEL=4" define="LOG_LEVEL_STR=\"TRACE\"" in SNocs
  • --with-address-sanitizer build with address sanitizer if available
    • cppflag=-fsanitize=address cppflag=-fno-omit-frame-pointer in SNocs

Benchmark Suite Options

  • --with-javac=File path to java compiler
  • --with-java=FILE path to java
  • --with-scalac=FILE path to scalac executable
  • --with-erlc=FILE path to erlc executable
  • --with-charmc=FILE path to charm++ compiler
  • --with-salsa=FILE path to salsa compiler

No benchmarks are implemented in SNocs build