Skip to content

Commit

Permalink
g
Browse files Browse the repository at this point in the history
  • Loading branch information
gilpazintel committed Feb 27, 2025
1 parent 3828011 commit 458b0bf
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 9 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/static_analysis.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -117,13 +117,13 @@ jobs:
run: |
mkdir build
cd build
cmake .. -DBUILD_EXAMPLES=true -DBUILD_GRAPHICAL_EXAMPLES=true
cmake .. -DBUILD_EXAMPLES=true
make -j$(($(nproc)-1))
- name: Run Valgrind
run: |
cd build
valgrind --leak-check=yes --show-leak-kinds=all --track-origins=yes --log-file=valgrind-out.txt ./Release/rs-software-device
valgrind --leak-check=yes --show-leak-kinds=all --track-origins=yes --log-file=valgrind-out.txt ./Release/start-camera-for-mem-leak
continue-on-error: true

- name: Upload Valgrind Log
Expand Down
16 changes: 9 additions & 7 deletions examples/memory-leaks-check/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,15 @@
# Copyright(c) 2019-2024 Intel Corporation. All Rights Reserved.
cmake_minimum_required(VERSION 3.8)

project(RealsenseExamplesMemLeak )
project(RealsenseExamplesMemoryLeaksCheck )

# Save the command line compile commands in the build output
set(CMAKE_EXPORT_COMPILE_COMMANDS 1)
add_executable( start-camera-for-mem-leak start-camera-for-mem-leak.cpp )
set_property(TARGET start-camera-for-mem-leak PROPERTY CXX_STANDARD 11)
target_link_libraries( start-camera-for-mem-leak ${DEPENDENCIES} tclap )
include_directories(../ ../../third-party/ ../../common/res)
set_target_properties( start-camera-for-mem-leak PROPERTIES FOLDER "Examples" )
install( TARGETS start-camera-for-mem-leak RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} )
if(BUILD_GRAPHICAL_EXAMPLES)
add_executable( start-camera-for-mem-leak start-camera-for-mem-leak.cpp ${IMGUI_SOURCES})
set_property(TARGET start-camera-for-mem-leak PROPERTY CXX_STANDARD 11)
target_link_libraries( start-camera-for-mem-leak ${DEPENDENCIES} tclap )
include_directories(../ ../../third-party/ ../../common/res)
set_target_properties( start-camera-for-mem-leak PROPERTIES FOLDER "Examples" )
install( TARGETS start-camera-for-mem-leak RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} )
endif()

0 comments on commit 458b0bf

Please sign in to comment.