-
-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* bump lief to most recent main (3414ded8cdcbd9705f7871c66c212b15cd74ea69) * created new nix directory and moved overlay there * had to copy lief derivation from nixpkg for now since lief changed how it is built.
- Loading branch information
Showing
5 changed files
with
54 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
{ poetry2nix, poetryOverrides }: | ||
poetry2nix.mkPoetryApplication { | ||
projectDir = ./.; | ||
projectDir = ../.; | ||
overrides = poetry2nix.overrides.withDefaults poetryOverrides; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
# This is an unreleased version of Lief that fixes a bug when generates GNU notes | ||
# https://github.com/lief-project/LIEF/commit/3414ded8cdcbd9705f7871c66c212b15cd74ea69 | ||
# Nixpkgs derivation was updated to change how lief was built since it no longer has setup.py | ||
# in the root of the directory. | ||
# For now, we copy the derivation until it's merged into nixpkgs we are tracking. | ||
# https://github.com/NixOS/nixpkgs/pull/251414 | ||
{ fetchFromGitHub, python, stdenv, cmake, ninja }: | ||
let | ||
pyEnv = python.withPackages (ps: [ ps.setuptools ps.tomli ps.pip ps.setuptools ]); | ||
in | ||
stdenv.mkDerivation rec { | ||
pname = "lief"; | ||
version = "0.14.0-3414ded"; | ||
src = fetchFromGitHub { | ||
owner = "lief-project"; | ||
repo = "LIEF"; | ||
rev = "3414ded8cdcbd9705f7871c66c212b15cd74ea69"; | ||
sha256 = "sha256-GJTj4w8HhAiC2bQAjEIqPw9feaOHL4fmAfLACioW0Q0="; | ||
}; | ||
outputs = [ "out" "py" ]; | ||
|
||
nativeBuildInputs = [ | ||
cmake | ||
ninja | ||
]; | ||
|
||
# Not a propagatedBuildInput because only the $py output needs it; $out is | ||
# just the library itself (e.g. C/C++ headers). | ||
buildInputs = [ | ||
python | ||
]; | ||
|
||
postBuild = '' | ||
pushd /build/source/api/python | ||
${pyEnv.interpreter} setup.py build --parallel=$NIX_BUILD_CORES | ||
popd | ||
''; | ||
|
||
postInstall = '' | ||
pushd /build/source/api/python | ||
${pyEnv.interpreter} setup.py install --skip-build --root=/ --prefix=$py | ||
popd | ||
''; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters