Commit 3ede457c authored by Floris Bos's avatar Floris Bos Committed by Peter Korsgaard
Browse files

sqlite: add option to disable fsync



For use-cases in which performance is more important than data integrity.

Signed-off-by: default avatarFloris Bos <bos@je-eigen-domein.nl>
Reviewed-by: default avatarThomas Petazzoni <thomas.petazzoni@free-electrons.com>
Signed-off-by: default avatarPeter Korsgaard <peter@korsgaard.com>
parent 4288da4b
Loading
Loading
Loading
Loading
+9 −0
Original line number Diff line number Diff line
@@ -53,4 +53,13 @@ config BR2_PACKAGE_SQLITE_SECURE_DELETE
	  http://www.sqlite.org/pragma.html#pragma_secure_delete
	  for additional information.

config BR2_PACKAGE_SQLITE_NO_SYNC
	bool "Disable fsync"
	help
	  By default SQLite forces all database transactions to storage
	  immediately using fsync() to protect against data loss in case
	  of power failure.
	  This option turns this behavior off resulting in higher performance
	  especially when using slow flash storage.

endif
+4 −0
Original line number Diff line number Diff line
@@ -33,6 +33,10 @@ ifeq ($(BR2_PACKAGE_SQLITE_SECURE_DELETE),y)
SQLITE_CFLAGS += -DSQLITE_SECURE_DELETE
endif

ifeq ($(BR2_PACKAGE_SQLITE_NO_SYNC),y)
SQLITE_CFLAGS += -DSQLITE_NO_SYNC
endif

SQLITE_CONF_ENV = CFLAGS="$(TARGET_CFLAGS) $(SQLITE_CFLAGS)"

SQLITE_CONF_OPT = \