Skip to content

Commit 8914cd0

Browse files
committed
Tweaks for Session build
1 parent 3ee3fba commit 8914cd0

File tree

4 files changed

+6570
-87
lines changed

4 files changed

+6570
-87
lines changed

.github/README.md.in

Lines changed: 0 additions & 76 deletions
This file was deleted.

README.md

Lines changed: 77 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,80 @@
1+
# GRDB + SQLCipher
2+
3+
## What is this?
4+
This is a fork of [GRDB](https://github.com/groue/GRDB.swift) which contains a [SQLCipher Community Edition](https://www.zetetic.net/sqlcipher/open-source/) amalgamation packaged so that it can be consumed as a Swift Package.
5+
6+
The default branch for this repository is `SQLCipher` so that we can more easily pull upstream changes if we need to.
7+
8+
## Versioning
9+
10+
* This Package: *2.0.0*
11+
* GRDB: *6.6.0*
12+
* SQLCipher: *4.5.3*
13+
14+
## Contributions
15+
We do not accept contributions to this repository at this time. However, feel free to open an issue in order to start a discussion.
16+
17+
18+
## Updating from Upstream
19+
20+
Add remote upstream:
21+
22+
* `git remote add upstream [email protected]:groue/GRDB.swift.git`
23+
24+
Check out upstream's master branch locally:
25+
26+
* `git fetch upstream +master:upstream-master && git checkout upstream-master`
27+
28+
Update upstream's master branch if needed:
29+
30+
* `git pull upstream master`
31+
32+
Switch back to the `SQLCipher` branch and merge with upstream-master:
33+
34+
* `git merge upstream-master`
35+
36+
Resolve any conflicts that may occur (normally there should be none or only in Package.swift)
37+
and commit the merge. Once done, run `prepare_release.sh` script to fetch and compile the latest tag
38+
of SQLCipher and embed it in GRDB.swift:
39+
40+
* `./prepare_release.sh`
41+
42+
The script will also:
43+
* present the summary of updated versions and ask you to pick the new version number for DuckDuckGo GRDB fork,
44+
* test the build,
45+
* create a new release branch and commit changes.
46+
47+
For versioning, follow [Semantic Versioning Rules](https://semver.org), but note you don't need
48+
to use the same version as GRDB. Examples:
49+
50+
* Upstream GRDB 5.6.0, after merge -> 5.12.0
51+
* This project 1.0.0 -> 1.1.0
52+
53+
* Upstream GRDB 5.12.0, after merge -> 6.0.0
54+
* This project 1.1.0 -> 2.0.0
55+
56+
If everything looks fine:
57+
* push your branch,
58+
* create PR for BSK referencing the new branch,
59+
* create PRs for iOS and macOS apps referencing your BSK branch.
60+
61+
Once approved:
62+
* merge your branch back to `SQLCipher`,
63+
* create a tag matching the release number **without the 'v' prefix** (those are reserved for upstream),
64+
* push the tag,
65+
* update the reference to GRDB in BSK to point to a tag.
66+
67+
### Compiling SQLCipher manually
68+
69+
In case `prepare_release.sh` script fails, you need to compile SQLCipher amalgamation package
70+
manually. See [general instructions](https://github.com/sqlcipher/sqlcipher#compiling-for-unix-like-systems):
71+
72+
* Use `./configure --with-crypto-lib=none`.
73+
* Remember to use `make sqlite3.c` and not `make`.
74+
* Copy `sqlite3.c` and `sqlite3.h` to `Sources/SQLCipher/sqlite3.c` and `Sources/SQLCipher/include/sqlite3.h`.
75+
76+
--
77+
178
<picture>
279
<source media="(prefers-color-scheme: dark)" srcset="https://raw.githubusercontent.com/groue/GRDB.swift/master/GRDB~dark.png">
380
<source media="(prefers-color-scheme: light)" srcset="https://raw.githubusercontent.com/groue/GRDB.swift/master/GRDB.png">

0 commit comments

Comments
 (0)