Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MacOS support #71

Open
anacrolix opened this issue Sep 25, 2022 · 2 comments
Open

MacOS support #71

anacrolix opened this issue Sep 25, 2022 · 2 comments
Labels
enhancement New feature or request

Comments

@anacrolix
Copy link

I had some trouble trying this on MacOS. Creating a namespace would hang (not sure if this is MacOS specific). Running sqlite3 with DYLD_INSERT_LIBRARIES didn't seem to interpose correctly, sqlite3 would still operate on the local file test. There are some tweaks to compiler and linker flags in spots that were necessary, I can contribute some of those back if it's of interest.

@losfair
Copy link
Owner

losfair commented Sep 26, 2022

Thanks for trying mvsqlite on macOS!

Creating a namespace would hang

mvstore needs to be started with the --cluster /usr/local/etc/foundationdb/fdb.cluster argument. Currently the default value is hardcoded to /etc/foundationdb/fdb.cluster but it's different on macOS.

Running sqlite3 with DYLD_INSERT_LIBRARIES didn't seem to interpose correctly, sqlite3 would still operate on the local file test.

Is the sqlite3 binary compiled with dynamically linked libsqlite3?

@losfair losfair added the enhancement New feature or request label Sep 26, 2022
@anacrolix
Copy link
Author

mvstore needs to be started with the --cluster /usr/local/etc/foundationdb/fdb.cluster argument. Currently the default value is hardcoded to /etc/foundationdb/fdb.cluster but it's different on macOS.

I did do that, it suddenly succeeded when I gave up, possibly while shutting the server down. I'll report back but I think it's operator error for now.

Running sqlite3 with DYLD_INSERT_LIBRARIES didn't seem to interpose correctly, sqlite3 would still operate on the local file test.

Is the sqlite3 binary compiled with dynamically linked libsqlite3?

MacOS' equivalent I think:

$ otool -L sqlite3
sqlite3:
	libsqlite3.so (compatibility version 0.0.0, current version 0.0.0)
	/usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1311.100.3)

There's probably a lot of user error here, but it may help others who are trying too.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants