From 9c76b1793323e9a9cc673f3269aaa3be0580e58f Mon Sep 17 00:00:00 2001 From: Jonathan del Strother Date: Sun, 11 Apr 2021 12:50:09 +0100 Subject: [PATCH] mysql: fix building on Apple Silicon rpcsvc-proto doesn't build for aarch64-darwin (`struct stat64` isn't declared), but it isn't actually necessary on Darwin/clang. --- pkgs/servers/sql/mysql/5.7.x.nix | 3 ++- pkgs/servers/sql/mysql/8.0.x.nix | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/pkgs/servers/sql/mysql/5.7.x.nix b/pkgs/servers/sql/mysql/5.7.x.nix index 547900932153..36e26d38fc48 100644 --- a/pkgs/servers/sql/mysql/5.7.x.nix +++ b/pkgs/servers/sql/mysql/5.7.x.nix @@ -21,7 +21,8 @@ self = stdenv.mkDerivation rec { export PATH=$PATH:$TMPDIR ''; - nativeBuildInputs = [ cmake bison pkg-config rpcsvc-proto ]; + nativeBuildInputs = [ bison cmake pkg-config ] + ++ lib.optionals (!stdenv.isDarwin) [ rpcsvc-proto ]; buildInputs = [ boost libedit libevent lz4 ncurses openssl protobuf readline zlib ] ++ lib.optionals stdenv.isDarwin [ perl cctools CoreServices developer_cmds ] diff --git a/pkgs/servers/sql/mysql/8.0.x.nix b/pkgs/servers/sql/mysql/8.0.x.nix index 3dbd84c2a984..cdbfdaea7adf 100644 --- a/pkgs/servers/sql/mysql/8.0.x.nix +++ b/pkgs/servers/sql/mysql/8.0.x.nix @@ -17,7 +17,8 @@ self = stdenv.mkDerivation rec { ./abi-check.patch ]; - nativeBuildInputs = [ bison cmake pkg-config rpcsvc-proto ]; + nativeBuildInputs = [ bison cmake pkg-config ] + ++ lib.optionals (!stdenv.isDarwin) [ rpcsvc-proto ]; ## NOTE: MySQL upstream frequently twiddles the invocations of libtool. When updating, you might proactively grep for libtool references. postPatch = ''