Enforce compiler warnings in CI build only.
This commit is contained in:
parent
d6d7ce1015
commit
5a0071f497
2 changed files with 11 additions and 7 deletions
|
|
@ -24,7 +24,8 @@ jobs:
|
|||
- name: Build module
|
||||
working-directory: build
|
||||
run: |
|
||||
cmake -DNGX_OTEL_NGINX_BUILD_DIR=${PWD}/../nginx/objs ..
|
||||
cmake -DNGX_OTEL_NGINX_BUILD_DIR=${PWD}/../nginx/objs \
|
||||
-DNGX_OTEL_DEV=ON ..
|
||||
make -j 4
|
||||
strip ngx_otel_module.so
|
||||
- name: Archive module
|
||||
|
|
|
|||
|
|
@ -8,6 +8,7 @@ set(NGX_OTEL_NGINX_DIR "${NGX_OTEL_NGINX_BUILD_DIR}/.."
|
|||
|
||||
set(NGX_OTEL_FETCH_DEPS ON CACHE BOOL "Download dependencies")
|
||||
set(NGX_OTEL_PROTO_DIR "" CACHE PATH "OTel proto files root")
|
||||
set(NGX_OTEL_DEV OFF CACHE BOOL "Enforce compiler warnings")
|
||||
|
||||
if(NOT CMAKE_BUILD_TYPE)
|
||||
set(CMAKE_BUILD_TYPE RelWithDebInfo)
|
||||
|
|
@ -99,7 +100,9 @@ add_custom_command(
|
|||
set(CMAKE_CXX_STANDARD 11)
|
||||
set(CMAKE_CXX_EXTENSIONS OFF)
|
||||
|
||||
add_compile_options(-Wall -Wtype-limits -Werror)
|
||||
if (NGX_OTEL_DEV)
|
||||
add_compile_options(-Wall -Wtype-limits -Werror)
|
||||
endif()
|
||||
|
||||
add_library(ngx_otel_module MODULE
|
||||
src/http_module.cpp
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue