From 7bc68a5191581605a31aeec1b179e288cb67a190 Mon Sep 17 00:00:00 2001 From: Eduard Mihailescu Date: Mon, 30 Jan 2023 17:43:30 +0200 Subject: [PATCH] Created config options and basic structure --- Config.uk | 17 ++++++++++++++--- Makefile.uk | 8 ++++++++ tests/test_minimal.c | 0 3 files changed, 22 insertions(+), 3 deletions(-) create mode 100644 tests/test_minimal.c diff --git a/Config.uk b/Config.uk index b32df59..735442a 100644 --- a/Config.uk +++ b/Config.uk @@ -7,7 +7,18 @@ menuconfig LIBSQLITE select LIBPTHREAD_EMBEDDED if LIBSQLITE -config LIBSQLITE_MAIN_FUNCTION - bool "Provide main function" - default y + config LIBSQLITE_MAIN_FUNCTION + bool "Provide main function" + default y + config LIBSQLITE_TEST + bool "Enable sqlite tcl tests" + select LIBUKTEST + default n + select LIBSQLITE_TEST_MINIMAL + help + + config LIBSQLITE_TEST_MINIMAL + bool + default n + endif diff --git a/Makefile.uk b/Makefile.uk index a8b7183..e0f86bd 100644 --- a/Makefile.uk +++ b/Makefile.uk @@ -85,3 +85,11 @@ LIBSQLITE_SHELL_FLAGS-y += -Dmain=sqlite_main -Dwmain=sqlite_main LIBSQLITE_SRCS-y += $(LIBSQLITE_SRC)/shell.c LIBSQLITE_SRCS-y += $(LIBSQLITE_SRC)/sqlite3.c + + +################################################################################ +# Tests +################################################################################ +ifneq ($(filter y, $(LIBSQLITE_TEST_MINIMAL) $(CONFIG_LIBUKTEST_ALL)),) +LIBSQLITE_SRCS-y += $(LIBSQLITE_BASE)/tests/test_minimal.c +endif \ No newline at end of file diff --git a/tests/test_minimal.c b/tests/test_minimal.c new file mode 100644 index 0000000..e69de29