Skip to content

Commit

Permalink
Build s390x binaries using musl libc
Browse files Browse the repository at this point in the history
Building using musl until NixOS/nixpkgs#306473
is resolved.

Signed-off-by: Sascha Grunert <sgrunert@redhat.com>
  • Loading branch information
saschagrunert committed Apr 24, 2024
1 parent 944404a commit 12d791e
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 3 deletions.
5 changes: 4 additions & 1 deletion nix/default-s390x.nix
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
(import ./nixpkgs.nix {
crossSystem = {
config = "s390x-unknown-linux-gnu";
# TODO: Switch back to glibc when
# https://github.com/cri-o/cri-o/issues/7911
# is resolved.
config = "s390x-unknown-linux-musl";
};
overlays = [ (import ./overlay.nix) ];
}).callPackage ./derivation.nix
Expand Down
7 changes: 5 additions & 2 deletions nix/derivation.nix
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
{ pkgs }:
{ stdenv
, pkgs
}:
with pkgs; buildGo122Module {
name = "cri-o";
src = ./..;
Expand All @@ -15,9 +17,10 @@ with pkgs; buildGo122Module {
pkg-config
which
];
buildInputs = [
buildInputs = lib.optionals (!stdenv.hostPlatform.isMusl) [
glibc
glibc.static
] ++ [
gpgme
libassuan
libgpgerror
Expand Down

0 comments on commit 12d791e

Please sign in to comment.