File tree Expand file tree Collapse file tree 2 files changed +10
-3
lines changed
Expand file tree Collapse file tree 2 files changed +10
-3
lines changed Original file line number Diff line number Diff line change 1919 matrix :
2020 external-gtest : [ YES, NO ]
2121 os : [ ubuntu-latest, ubuntu-22.04 ]
22+ asan : [ YES, NO ]
2223
2324 runs-on : ${{ matrix.os }}
2425 name : Build with external_gtest=${{ matrix.external-gtest }} on ${{ matrix.os }}
4445 # Note the current convention is to use the -S and -B options here to specify source
4546 # and build directories, but this is only available with CMake 3.13 and higher.
4647 # The CMake binaries on the Github Actions machines are (as of this writing) 3.12
47- run : cmake $GITHUB_WORKSPACE -DCMAKE_BUILD_TYPE=$BUILD_TYPE -DSCITOKENS_BUILD_UNITTESTS=yes -DSCITOKENS_EXTERNAL_GTEST=${{ matrix.external-gtest }}
48+ run : cmake $GITHUB_WORKSPACE -DCMAKE_BUILD_TYPE=$BUILD_TYPE -DSCITOKENS_BUILD_UNITTESTS=yes -DSCITOKENS_EXTERNAL_GTEST=${{ matrix.external-gtest }} -DSCITOKENS_WITH_ASAN=${{ matrix.asan }}
4849
4950 - name : Build
5051 working-directory : ${{runner.workspace}}/build
Original file line number Diff line number Diff line change @@ -6,15 +6,21 @@ project( scitokens-cpp
66 VERSION 1.0.2
77 LANGUAGES CXX)
88
9- option ( SCITOKENS_BUILD_UNITTESTS "Build the scitokens-cpp unit tests" OFF )
10- option ( SCITOKENS_EXTERNAL_GTEST "Use an external/pre-installed copy of GTest" OFF )
9+ option ( SCITOKENS_BUILD_UNITTESTS "Build the scitokens-cpp unit tests" ON )
10+ option ( SCITOKENS_EXTERNAL_GTEST " Use an external/pre-installed copy of GTest" OFF )
11+ option ( SCITOKENS_WITH_ASAN "Build with the address santizier" OFF )
1112
1213set ( CMAKE_MODULE_PATH "${PROJECT_SOURCE_DIR} /cmake;${CMAKE_MODULE_PATH} " )
1314
1415set ( CMAKE_BUILD_TYPE RelWithDebInfo) # -g -O2
1516
1617set ( CMAKE_UNITY_BUILD False )
1718
19+ if ( SCITOKENS_WITH_ASAN )
20+ add_compile_options (-fsanitize=address -fno-omit-frame-pointer)
21+ add_link_options (-fsanitize=address)
22+ endif ()
23+
1824include (GNUInstallDirs)
1925
2026find_package ( jwt-cpp REQUIRED )
You can’t perform that action at this time.
0 commit comments