X-Git-Url: http://git.code-monkey.de/?p=pulseview.git;a=blobdiff_plain;f=CMakeLists.txt;h=b6c88f4f640c37ffea1b972b0c39f956ab8c4156;hp=050e8a351a1f19b30d54b9c24ba3613d11ae1677;hb=b9591f3a680dd35b7af2fb482a136b1bd494c6e4;hpb=844c4619ddbbab7d05ed01961f6b5957a3db75c5 diff --git a/CMakeLists.txt b/CMakeLists.txt index 050e8a3..b6c88f4 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -40,10 +40,11 @@ list(APPEND CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/CMake") #= User Options #------------------------------------------------------------------------------- -option(DISABLE_WERROR "Build without -Werror" FALSE) +option(DISABLE_WERROR "Build without -Werror" TRUE) option(ENABLE_SIGNALS "Build with UNIX signals" TRUE) option(ENABLE_STACKTRACE "Enable stack trace when crashing" FALSE) option(ENABLE_DECODE "Build with libsigrokdecode" TRUE) +option(ENABLE_FLOW "Build with libsigrokflow" FALSE) option(ENABLE_TESTS "Enable unit tests" FALSE) option(STATIC_PKGDEPS_LIBS "Statically link to (pkg-config) libraries" FALSE) @@ -62,6 +63,12 @@ if(NOT CMAKE_BUILD_TYPE) FORCE) endif() +#=============================================================================== +#= Documentation +#------------------------------------------------------------------------------- + +add_subdirectory(manual) + #=============================================================================== #= Dependencies #------------------------------------------------------------------------------- @@ -69,11 +76,16 @@ endif() list(APPEND PKGDEPS glib-2.0>=2.28.0) list(APPEND PKGDEPS glibmm-2.4>=2.28.0) -set(LIBSR_CXX_BINDING "libsigrokcxx>=0.6.0") +if(ENABLE_FLOW) + list(APPEND PKGDEPS gstreamermm-1.0>=1.8.0) + list(APPEND PKGDEPS libsigrokflow>=0.1.0) +endif() + +set(LIBSR_CXX_BINDING "libsigrokcxx>=0.5.1") list(APPEND PKGDEPS "${LIBSR_CXX_BINDING}") if(ENABLE_DECODE) - list(APPEND PKGDEPS libsigrokdecode>=0.6.0) + list(APPEND PKGDEPS libsigrokdecode>=0.5.2) endif() if(ANDROID) @@ -81,7 +93,7 @@ if(ANDROID) endif() find_package(PkgConfig) -pkg_check_modules(LIBSRCXX QUIET ${LIBSR_CXX_BINDING}) +pkg_check_modules(LIBSRCXX ${LIBSR_CXX_BINDING}) if(NOT LIBSRCXX_FOUND OR NOT LIBSRCXX_VERSION) message(FATAL_ERROR "libsigrok C++ bindings missing, check libsigrok's 'configure' output (missing dependencies?)") endif() @@ -191,6 +203,12 @@ if(NOT PV_TAG_VERSION_STRING) string(SUBSTRING "${PV_HASH}" 0 7 PV_SHORTHASH) set(PV_VERSION_STRING "${PV_VERSION_STRING}-git-${PV_SHORTHASH}") endif() + + # Non-tagged releases use the unstable manual + set(PV_MANUAL_VERSION "unstable") +else() + # Tagged releases use a fixed manual version + set(PV_MANUAL_VERSION ${PV_VERSION_STRING}) endif() if(PV_VERSION_STRING MATCHES "^([0-9]+)\\.([0-9]+)\\.([0-9]+)(-[-0-9a-z]*)?$") @@ -248,6 +266,7 @@ set(pulseview_SOURCES pv/prop/int.cpp pv/prop/property.cpp pv/prop/string.cpp + pv/subwindows/subwindowbase.cpp pv/toolbars/mainbar.cpp pv/views/trace/analogsignal.cpp pv/views/trace/cursor.cpp @@ -312,6 +331,7 @@ set(pulseview_HEADERS pv/prop/int.hpp pv/prop/property.hpp pv/prop/string.hpp + pv/subwindows/subwindowbase.hpp pv/toolbars/mainbar.hpp pv/views/trace/analogsignal.hpp pv/views/trace/cursor.hpp @@ -363,6 +383,9 @@ if(ENABLE_DECODE) pv/data/decode/decoder.cpp pv/data/decode/row.cpp pv/data/decode/rowdata.cpp + pv/subwindows/decoder_selector/item.cpp + pv/subwindows/decoder_selector/model.cpp + pv/subwindows/decoder_selector/subwindow.cpp pv/views/trace/decodetrace.cpp pv/widgets/decodergroupbox.cpp pv/widgets/decodermenu.cpp @@ -370,6 +393,7 @@ if(ENABLE_DECODE) list(APPEND pulseview_HEADERS pv/data/decodesignal.hpp + pv/subwindows/decoder_selector/subwindow.hpp pv/views/trace/decodetrace.hpp pv/widgets/decodergroupbox.hpp pv/widgets/decodermenu.hpp @@ -402,6 +426,10 @@ add_definitions(-Wall -Wextra) add_definitions(-std=c++11) add_definitions(-DBOOST_MATH_DISABLE_FLOAT128=1) +if(ENABLE_FLOW) + add_definitions(-DENABLE_FLOW) +endif() + if(ENABLE_DECODE) add_definitions(-DENABLE_DECODE) endif() @@ -512,7 +540,7 @@ install(FILES icons/pulseview.png DESTINATION ${CMAKE_INSTALL_DATAROOTDIR}/icons install(FILES icons/pulseview.svg DESTINATION ${CMAKE_INSTALL_DATAROOTDIR}/icons/hicolor/scalable/apps) # Generate Windows installer script. -configure_file(contrib/pulseview_cross.nsi.in contrib/pulseview_cross.nsi @ONLY) +configure_file(contrib/pulseview_cross.nsi.in ${CMAKE_CURRENT_BINARY_DIR}/contrib/pulseview_cross.nsi @ONLY) #=============================================================================== #= Packaging (handled by CPack)