Skip to content

Commit

Permalink
Add an option to disable crash reporter GUI component
Browse files Browse the repository at this point in the history
  • Loading branch information
dmitrio95 committed Feb 22, 2019
1 parent 4f2339d commit 43ea191
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 3 deletions.
7 changes: 6 additions & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@ if(POLICY CMP0071)
cmake_policy(SET CMP0071 NEW)
endif()

option(ENABLE_GPL_CODE OFF)
option(ENABLE_GPL_CODE "Enable GPL-licensed depencencies of libcrashreporter-qt (dr.konqui integration)" OFF)
option(ENABLE_CRASH_REPORTER "Enable libcrashreporter-qt GUI component" ON)

find_package(Qt5 COMPONENTS Core Network Widgets)

Expand All @@ -18,5 +19,9 @@ if((CMAKE_COMPILER_IS_GNUCXX AND CMAKE_CXX_FLAGS) OR
string(REPLACE "-std=c++14" "-std=gnu++14" CMAKE_CXX_FLAGS ${CMAKE_CXX_FLAGS})
endif()

if(ENABLE_CRASH_REPORTER)
add_definitions(-DENABLE_CRASH_REPORTER)
endif(ENABLE_CRASH_REPORTER)

add_subdirectory(3rdparty)
add_subdirectory(src)
5 changes: 4 additions & 1 deletion src/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1,5 @@
add_subdirectory(libcrashreporter-handler)
add_subdirectory(libcrashreporter-gui)

if (ENABLE_CRASH_REPORTER)
add_subdirectory(libcrashreporter-gui)
endif(ENABLE_CRASH_REPORTER)
2 changes: 1 addition & 1 deletion src/libcrashreporter-handler/Handler.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -218,7 +218,7 @@ LaunchUploader( const char* dump_dir, const char* minidump_id, void* context, bo
printf( "Error: Can't launch CrashReporter!\n" );
return false;
}
#ifdef Q_OS_LINUX
#if defined(Q_OS_LINUX) && defined(ENABLE_CRASH_REPORTER)
// If we're running on Linux, we expect that the CrashReporter component will
// attach gdb, do its thing and then kill this process, so we hang here for the
// time being, on purpose. -- Teo 3/2016
Expand Down

0 comments on commit 43ea191

Please sign in to comment.