edencommon: use sanitiseHeaderPathsHook

This commit is contained in:
Emily
2025-07-04 12:02:26 +01:00
parent 17d4441a42
commit 034f0298f4
+2 -14
View File
@@ -6,7 +6,7 @@
cmake,
ninja,
removeReferencesTo,
sanitiseHeaderPathsHook,
glog,
gflags,
@@ -47,7 +47,7 @@ stdenv.mkDerivation (finalAttrs: {
nativeBuildInputs = [
cmake
ninja
removeReferencesTo
sanitiseHeaderPathsHook
];
buildInputs = [
@@ -98,18 +98,6 @@ stdenv.mkDerivation (finalAttrs: {
'find_package(FBThrift CONFIG REQUIRED COMPONENTS cpp2)'
'';
postFixup = ''
# Sanitize header paths to avoid runtime dependencies leaking in
# through `__FILE__`.
(
shopt -s globstar
for header in "$dev/include"/**/*.h; do
sed -i "1i#line 1 \"$header\"" "$header"
remove-references-to -t "$dev" "$header"
done
)
'';
passthru.updateScript = nix-update-script { };
meta = {