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
53 lines
1.3 KiB
Nix
53 lines
1.3 KiB
Nix
{
|
|
lib,
|
|
stdenv,
|
|
fetchFromGitHub,
|
|
nixosTests,
|
|
}:
|
|
|
|
stdenv.mkDerivation rec {
|
|
pname = "3proxy";
|
|
version = "0.9.5";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "3proxy";
|
|
repo = "3proxy";
|
|
tag = version;
|
|
sha256 = "sha256-uy6flZ1a7o02pr5O0pgl9zCjh8mE9W5JxotJeBMB16A=";
|
|
};
|
|
|
|
# They use 'install -s', that calls the native strip instead of the cross.
|
|
# Don't strip binary on install, we strip it on fixup phase anyway.
|
|
postPatch = ''
|
|
substituteInPlace Makefile.Linux \
|
|
--replace "(INSTALL_BIN) -s" "(INSTALL_BIN)" \
|
|
--replace "/usr" ""
|
|
'';
|
|
|
|
makeFlags = [
|
|
"-f Makefile.Linux"
|
|
"INSTALL=install"
|
|
"DESTDIR=${placeholder "out"}"
|
|
"CC:=$(CC)"
|
|
];
|
|
|
|
postInstall = ''
|
|
rm -fr $out/var
|
|
'';
|
|
|
|
# common.c:208:9: error: initialization of 'int (*)(struct pollfd *, unsigned int, int)' from incompatible pointer type 'int (*)(struct pollfd *, nfds_t, int)' {aka 'int (*)(struct pollfd *, long unsigned int, int)'}
|
|
env.NIX_CFLAGS_COMPILE = "-Wno-error=incompatible-pointer-types";
|
|
|
|
passthru.tests = {
|
|
smoke-test = nixosTests._3proxy;
|
|
};
|
|
|
|
meta = {
|
|
description = "Tiny free proxy server";
|
|
homepage = "https://github.com/3proxy/3proxy";
|
|
license = lib.licenses.bsd2;
|
|
platforms = lib.platforms.linux;
|
|
maintainers = with lib.maintainers; [ misuzu ];
|
|
};
|
|
}
|