mariadb-connector-c: remove top-level with lib;

This commit is contained in:
TomaSajt 2024-05-13 22:02:37 +02:00
parent 5a2a2b8c0a
commit 7f98396a16
No known key found for this signature in database
GPG Key ID: F011163C050122A1

View File

@ -4,10 +4,8 @@
, version, hash, ...
}:
with lib;
let
isVer33 = versionAtLeast version "3.3";
isVer33 = lib.versionAtLeast version "3.3";
in stdenv.mkDerivation {
pname = "mariadb-connector-c";
@ -46,12 +44,12 @@ in stdenv.mkDerivation {
'';
# The cmake setup-hook uses $out/lib by default, this is not the case here.
preConfigure = optionalString stdenv.isDarwin ''
preConfigure = lib.optionalString stdenv.isDarwin ''
cmakeFlagsArray+=("-DCMAKE_INSTALL_NAME_DIR=$out/lib/mariadb")
'';
nativeBuildInputs = [ cmake ];
propagatedBuildInputs = [ curl openssl zlib ] ++ optional isVer33 zstd;
propagatedBuildInputs = [ curl openssl zlib ] ++ lib.optional isVer33 zstd;
buildInputs = [ libiconv ];
postInstall = ''
@ -67,7 +65,7 @@ in stdenv.mkDerivation {
install -Dm644 include/ma_config.h $dev/include/mariadb/my_config.h
'';
meta = {
meta = with lib; {
description = "Client library that can be used to connect to MySQL or MariaDB";
license = licenses.lgpl21Plus;
maintainers = with maintainers; [ globin ];