Skip to content

Commit

Permalink
Add cardano-node-8.9.1-aarch64-linux.tar.gz for E2E tests
Browse files Browse the repository at this point in the history
  • Loading branch information
michalrus committed Apr 3, 2024
1 parent 00630d6 commit feffa02
Show file tree
Hide file tree
Showing 2 changed files with 38 additions and 0 deletions.
13 changes: 13 additions & 0 deletions native-arm/cardano-node-8.9.1--expose-projectExes.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
diff --git a/flake.nix b/flake.nix
index 0804d9ff3..64362d27d 100644
--- a/flake.nix
+++ b/flake.nix
@@ -305,6 +305,8 @@
internal.roots.project = windowsProject.roots;
variants = mapAttrs (_: v: removeAttrs v.windows ["variants"]) ciJobsVariants;
});
+ } // optionalAttrs (system == "aarch64-linux") {
+ linux-arm64.projectExes = collectExes project;
} // optionalAttrs (system == "x86_64-darwin") {
native = lib.filterAttrs
(n: _:
25 changes: 25 additions & 0 deletions native-arm/flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -556,6 +556,10 @@
original = inputs.${input};
supportedSystemsPath = "nix/supported-systems.nix";
extraPatch = ''
(
cd $out
patch -p1 -i ${./cardano-node-8.9.1--expose-projectExes.patch}
)
sed -r '
s/"ghc8107"/"ghc963"/g
s/"-fexternal-interpreter"//g
Expand All @@ -569,6 +573,27 @@
# { name = "${input}--cardano-submit-api"; value = theFlake.packages.${system}.cardano-submit-api; }
{ name = "${input}--oci"; value = retagOCI "cardano-node" version theFlake.legacyPackages.${system}.dockerImage; }
{ name = "${input}--oci-submit-api"; value = retagOCI "cardano-submit-api" version theFlake.legacyPackages.${system}.submitApiDockerImage; }
{
name = "${input}--tar";
value = let
pkgs = theFlake.inputs.nixpkgs.legacyPackages.${system};
nix-bundle-exe-with-symlinks = pkgs.runCommand "nix-bundle-exe-with-symlinks" {} ''
cp -r ${inputs.nix-bundle-exe} $out
chmod -R +w $out
sed -r "s/find '/find -L '/g" -i $out/default.nix
'';
nix-bundle-exe = import nix-bundle-exe-with-symlinks { pkgs = pkgs; };
allExes = pkgs.buildEnv {
name = "cardano-tools";
paths = builtins.attrValues theFlake.hydraJobs.${system}.linux-arm64.projectExes;
pathsToLink = ["/bin"];
};
bundle = nix-bundle-exe allExes;
in pkgs.runCommand "${bundle.name}-tar" {} ''
mkdir -p $out
tar -czvf $out/cardano-node-${version}-${system}.tar.gz -C ${bundle} .
'';
}
])

);
Expand Down

0 comments on commit feffa02

Please sign in to comment.