mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-02-23 12:34:15 +00:00
autoPatchelfHook: Make Linux-exclusive
After being rewritten in https://github.com/NixOS/nixpkgs/pull/149731, this hook can fail on Mach-O binaries. Since patching ELF files on Darwin doesn't make much sense anyway, we'll mark this as Linux-exclusive.
This commit is contained in:
parent
80180c339e
commit
48034046bf
@ -516,15 +516,19 @@ rec {
|
||||
* # setup hook that depends on the hello package and runs ./myscript.sh
|
||||
* myhellohook = makeSetupHook { deps = [ hello ]; } ./myscript.sh;
|
||||
*
|
||||
* # wrotes a setup hook where @bash@ myscript.sh is substituted for the
|
||||
* # writes a Linux-exclusive setup hook where @bash@ myscript.sh is substituted for the
|
||||
* # bash interpreter.
|
||||
* myhellohookSub = makeSetupHook {
|
||||
* deps = [ hello ];
|
||||
* substitutions = { bash = "${pkgs.bash}/bin/bash"; };
|
||||
* meta.platforms = lib.platforms.linux;
|
||||
* } ./myscript.sh;
|
||||
*/
|
||||
makeSetupHook = { name ? "hook", deps ? [], substitutions ? {} }: script:
|
||||
runCommand name substitutions
|
||||
makeSetupHook = { name ? "hook", deps ? [], substitutions ? {}, meta ? {} }: script:
|
||||
runCommand name
|
||||
(substitutions // {
|
||||
inherit meta;
|
||||
})
|
||||
(''
|
||||
mkdir -p $out/nix-support
|
||||
cp ${script} $out/nix-support/setup-hook
|
||||
|
@ -154,6 +154,7 @@ with pkgs;
|
||||
pythonInterpreter = "${python3.withPackages (ps: [ ps.pyelftools ])}/bin/python";
|
||||
autoPatchelfScript = ../build-support/setup-hooks/auto-patchelf.py;
|
||||
};
|
||||
meta.platforms = lib.platforms.linux;
|
||||
} ../build-support/setup-hooks/auto-patchelf.sh;
|
||||
|
||||
appflowy = callPackage ../applications/office/appflowy { };
|
||||
|
Loading…
Reference in New Issue
Block a user