Skip to content

Conversation

@0x2E
Copy link
Owner

@0x2E 0x2E commented Dec 23, 2024

The current SQLite driver uses CGO, which makes cross-compilation and static build (#36) difficult. The new CGO-free driver is slower, but it's fine for small projects.

Context:

@mtlynch
Copy link
Collaborator

mtlynch commented Dec 23, 2024

@0x2E - Cool, yes that works! I tested a merge of the two here and it builds successfully on NixOS:

https://github.com/mtlynch/fusion/tree/static-build-no-cgo

I'm happy to see CGO go away, but another alternative is that we could adjust scripts.sh to only do static linking on non-Darwin systems.

@0x2E
Copy link
Owner Author

0x2E commented Dec 24, 2024

Thanks for the testing.

we could adjust scripts.sh to only do static linking on non-Darwin systems.

CGO also makes cross-compiling CI tough, so let's fix it all in one go.

@0x2E 0x2E merged commit 4d2c0e2 into main Dec 24, 2024
1 check passed
@0x2E 0x2E deleted the cgo-free-sqlite branch March 2, 2025 15:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants