Skip to content

Latest commit

 

History

History
37 lines (25 loc) · 625 Bytes

README.md

File metadata and controls

37 lines (25 loc) · 625 Bytes

Cpp Project Template

This is a template of cpp project which can use cmake or bazel as build tools.

Use cmake

The project uses Google Test as unit test framework which is a submodule of the repository.

  1. Update submodule

    git submodule upate --init --recursive
  2. Make and test

    mkdir build
    cd build
    cmake ..
    make
    ctest

Use bazel

  1. Build

    bazel build -c opt //main:demo
  2. Run unit tests

    bazel test -c opt //lib:demo-lib-test