style: Run statix

This commit is contained in:
Shuroii 2025-07-03 13:11:47 +02:00 committed by Jade Ellis
commit 6289bcaabc
No known key found for this signature in database
GPG key ID: 8705A2A3EBF77BD2
3 changed files with 8 additions and 17 deletions

View file

@ -13,12 +13,7 @@ lib.optionalAttrs stdenv.hostPlatform.isStatic
CARGO_BUILD_RUSTFLAGS =
lib.concatStringsSep
" "
([ ]
# This disables PIE for static builds, which isn't great in terms
# of security. Unfortunately, my hand is forced because nixpkgs'
# `libstdc++.a` is built without `-fPIE`, which precludes us from
# leaving PIE enabled.
++ lib.optionals
(lib.optionals
stdenv.hostPlatform.isStatic
[ "-C" "relocation-model=static" ]
++ lib.optionals

View file

@ -93,16 +93,16 @@ let
# for some reason enableLiburing in nixpkgs rocksdb is default true
# which breaks Darwin entirely
enableLiburing = enableLiburing;
inherit enableLiburing;
}).overrideAttrs (old: {
enableLiburing = enableLiburing;
inherit enableLiburing;
cmakeFlags = (if x86_64_haswell_target_optimised then
(lib.subtractLists [
# dont make a portable build if x86_64_haswell_target_optimised is enabled
"-DPORTABLE=1"
]
old.cmakeFlags
++ [ "-DPORTABLE=haswell" ]) else ([ "-DPORTABLE=1" ])
++ [ "-DPORTABLE=haswell" ]) else [ "-DPORTABLE=1" ]
)
++ old.cmakeFlags;