Static linking part 2
This commit is contained in:
parent
ad1918aa6f
commit
fccee3e61c
44
flake.lock
generated
44
flake.lock
generated
@ -18,25 +18,55 @@
|
|||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
"nh2pkgs": {
|
||||||
|
"flake": false,
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1718490232,
|
||||||
|
"narHash": "sha256-0Fh3aJZuTJVmiiKY/5SyvHlfhZ3HeZTDUQnd+Fx6/Qo=",
|
||||||
|
"type": "tarball",
|
||||||
|
"url": "https://github.com/nh2/nixpkgs/archive/ede5282c487a1fd2de64303ba59adad6726f1225.tar.gz"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"type": "tarball",
|
||||||
|
"url": "https://github.com/nh2/nixpkgs/archive/ede5282c487a1fd2de64303ba59adad6726f1225.tar.gz"
|
||||||
|
}
|
||||||
|
},
|
||||||
"nixpkgs": {
|
"nixpkgs": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1734566935,
|
"lastModified": 1738797219,
|
||||||
"narHash": "sha256-cnBItmSwoH132tH3D4jxmMLVmk8G5VJ6q/SC3kszv9E=",
|
"narHash": "sha256-KRwX9Z1XavpgeSDVM/THdFd6uH8rNm/6R+7kIbGa+2s=",
|
||||||
"owner": "NixOS",
|
"owner": "NixOS",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "087408a407440892c1b00d80360fd64639b8091d",
|
"rev": "1da52dd49a127ad74486b135898da2cef8c62665",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
"owner": "NixOS",
|
"id": "nixpkgs",
|
||||||
"repo": "nixpkgs",
|
"type": "indirect"
|
||||||
"type": "github"
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"root": {
|
"root": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"flake-utils": "flake-utils",
|
"flake-utils": "flake-utils",
|
||||||
"nixpkgs": "nixpkgs"
|
"nh2pkgs": "nh2pkgs",
|
||||||
|
"nixpkgs": "nixpkgs",
|
||||||
|
"static-haskell-nix": "static-haskell-nix"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"static-haskell-nix": {
|
||||||
|
"flake": false,
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1718492291,
|
||||||
|
"narHash": "sha256-XbBHPJk3ln+uLW+Dsio7vJNYnsHhmqenbI7cLsP8kHg=",
|
||||||
|
"owner": "nh2",
|
||||||
|
"repo": "static-haskell-nix",
|
||||||
|
"rev": "481e7d73ca624278ef0f840a0a2ba09e3a583217",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "nh2",
|
||||||
|
"repo": "static-haskell-nix",
|
||||||
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"systems": {
|
"systems": {
|
||||||
|
61
flake.nix
61
flake.nix
@ -2,7 +2,7 @@
|
|||||||
description = "tricu";
|
description = "tricu";
|
||||||
|
|
||||||
inputs = {
|
inputs = {
|
||||||
nixpkgs = {
|
nh2pkgs = {
|
||||||
url = "https://github.com/nh2/nixpkgs/archive/ede5282c487a1fd2de64303ba59adad6726f1225.tar.gz";
|
url = "https://github.com/nh2/nixpkgs/archive/ede5282c487a1fd2de64303ba59adad6726f1225.tar.gz";
|
||||||
type = "tarball";
|
type = "tarball";
|
||||||
flake = false;
|
flake = false;
|
||||||
@ -11,48 +11,47 @@
|
|||||||
url = "github:nh2/static-haskell-nix";
|
url = "github:nh2/static-haskell-nix";
|
||||||
flake = false;
|
flake = false;
|
||||||
};
|
};
|
||||||
|
flake-utils.url = "github:numtide/flake-utils";
|
||||||
};
|
};
|
||||||
|
|
||||||
outputs = { self, nixpkgs, static-haskell-nix }:
|
outputs = { self, flake-utils, nh2pkgs, nixpkgs, static-haskell-nix }:
|
||||||
let
|
flake-utils.lib.eachDefaultSystem (system:
|
||||||
system = "x86_64-linux";
|
let
|
||||||
compiler = "ghc948";
|
compiler = "ghc948";
|
||||||
packageName = "tricu";
|
packageName = "tricu";
|
||||||
|
|
||||||
overlay = self: super: {
|
overlay = self: super: {
|
||||||
haskell = super.haskell // {
|
haskell = super.haskell // {
|
||||||
packages = super.haskell.packages // {
|
packages = super.haskell.packages // {
|
||||||
${compiler} = super.haskell.packages.${compiler}.override {
|
${compiler} = super.haskell.packages.${compiler}.override {
|
||||||
overrides = final: prev: {
|
overrides = final: prev: {
|
||||||
${packageName} = prev.callCabal2nix packageName ./. {};
|
${packageName} = prev.callCabal2nix packageName ./. {};
|
||||||
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
|
||||||
|
|
||||||
overlays = [overlay];
|
overlays = [overlay];
|
||||||
|
|
||||||
normalPkgs = import nixpkgs { inherit overlays system; };
|
pkgs = import nh2pkgs { inherit overlays system; };
|
||||||
|
|
||||||
survey = import "${static-haskell-nix}/survey" { inherit compiler normalPkgs; };
|
survey = import "${static-haskell-nix}/survey" { inherit compiler pkgs; };
|
||||||
|
|
||||||
tricuStatic = survey.haskellPackages.${packageName};
|
tricuStatic = survey.haskellPackages.${packageName};
|
||||||
|
|
||||||
in {
|
in {
|
||||||
packages.${system}.default = tricuStatic;
|
packages.default = tricuStatic;
|
||||||
|
|
||||||
devShells.default = normalPkgs.mkShell {
|
devShells.default = pkgs.mkShell {
|
||||||
buildInputs = with normalPkgs; [
|
buildInputs = with survey; [
|
||||||
normalPkgs.haskellPackages.cabal-install
|
haskellPackages.cabal-install
|
||||||
normalPkgs.haskellPackages.ghc-events
|
haskellPackages.ghc-events
|
||||||
normalPkgs.haskellPackages.ghcid
|
haskellPackages.ghcid
|
||||||
normalPkgs.upx
|
] ++ [pkgs.upx];
|
||||||
];
|
inputsFrom = builtins.attrValues self.packages.${system};
|
||||||
inputsFrom = builtins.attrValues self.packages.${system};
|
};
|
||||||
};
|
devShell = self.devShells.${system}.default;
|
||||||
|
});
|
||||||
devShell = self.devShells.${system}.default;
|
|
||||||
};
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
cabal-version: 1.12
|
cabal-version: 1.12
|
||||||
|
|
||||||
name: tricu
|
name: tricu
|
||||||
version: 0.18.0
|
version: 0.18.1
|
||||||
description: A micro-language for exploring Tree Calculus
|
description: A micro-language for exploring Tree Calculus
|
||||||
author: James Eversole
|
author: James Eversole
|
||||||
maintainer: james@eversole.co
|
maintainer: james@eversole.co
|
||||||
|
Loading…
x
Reference in New Issue
Block a user