Remove dhall-haskell dependency
This commit is contained in:
parent
e0c8dfed3e
commit
8c2aafed45
19
flake.lock
19
flake.lock
|
@ -1,24 +1,5 @@
|
||||||
{
|
{
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"dhall-haskell": {
|
|
||||||
"inputs": {
|
|
||||||
"nixpkgs": {
|
|
||||||
"inputs": {},
|
|
||||||
"narHash": "sha256-wJg4DA700SoQbEz61448sR6BgxRa1R92K3vvCV1g+HY=",
|
|
||||||
"originalUrl": "git+https://github.com/nixos/nixpkgs.git?ref=18.09-beta&rev=1d4de0d552ae9aa66a5b8dee5fb0650a4372d148",
|
|
||||||
"url": "git+https://github.com/nixos/nixpkgs.git?ref=18.09-beta&rev=1d4de0d552ae9aa66a5b8dee5fb0650a4372d148"
|
|
||||||
},
|
|
||||||
"nixpkgsStaticLinux": {
|
|
||||||
"inputs": {},
|
|
||||||
"narHash": "sha256-famU3pJZ4vkElV9qc71HmyRVSvcrAhfMZ0UJKpmmKP8=",
|
|
||||||
"originalUrl": "git+https://github.com/nh2/nixpkgs.git?ref=static-haskell-nix-stack-dhall-working",
|
|
||||||
"url": "git+https://github.com/nh2/nixpkgs.git?ref=static-haskell-nix-stack-dhall-working&rev=925aac04f4ca58aceb83beef18cb7dae0715421b"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"narHash": "sha256-KJl9ZLcMcEsLSPcwcWoc0Ac74/6HKC9LkVMeLwhyhlg=",
|
|
||||||
"originalUrl": "git+https://github.com/dhall-lang/dhall-haskell?ref=flake",
|
|
||||||
"url": "git+https://github.com/dhall-lang/dhall-haskell?ref=flake&rev=aea28adf3d10ff1982aa4ddd176d1476251b932f"
|
|
||||||
},
|
|
||||||
"nixpkgs": {
|
"nixpkgs": {
|
||||||
"inputs": {},
|
"inputs": {},
|
||||||
"narHash": "sha256-NB+H7zK3BB//zM127FqgbG4iAfY+nS/IOyO+uGWA5Ho=",
|
"narHash": "sha256-NB+H7zK3BB//zM127FqgbG4iAfY+nS/IOyO+uGWA5Ho=",
|
||||||
|
|
29
flake.nix
29
flake.nix
|
@ -3,10 +3,7 @@
|
||||||
|
|
||||||
edition = 201909;
|
edition = 201909;
|
||||||
|
|
||||||
inputs.dhall-haskell.uri =
|
outputs = { self, nixpkgs }:
|
||||||
"git+https://github.com/dhall-lang/dhall-haskell?ref=flake";
|
|
||||||
|
|
||||||
outputs = { self, nixpkgs, dhall-haskell }:
|
|
||||||
let
|
let
|
||||||
localSystem = "x86_64-linux";
|
localSystem = "x86_64-linux";
|
||||||
localPackages = nixpkgs.legacyPackages.${localSystem};
|
localPackages = nixpkgs.legacyPackages.${localSystem};
|
||||||
|
@ -25,7 +22,6 @@
|
||||||
};
|
};
|
||||||
dontConfigure = true;
|
dontConfigure = true;
|
||||||
dontBuild = true;
|
dontBuild = true;
|
||||||
buildInputs = [ dhall-haskell.packages.${localSystem}.dhall ];
|
|
||||||
installPhase = ''
|
installPhase = ''
|
||||||
find . -type f | while read FILE; do
|
find . -type f | while read FILE; do
|
||||||
case $FILE in
|
case $FILE in
|
||||||
|
@ -37,26 +33,25 @@
|
||||||
done
|
done
|
||||||
|
|
||||||
local drv=$out
|
local drv=$out
|
||||||
echo '{' >> manifest.tmp
|
echo -n '{' >> $manifest
|
||||||
if [ -d $drv/bin ]; then
|
if [ -d $drv/bin ]; then
|
||||||
echo ', bin = {' >> manifest.tmp
|
echo -n ',bin={' >> $manifest
|
||||||
find $drv/bin/ -type f -printf ', %f = { mapKey = "%f", mapValue = "%p" }\n' >> manifest.tmp
|
find $drv/bin/ -type f -printf ',%f={mapKey="%f",mapValue="%p"}\n' >> $manifest
|
||||||
echo '}' >> manifest.tmp
|
echo -n '}' >> $manifest
|
||||||
fi
|
fi
|
||||||
if [ -d $drv/lib ]; then
|
if [ -d $drv/lib ]; then
|
||||||
echo ', lib = {' >> manifest.tmp
|
echo -n ',lib={' >> $manifest
|
||||||
find $drv/lib/ -type f -name '*.lib.so' -printf '%f "%p"\n' \
|
find $drv/lib/ -type f -name '*.lib.so' -printf '%f "%p"\n' \
|
||||||
| awk '{print ", "gensub(/.lib.so/, "", 1, $1)" = { mapKey = \""$1"\", mapValue = "$2" }" }'>> manifest.tmp
|
| awk '{print ","gensub(/.lib.so/, "", 1, $1)"={mapKey=\""$1"\",mapValue="$2" }"}'>> $manifest
|
||||||
echo '}' >> manifest.tmp
|
echo -n '}' >> $manifest
|
||||||
fi
|
fi
|
||||||
if [ -d $drv/tar ]; then
|
if [ -d $drv/tar ]; then
|
||||||
echo ', tar = {' >> manifest.tmp
|
echo -n ',tar={' >> $manifest
|
||||||
find $drv/tar/ -type f -name '*.tar' -printf '%f "%p"\n' \
|
find $drv/tar/ -type f -name '*.tar' -printf '%f "%p"\n' \
|
||||||
| awk '{print ""gensub(/.tar/, "", 1, $1)" = { mapKey = \""$1"\", mapValue = "$2" }" }'>> manifest.tmp
|
| awk '{print ""gensub(/.tar/, "", 1, $1)"={mapKey=\""$1"\",mapValue="$2"}"}'>> $manifest
|
||||||
echo '}' >> manifest.tmp
|
echo -n '}' >> $manifest
|
||||||
fi
|
fi
|
||||||
echo '}' >> manifest.tmp
|
echo '}' >> $manifest
|
||||||
dhall < manifest.tmp > $manifest
|
|
||||||
'';
|
'';
|
||||||
meta = {
|
meta = {
|
||||||
license = [ "LicenseRef-Genode" ];
|
license = [ "LicenseRef-Genode" ];
|
||||||
|
|
Loading…
Reference in New Issue