-
Notifications
You must be signed in to change notification settings - Fork 129
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
Clean rocksdb on make update. #2347
Conversation
This won't catch manual updates to rocksdb - ie if I manually switch to a different nim-rocksdb commit, rocksdb should be automatically rebuilt (because the library it build previously is no longer valid) |
Are there any examples in the codebase that do something similar to what you are suggesting? Just thinking through the best way to implement that. |
nim-nat-traversal maybe |
basically, every time we build, we should run make in that folder in a way where rocksdb updates itself - the situation is the same as running make after switching checkouts in rocksdb manually, I'm sure they have some instructions for that .. |
and regarding cleaning, the ideal would be that after building the library (librocksdb.*), we would remove all intermediate |
Doing this is problematic at the moment because if I do a clean after building and copying the libraries then next time it will trigger another full rebuild which is very slow. I might need to redo/rewrite the nim-rocksdb build system to use a proper Makefile so that it can be smarter. Currently its just using a few build scripts. |
yeah, possible - though I'd be a bit surprised if the Makefile that rocksdb ships can't deal with this, seems like a basic thing .. |
Well it does do the usual stuff like if files have changed then it will do a rebuild of the artifact. What it doesn't do is automatically do a clean if you update the files. The problem you ran into was that rocksdb was doing a rebuild as it should have because the files had changed but the build failed because the rocksdb version had changed and likely some src files removed or added etc between versions. I'll need to somehow look at the git submodule status or something and if it changes then run the clean script to force the full rebuild. |
oh weird, sounds like a bug to report to them.. ie if I switch tags in their checkout, they should rebuild their deps automatically. |
Actually if I switch from using the RocksDb Makefile to using vcpkg to build the static libraries, that might fix this problem. |
Clean rocksdb on
make update
so that if rocksdb has been updated to a newer version, when runningmake nimbus
rocksdb will be completely rebuilt from source.