From dac585c01bf802abdc41eac31a63508cae8cd298 Mon Sep 17 00:00:00 2001 From: Alexander Shaduri Date: Mon, 1 Mar 2021 16:20:40 +0400 Subject: [PATCH] Fixed building examples. --- src/applib/examples/smartctl_executor_example.cpp | 4 ++-- src/applib/examples/smartctl_parser_example.cpp | 4 ++-- src/applib/examples/storage_detector_example.cpp | 4 ++-- src/hz/examples/format_unit_example.cpp | 2 +- src/hz/examples/string_algo_example.cpp | 2 +- src/hz/examples/string_num_example.cpp | 2 +- src/libdebug/examples/libdebug_example.cpp | 8 ++++---- src/rconfig/examples/rconfig_example.cpp | 4 ++-- 8 files changed, 15 insertions(+), 15 deletions(-) diff --git a/src/applib/examples/smartctl_executor_example.cpp b/src/applib/examples/smartctl_executor_example.cpp index e6bfb15..3bc5ae6 100644 --- a/src/applib/examples/smartctl_executor_example.cpp +++ b/src/applib/examples/smartctl_executor_example.cpp @@ -18,8 +18,8 @@ Copyright: #include #include -// #include "smartctl_executor_gui.h" -#include "smartctl_executor.h" +// #include "applib/smartctl_executor_gui.h" +#include "applib/smartctl_executor.h" diff --git a/src/applib/examples/smartctl_parser_example.cpp b/src/applib/examples/smartctl_parser_example.cpp index f145549..a3df5d2 100644 --- a/src/applib/examples/smartctl_parser_example.cpp +++ b/src/applib/examples/smartctl_parser_example.cpp @@ -20,8 +20,8 @@ Copyright: #include "libdebug/libdebug.h" #include "hz/fs.h" -#include "storage_property.h" -#include "smartctl_parser.h" +#include "applib/storage_property.h" +#include "applib/smartctl_parser.h" diff --git a/src/applib/examples/storage_detector_example.cpp b/src/applib/examples/storage_detector_example.cpp index a085f2a..9eedc8c 100644 --- a/src/applib/examples/storage_detector_example.cpp +++ b/src/applib/examples/storage_detector_example.cpp @@ -11,8 +11,8 @@ Copyright: #include -#include "storage_device.h" -#include "storage_detector.h" +#include "applib/storage_device.h" +#include "applib/storage_detector.h" #include "gsc_settings.h" // in src directory diff --git a/src/hz/examples/format_unit_example.cpp b/src/hz/examples/format_unit_example.cpp index 7caafac..f0c8fc9 100644 --- a/src/hz/examples/format_unit_example.cpp +++ b/src/hz/examples/format_unit_example.cpp @@ -18,7 +18,7 @@ Copyright: // The first header should be then one we're testing, to avoid missing // header pitfalls. -#include "format_unit.h" +#include "hz/format_unit.h" #include #include diff --git a/src/hz/examples/string_algo_example.cpp b/src/hz/examples/string_algo_example.cpp index 97a690e..578c1d4 100644 --- a/src/hz/examples/string_algo_example.cpp +++ b/src/hz/examples/string_algo_example.cpp @@ -18,7 +18,7 @@ Copyright: // The first header should be then one we're testing, to avoid missing // header pitfalls. -#include "string_algo.h" +#include "hz/string_algo.h" #include #include diff --git a/src/hz/examples/string_num_example.cpp b/src/hz/examples/string_num_example.cpp index 75aa5ae..d07f24e 100644 --- a/src/hz/examples/string_num_example.cpp +++ b/src/hz/examples/string_num_example.cpp @@ -18,7 +18,7 @@ Copyright: // The first header should be then one we're testing, to avoid missing // header pitfalls. -#include "string_num.h" +#include "hz/string_num.h" #include #include diff --git a/src/libdebug/examples/libdebug_example.cpp b/src/libdebug/examples/libdebug_example.cpp index e5bb29a..74f0c10 100644 --- a/src/libdebug/examples/libdebug_example.cpp +++ b/src/libdebug/examples/libdebug_example.cpp @@ -11,7 +11,7 @@ Copyright: // The first header should be then one we're testing, to avoid missing // header pitfalls. -#include "libdebug.h" +#include "libdebug/libdebug.h" #include @@ -21,7 +21,7 @@ namespace libdebug_example { /// Libdebug test class struct TestClassA { - bool func(int a = 2) + bool func([[maybe_unused]] int a = 2) { // this prints "func" debug_out_info("default", DBG_FUNC_NAME << "\n"); @@ -46,7 +46,7 @@ namespace { template struct TestClassB { template - U func2(V v, int) + U func2([[maybe_unused]] V v, int) { debug_out_info("default", DBG_FUNC_PRNAME << "\n"); debug_out_info("default", DBG_FUNC_MSG << "function called.\n"); @@ -63,7 +63,7 @@ namespace { /// Main function for the test -int main(int argc, char *argv[]) +int main() { debug_register_domain("dom"); diff --git a/src/rconfig/examples/rconfig_example.cpp b/src/rconfig/examples/rconfig_example.cpp index 6b992db..9a317a3 100644 --- a/src/rconfig/examples/rconfig_example.cpp +++ b/src/rconfig/examples/rconfig_example.cpp @@ -16,10 +16,10 @@ Copyright: #undef HZ_EMULATE_LIBDEBUG #define HZ_EMULATE_LIBDEBUG 1 -#include "loadsave.h" +#include "rconfig/loadsave.h" #if defined ENABLE_GLIB && ENABLE_GLIB - #include "autosave.h" + #include "rconfig/autosave.h" #endif #include