mysql-shell{,_8,-innovation}: format with nixfmt

This commit is contained in:
Aaron Jheng 2024-11-24 10:45:01 +08:00
parent 9e708b3c14
commit 3e8d408a5e
No known key found for this signature in database
GPG Key ID: F6A547A869D050A3
2 changed files with 144 additions and 110 deletions

View File

@ -1,37 +1,42 @@
{ lib {
, stdenv lib,
, pkg-config stdenv,
, cmake pkg-config,
, fetchurl cmake,
, git fetchurl,
, cctools git,
, darwin cctools,
, makeWrapper darwin,
, bison makeWrapper,
, openssl bison,
, protobuf openssl,
, curl protobuf,
, zlib curl,
, libssh zlib,
, zstd libssh,
, lz4 zstd,
, readline lz4,
, libtirpc readline,
, rpcsvc-proto libtirpc,
, libedit rpcsvc-proto,
, libevent libedit,
, icu libevent,
, re2 icu,
, ncurses re2,
, libfido2 ncurses,
, python3 libfido2,
, cyrus_sasl python3,
, openldap cyrus_sasl,
, antlr openldap,
antlr,
}: }:
let let
pythonDeps = with python3.pkgs; [ certifi paramiko pyyaml ]; pythonDeps = with python3.pkgs; [
certifi
paramiko
pyyaml
];
mysqlShellVersion = "8.4.3"; mysqlShellVersion = "8.4.3";
mysqlServerVersion = "8.4.3"; mysqlServerVersion = "8.4.3";
@ -70,32 +75,44 @@ stdenv.mkDerivation (finalAttrs: {
substituteInPlace cmake/libutils.cmake --replace-fail /usr/bin/libtool libtool substituteInPlace cmake/libutils.cmake --replace-fail /usr/bin/libtool libtool
''; '';
nativeBuildInputs = [ pkg-config cmake git bison makeWrapper ] nativeBuildInputs =
[
pkg-config
cmake
git
bison
makeWrapper
]
++ lib.optionals (!stdenv.hostPlatform.isDarwin) [ rpcsvc-proto ] ++ lib.optionals (!stdenv.hostPlatform.isDarwin) [ rpcsvc-proto ]
++ lib.optionals stdenv.hostPlatform.isDarwin [ cctools darwin.DarwinTools ]; ++ lib.optionals stdenv.hostPlatform.isDarwin [
cctools
darwin.DarwinTools
];
buildInputs = [ buildInputs =
curl [
libedit curl
libssh libedit
lz4 libssh
openssl lz4
protobuf openssl
readline protobuf
zlib readline
zstd zlib
libevent zstd
icu libevent
re2 icu
ncurses re2
libfido2 ncurses
cyrus_sasl libfido2
openldap cyrus_sasl
python3 openldap
antlr.runtime.cpp python3
] ++ pythonDeps antlr.runtime.cpp
++ lib.optionals stdenv.hostPlatform.isLinux [ libtirpc ] ]
++ lib.optionals stdenv.hostPlatform.isDarwin [ darwin.libutil ]; ++ pythonDeps
++ lib.optionals stdenv.hostPlatform.isLinux [ libtirpc ]
++ lib.optionals stdenv.hostPlatform.isDarwin [ darwin.libutil ];
preConfigure = '' preConfigure = ''
# Build MySQL # Build MySQL

View File

@ -1,37 +1,42 @@
{ lib {
, stdenv lib,
, pkg-config stdenv,
, cmake pkg-config,
, fetchurl cmake,
, git fetchurl,
, cctools git,
, darwin cctools,
, makeWrapper darwin,
, bison makeWrapper,
, openssl bison,
, protobuf openssl,
, curl protobuf,
, zlib curl,
, libssh zlib,
, zstd libssh,
, lz4 zstd,
, readline lz4,
, libtirpc readline,
, rpcsvc-proto libtirpc,
, libedit rpcsvc-proto,
, libevent libedit,
, icu libevent,
, re2 icu,
, ncurses re2,
, libfido2 ncurses,
, python3 libfido2,
, cyrus_sasl python3,
, openldap cyrus_sasl,
, antlr openldap,
antlr,
}: }:
let let
pythonDeps = with python3.pkgs; [ certifi paramiko pyyaml ]; pythonDeps = with python3.pkgs; [
certifi
paramiko
pyyaml
];
mysqlShellVersion = "9.1.0"; mysqlShellVersion = "9.1.0";
mysqlServerVersion = "9.1.0"; mysqlServerVersion = "9.1.0";
@ -70,32 +75,44 @@ stdenv.mkDerivation (finalAttrs: {
substituteInPlace cmake/libutils.cmake --replace-fail /usr/bin/libtool libtool substituteInPlace cmake/libutils.cmake --replace-fail /usr/bin/libtool libtool
''; '';
nativeBuildInputs = [ pkg-config cmake git bison makeWrapper ] nativeBuildInputs =
[
pkg-config
cmake
git
bison
makeWrapper
]
++ lib.optionals (!stdenv.hostPlatform.isDarwin) [ rpcsvc-proto ] ++ lib.optionals (!stdenv.hostPlatform.isDarwin) [ rpcsvc-proto ]
++ lib.optionals stdenv.hostPlatform.isDarwin [ cctools darwin.DarwinTools ]; ++ lib.optionals stdenv.hostPlatform.isDarwin [
cctools
darwin.DarwinTools
];
buildInputs = [ buildInputs =
curl [
libedit curl
libssh libedit
lz4 libssh
openssl lz4
protobuf openssl
readline protobuf
zlib readline
zstd zlib
libevent zstd
icu libevent
re2 icu
ncurses re2
libfido2 ncurses
cyrus_sasl libfido2
openldap cyrus_sasl
python3 openldap
antlr.runtime.cpp python3
] ++ pythonDeps antlr.runtime.cpp
++ lib.optionals stdenv.hostPlatform.isLinux [ libtirpc ] ]
++ lib.optionals stdenv.hostPlatform.isDarwin [ darwin.libutil ]; ++ pythonDeps
++ lib.optionals stdenv.hostPlatform.isLinux [ libtirpc ]
++ lib.optionals stdenv.hostPlatform.isDarwin [ darwin.libutil ];
preConfigure = '' preConfigure = ''
# Build MySQL # Build MySQL