2021-01-11 07:54:33 +00:00
|
|
|
{ lib, stdenv
|
2021-01-01 20:37:44 +00:00
|
|
|
, autoreconfHook
|
|
|
|
, bison
|
2021-05-19 07:52:52 +00:00
|
|
|
, fetchFromGitHub
|
2021-01-01 20:37:44 +00:00
|
|
|
, flex
|
2021-05-19 07:52:52 +00:00
|
|
|
, lksctp-tools
|
2021-01-01 20:37:44 +00:00
|
|
|
, openssl
|
2021-05-19 07:52:52 +00:00
|
|
|
, pkg-config
|
2021-01-01 20:37:44 +00:00
|
|
|
, sqlite
|
2021-05-19 07:52:52 +00:00
|
|
|
, util-linux
|
2021-01-01 20:37:44 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "solanum";
|
2021-11-30 14:41:47 +00:00
|
|
|
version = "unstable-2021-11-14";
|
2021-01-01 20:37:44 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "solanum-ircd";
|
|
|
|
repo = pname;
|
2021-11-30 14:41:47 +00:00
|
|
|
rev = "bd38559fedcdfded4d9acbcbf988e4a8f5057eeb";
|
|
|
|
sha256 = "sha256-2P+mqf5b+TD9+9dLahXOdH7ZZhPWUoR1eV73YHbRbAA=";
|
2021-01-01 20:37:44 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
patches = [
|
|
|
|
./dont-create-logdir.patch
|
|
|
|
];
|
|
|
|
|
2021-05-31 00:27:08 +00:00
|
|
|
postPatch = ''
|
|
|
|
substituteInPlace include/defaults.h --replace 'ETCPATH "' '"/etc/solanum'
|
|
|
|
'';
|
|
|
|
|
2021-01-01 20:37:44 +00:00
|
|
|
configureFlags = [
|
|
|
|
"--enable-epoll"
|
|
|
|
"--enable-ipv6"
|
|
|
|
"--enable-openssl=${openssl.dev}"
|
|
|
|
"--with-program-prefix=solanum-"
|
2021-05-19 07:52:52 +00:00
|
|
|
"--localstatedir=/var/lib"
|
|
|
|
"--with-rundir=/run"
|
|
|
|
"--with-logdir=/var/log"
|
2021-01-15 07:07:56 +00:00
|
|
|
] ++ lib.optionals (stdenv.isLinux) [
|
2021-01-01 20:37:44 +00:00
|
|
|
"--enable-sctp=${lksctp-tools.out}/lib"
|
|
|
|
];
|
|
|
|
|
|
|
|
nativeBuildInputs = [
|
|
|
|
autoreconfHook
|
|
|
|
bison
|
|
|
|
flex
|
|
|
|
pkg-config
|
2021-05-19 07:52:52 +00:00
|
|
|
util-linux
|
2021-01-01 20:37:44 +00:00
|
|
|
];
|
|
|
|
|
|
|
|
buildInputs = [
|
|
|
|
openssl
|
|
|
|
sqlite
|
|
|
|
];
|
|
|
|
|
|
|
|
doCheck = !stdenv.isDarwin;
|
|
|
|
|
2021-01-03 15:52:49 +00:00
|
|
|
enableParallelBuilding = true;
|
|
|
|
|
2021-01-11 07:54:33 +00:00
|
|
|
meta = with lib; {
|
2021-01-01 20:37:44 +00:00
|
|
|
description = "An IRCd for unified networks";
|
|
|
|
homepage = "https://github.com/solanum-ircd/solanum";
|
2021-06-02 00:41:53 +00:00
|
|
|
license = licenses.gpl2Plus;
|
2021-01-01 20:37:44 +00:00
|
|
|
maintainers = with maintainers; [ hexa ];
|
|
|
|
platforms = platforms.unix;
|
|
|
|
};
|
|
|
|
}
|