Skip to content

Commit

Permalink
Fix optimization build settings (#504)
Browse files Browse the repository at this point in the history
Default build settings were inadvertantly changed so that optimization
was always disabled. This PR fixes that mistake and updates debug build
configuration to guarantee that optimization is disabled.

Signed-off-by: Will Hawkins <[email protected]>
Co-authored-by: Alan Jowett <[email protected]>
  • Loading branch information
hawkinsw and Alan-Jowett authored Jun 10, 2024
1 parent 7e1d3cb commit 92c5a50
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions cmake/settings.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,7 @@ if(CMAKE_SOURCE_DIR STREQUAL CMAKE_CURRENT_SOURCE_DIR)
-Wall
-Werror
-Iinc
-O0
-g
-O2
-Wunused-parameter
-fPIC
)
Expand All @@ -27,6 +26,7 @@ if(CMAKE_SOURCE_DIR STREQUAL CMAKE_CURRENT_SOURCE_DIR)
CMAKE_BUILD_TYPE STREQUAL "RelWithDebInfo")

target_compile_options("ubpf_settings" INTERFACE
-O0
-g
)
endif()
Expand Down

0 comments on commit 92c5a50

Please sign in to comment.