build: correct lmdb static builds

This commit is contained in:
Brendan Hay 2021-12-08 16:08:37 +01:00
parent d9ba577721
commit 4f1acce662
No known key found for this signature in database
GPG Key ID: 80E915C54A7C457D
3 changed files with 4 additions and 8 deletions

View File

@ -105,7 +105,7 @@ let
# Additional top-level packages and attributes exposed for convenience.
pkgsExtra = with pkgsLocal; rec {
# Expose packages with local customisations (like patches) for dev access.
inherit (pkgsCross) libsigsegv;
inherit (pkgsStatic) libsigsegv lmdb;
urbit-debug = urbit.override { enableDebug = true; };
urbit-tests = libLocal.testFakeShip {

View File

@ -24,5 +24,5 @@ in prev.lib.optionalAttrs isMusl {
numactl = overrideStdenv prev.numactl;
lmdb = overrideStdenv prev.lmdb;
# lmdb = overrideStdenv prev.lmdb;
}

View File

@ -26,12 +26,8 @@ in {
lmdb = prev.lmdb.overrideAttrs (old:
configureFlags old // {
# Why remove the so version? It's easier than preventing it from being
# built with lmdb's custom Makefiles, and it can't exist in the output
# because otherwise the linker will preferentially choose the .so over
# the .a.
postInstall = ''
rm $out/lib/liblmdb.so
postPatch = ''
sed '/^ILIBS\t/s/liblmdb\$(SOEXT)//' -i Makefile
'';
});
}