add build for ofborg-simple-build
This commit is contained in:
parent
96639e9d7e
commit
40c759e027
17
default.nix
17
default.nix
|
@ -1,20 +1,13 @@
|
|||
{ pkgs ? import ./nix { overlays = [ (import ./nix/overlay.nix) ]; } }:
|
||||
|
||||
let
|
||||
ofborgOverrides = {
|
||||
crateOverrides = pkgs.defaultCrateOverrides // {
|
||||
ofborg = attrs: {
|
||||
buildInputs = pkgs.lib.optional pkgs.stdenv.isDarwin
|
||||
pkgs.darwin.apple_sdk.frameworks.Security;
|
||||
};
|
||||
};
|
||||
ofborgCrates = pkgs.callPackage ./Cargo.nix {
|
||||
cratesIO = pkgs.callPackage ./crates-io.nix {};
|
||||
};
|
||||
|
||||
drv = ((pkgs.callPackage ./Cargo.nix {
|
||||
cratesIO = pkgs.callPackage ./crates-io.nix {};
|
||||
}).ofborg {}).override { release = false; };
|
||||
drv = ofborgCrates.ofborg {};
|
||||
|
||||
src = stripDeps (drv.override ofborgOverrides);
|
||||
src = stripDeps (drv.override { release = false; });
|
||||
|
||||
stripDeps = pkg: pkgs.runCommand "${pkg.name}-deps-stripped" {}
|
||||
''
|
||||
|
@ -27,6 +20,8 @@ let
|
|||
in
|
||||
|
||||
{
|
||||
ofborg.simple-build = ofborgCrates.ofborg_simple_build {};
|
||||
|
||||
ofborg.rs = pkgs.runCommand "ofborg-rs-symlink-compat" { inherit src; } ''
|
||||
mkdir -p $out/bin
|
||||
for f in $(find $src -type f); do
|
||||
|
|
|
@ -1,5 +1,14 @@
|
|||
(self: super: {
|
||||
(self: super:
|
||||
{
|
||||
defaultCrateOverrides = super.defaultCrateOverrides // {
|
||||
ofborg = attrs: {
|
||||
buildInputs = with self.darwin.apple_sdk.frameworks;
|
||||
super.lib.optional super.stdenv.isDarwin Security;
|
||||
};
|
||||
ofborg-simple-build = attrs: {
|
||||
buildInputs = with self.darwin.apple_sdk.frameworks;
|
||||
super.lib.optional super.stdenv.isDarwin Security;
|
||||
};
|
||||
openssl-sys = attrs: {
|
||||
buildInputs = [ self.openssl_1_0_2 ];
|
||||
nativeBuildInputs = [ self.pkgconfig ];
|
||||
|
|
Loading…
Reference in a new issue