diff --git a/.DS_Store b/.DS_Store deleted file mode 100644 index 4dae19f..0000000 Binary files a/.DS_Store and /dev/null differ diff --git a/.github/workflows/cmake.yml b/.github/workflows/cmake.yml new file mode 100644 index 0000000..9bf03cb --- /dev/null +++ b/.github/workflows/cmake.yml @@ -0,0 +1,41 @@ +name: Build +on: + push: + +jobs: + build-project: + strategy: + matrix: + config: + - { + os: ubuntu-latest, + cmake_options: "", + dependencies: "sudo apt update -yqq && sudo apt -yqq install libboost-dev" + } + - { + os: macos-latest, + cmake_options: "CMAKE_PREFIX_PATH=/opt/homebrew", + dependencies: "brew install boost eigen && brew link boost eigen" + } + - { + os: windows-latest, + cmake_options: "BOOST_ROOT=c:/local/boost_1_86_0", + dependencies: "choco install eigen -y --no-progress && choco install boost-msvc-14.3 -y --no-progress" + } + + runs-on: ${{ matrix.config.os }} + steps: + - name: Checkout Project + uses: actions/checkout@v4 + with: + submodules: recursive + + - name: Dependencies + run: ${{ matrix.config.dependencies }} + + - name: Build Project + uses: threeal/cmake-action@v2.0.0 + with: + options: | + ${{ matrix.config.cmake_options }} + diff --git a/.gitignore b/.gitignore index 3cda0c6..b5fabc7 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,4 @@ +.DS_Store build/ .vscode/ *.user diff --git a/CMakeLists.txt b/CMakeLists.txt index 13aed94..5e2e24a 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -9,6 +9,12 @@ project( ### Library options ### option(PUARA_GESTURES_ENABLE_TESTING "Enable building and running Puara gestures tests" ON) +### Dependencies ### +if(POLICY CMP0167) + cmake_policy(SET CMP0167 OLD) +endif() +find_package(Boost REQUIRED) + ### Main library ### add_library(puara_gestures 3rdparty/IMU_Sensor_Fusion/imu_orientation.h @@ -37,7 +43,10 @@ add_library(puara_gestures src/puara_gestures.cpp ) +target_compile_definitions(puara_gestures PUBLIC $<$:_USE_MATH_DEFINES>) target_include_directories(puara_gestures PUBLIC include 3rdparty) +target_compile_features(puara_gestures PUBLIC cxx_std_20) +target_link_libraries(puara_gestures PUBLIC Boost::headers) ### Tests ### if(PUARA_GESTURES_ENABLE_TESTING) diff --git a/standalone/.DS_Store b/standalone/.DS_Store deleted file mode 100644 index 16d875f..0000000 Binary files a/standalone/.DS_Store and /dev/null differ