From 442688504260bb2bfcfb08a9865f223d2ab2d19a Mon Sep 17 00:00:00 2001 From: dbiastoch Date: Wed, 13 Jan 2021 11:27:17 +0100 Subject: dlt-receive: Enabled more filtering by using json filter files -Added '-j' flag to dlt-receive for reading a json filter file -Added more attributes to DltFilter (LogLevel, MaxPayload, MinPayload) for extended message filtering, when using old filters these values are set to default. Same behaviour, when they are not defined in json filter file. -extended dlt_common.c to support json filter files and new DltFilter attributes +add dlt_json_filter_load to parse a json filter file into a DltFilter +add dlt_json_filter_save to print a DltFilter into a json file -Two new libraries are used to parse the json filter files: json-c for Linux based systems and the QNX internal libjson for QNX systems -gtest_dlt_common was modified to test the new function 'dlt_json_filter_load' +add testfile_extended.dlt that contains a bigger varity of messages (different context/app IDs, lengths and log levels) +add testfilter.json which is a valid json filter file -New dependency on library was added to related CMakeLists and is described in README.md Signed-off-by: dbiastoch --- src/lib/CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/lib') diff --git a/src/lib/CMakeLists.txt b/src/lib/CMakeLists.txt index 5a94bef..a070730 100644 --- a/src/lib/CMakeLists.txt +++ b/src/lib/CMakeLists.txt @@ -44,7 +44,7 @@ else() message(STATUS "pthread_setname_np API not available on this platform") endif() -target_link_libraries(dlt ${RT_LIBRARY} ${SOCKET_LIBRARY} Threads::Threads) +target_link_libraries(dlt ${RT_LIBRARY} ${SOCKET_LIBRARY} ${JSON_LIBRARIES} Threads::Threads) target_include_directories(dlt PUBLIC -- cgit v1.2.1