Files
nixpkgs/pkgs/by-name/co/coost/package.nix
Dark Steveneq 646b892680
Some checks failed
Periodic Merges (6h) / master → staging-nixos (push) Failing after 12m50s
Periodic Merges (6h) / master → staging-next (push) Failing after 12m54s
Periodic Merges (24h) / merge-base(master,staging) → haskell-updates (push) Failing after 11m54s
Periodic Merges (6h) / staging-next → staging (push) Failing after 12m13s
Periodic Merges (24h) / staging-next-25.05 → staging-25.05 (push) Failing after 13m24s
Periodic Merges (24h) / release-25.05 → staging-next-25.05 (push) Failing after 14m28s
push sheeet
2025-10-09 14:15:47 +02:00

53 lines
1.2 KiB
Nix

{
lib,
stdenv,
fetchFromGitHub,
cmake,
curl,
openssl,
gitUpdater,
withCurl ? true,
withOpenSSL ? true,
}:
stdenv.mkDerivation (finalAttrs: {
pname = "coost";
version = "3.0.2";
src = fetchFromGitHub {
owner = "idealvin";
repo = "coost";
rev = "v${finalAttrs.version}";
hash = "sha256-HbMenAL/UWsqQ1o7cMeWfwXkLh4GxIKV7iuZQD3hDA8=";
};
postPatch = ''
substituteInPlace cmake/coost.pc.in \
--replace '$'{exec_prefix}/@CMAKE_INSTALL_LIBDIR@ @CMAKE_INSTALL_FULL_LIBDIR@ \
--replace '$'{prefix}/@CMAKE_INSTALL_INCLUDEDIR@ @CMAKE_INSTALL_FULL_INCLUDEDIR@ \
'';
nativeBuildInputs = [ cmake ];
buildInputs = lib.optional withCurl curl ++ lib.optional withOpenSSL openssl;
cmakeFlags = [
"-DBUILD_SHARED_LIBS=ON"
]
++ lib.optional withCurl "-DWITH_LIBCURL=ON"
++ lib.optional withOpenSSL "-DWITH_OPENSSL=ON";
outputs = [
"out"
"dev"
];
passthru.updateScript = gitUpdater { };
meta = with lib; {
description = "Tiny boost library in C++11";
homepage = "https://github.com/idealvin/coost";
license = licenses.mit;
maintainers = [ maintainers.sigmanificient ];
platforms = platforms.unix;
};
})