mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-22 15:03:28 +00:00
osquery: remove workaround for autoPatchelfHook problem (#343084)
This commit is contained in:
commit
83bc01a59c
@ -14,7 +14,6 @@
|
||||
, jq
|
||||
, removeReferencesTo
|
||||
, nixosTests
|
||||
, file
|
||||
, writers
|
||||
}:
|
||||
|
||||
@ -24,7 +23,7 @@ let
|
||||
|
||||
opensslSrc = fetchurl info.openssl;
|
||||
|
||||
toolchain = import ./toolchain-bin.nix { inherit stdenv lib fetchzip file; };
|
||||
toolchain = import ./toolchain-bin.nix { inherit stdenv lib fetchzip autoPatchelfHook; };
|
||||
|
||||
in
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
{ stdenv, lib, fetchzip, file }:
|
||||
{ stdenv, lib, fetchzip, autoPatchelfHook }:
|
||||
let
|
||||
|
||||
version = "1.1.0";
|
||||
@ -24,24 +24,13 @@ stdenv.mkDerivation {
|
||||
|
||||
src = fetchzip dist.${stdenv.hostPlatform.system};
|
||||
|
||||
nativeBuildInputs = [ file ];
|
||||
nativeBuildInputs = [ autoPatchelfHook ];
|
||||
|
||||
installPhase = ''
|
||||
mkdir $out
|
||||
cp -r * $out
|
||||
'';
|
||||
|
||||
# autoPatchelfHook cannot be used here because of https://github.com/NixOS/nixpkgs/issues/333710
|
||||
postFixup = ''
|
||||
read -r interpreter < "$NIX_BINTOOLS"/nix-support/dynamic-linker
|
||||
for file in $(find "$out"/usr/bin -type f -executable); do
|
||||
if [[ $(file "$file") == *ELF*dynamically* ]]; then
|
||||
patchelf --interpreter "$interpreter" "$file"
|
||||
patchelf --set-rpath "$out/usr/lib" "$file"
|
||||
fi
|
||||
done
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
description = "A LLVM-based toolchain for Linux designed to build a portable osquery";
|
||||
homepage = "https://github.com/osquery/osquery-toolchain";
|
||||
|
Loading…
Reference in New Issue
Block a user