Skip to content

Commit

Permalink
DuckDuckGo GRDB.swift 2.0.0 (GRDB 6.6.0, SQLCipher 4.5.3)
Browse files Browse the repository at this point in the history
  • Loading branch information
ayoy committed Jan 16, 2023
1 parent 72b86ee commit 8eac7de
Show file tree
Hide file tree
Showing 4 changed files with 75,614 additions and 71,006 deletions.
8 changes: 4 additions & 4 deletions .github/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ The default branch for this repository is `SQLCipher` so that we can more easily

## Versioning

* This Package: *1.2.1.1*
* GRDB: *5.26.0*
* SQLCipher: *4.5.1*
* This Package: *2.0.0*
* GRDB: *6.6.0*
* SQLCipher: *4.5.3*

## Contributions
We do not accept contributions to this repository at this time. However, feel free to open an issue in order to start a discussion.
Expand Down Expand Up @@ -66,7 +66,7 @@ Once approved:
* push the tag,
* update the reference to GRDB in BSK to point to a tag.

# Compiling SQLCipher manually
### Compiling SQLCipher manually

In case `prepare_release.sh` script fails, you need to compile SQLCipher amalgamation package
manually. See [general instructions](https://github.com/sqlcipher/sqlcipher#compiling-for-unix-like-systems):
Expand Down
12 changes: 6 additions & 6 deletions Sources/SQLCipher/include/SQLCipher_config.h
Original file line number Diff line number Diff line change
Expand Up @@ -3,30 +3,30 @@

#include "sqlite3.h"

typedef void(*errorLogCallback)(void *pArg, int iErrCode, const char *zMsg);
typedef void(*_errorLogCallback)(void *pArg, int iErrCode, const char *zMsg);

/// Wrapper around sqlite3_config(SQLITE_CONFIG_LOG, ...) which is a variadic
/// function that can't be used from Swift.
static inline void registerErrorLogCallback(errorLogCallback callback) {
static inline void _registerErrorLogCallback(_errorLogCallback callback) {
sqlite3_config(SQLITE_CONFIG_LOG, callback, 0);
}

#if SQLITE_VERSION_NUMBER >= 3029000
/// Wrapper around sqlite3_db_config() which is a variadic function that can't
/// be used from Swift.
static inline void disableDoubleQuotedStringLiterals(sqlite3 *db) {
static inline void _disableDoubleQuotedStringLiterals(sqlite3 *db) {
sqlite3_db_config(db, SQLITE_DBCONFIG_DQS_DDL, 0, (void *)0);
sqlite3_db_config(db, SQLITE_DBCONFIG_DQS_DML, 0, (void *)0);
}

/// Wrapper around sqlite3_db_config() which is a variadic function that can't
/// be used from Swift.
static inline void enableDoubleQuotedStringLiterals(sqlite3 *db) {
static inline void _enableDoubleQuotedStringLiterals(sqlite3 *db) {
sqlite3_db_config(db, SQLITE_DBCONFIG_DQS_DDL, 1, (void *)0);
sqlite3_db_config(db, SQLITE_DBCONFIG_DQS_DML, 1, (void *)0);
}
#else
static inline void disableDoubleQuotedStringLiterals(sqlite3 *db) { }
static inline void enableDoubleQuotedStringLiterals(sqlite3 *db) { }
static inline void _disableDoubleQuotedStringLiterals(sqlite3 *db) { }
static inline void _enableDoubleQuotedStringLiterals(sqlite3 *db) { }
#endif
#endif /* grdb_config_h */
Loading

0 comments on commit 8eac7de

Please sign in to comment.