forked from mirrors/nixpkgs
perlPackages.NetZooKeeper: adapt to zookeeper_mt 3.6.2
This commit is contained in:
parent
03dec29a4f
commit
a429badcc8
|
@ -1,7 +1,12 @@
|
|||
import ./make-test-python.nix ({ pkgs, ...} : {
|
||||
import ./make-test-python.nix ({ pkgs, ...} :
|
||||
let
|
||||
|
||||
perlEnv = pkgs.perl.withPackages (p: [p.NetZooKeeper]);
|
||||
|
||||
in {
|
||||
name = "zookeeper";
|
||||
meta = with pkgs.stdenv.lib.maintainers; {
|
||||
maintainers = [ nequissimus ];
|
||||
maintainers = [ nequissimus ztzg ];
|
||||
};
|
||||
|
||||
nodes = {
|
||||
|
@ -30,5 +35,12 @@ import ./make-test-python.nix ({ pkgs, ...} : {
|
|||
server.wait_until_succeeds(
|
||||
"${pkgs.zookeeper}/bin/zkCli.sh -server localhost:2181 get /foo | grep hello"
|
||||
)
|
||||
|
||||
server.wait_until_succeeds(
|
||||
"${perlEnv}/bin/perl -E 'use Net::ZooKeeper qw(:acls); $z=Net::ZooKeeper->new(q(localhost:2181)); $z->create(qw(/perl foo acl), ZOO_OPEN_ACL_UNSAFE) || die $z->get_error()'"
|
||||
)
|
||||
server.wait_until_succeeds(
|
||||
"${perlEnv}/bin/perl -E 'use Net::ZooKeeper qw(:acls); $z=Net::ZooKeeper->new(q(localhost:2181)); $z->get(qw(/perl)) eq qw(foo) || die $z->get_error()'"
|
||||
)
|
||||
'';
|
||||
})
|
||||
|
|
|
@ -15752,18 +15752,31 @@ let
|
|||
|
||||
NetZooKeeper = buildPerlPackage {
|
||||
pname = "Net-ZooKeeper";
|
||||
version = "0.41";
|
||||
src = fetchurl {
|
||||
url = "mirror://cpan/authors/id/M/MA/MAF/Net-ZooKeeper-0.41.tar.gz";
|
||||
sha256 = "91c177f30f82302eaf3173356eef05c21bc82163df752acb469177bd14a72db9";
|
||||
version = "0.42pre";
|
||||
src = fetchFromGitHub {
|
||||
owner = "mark-5";
|
||||
repo = "p5-net-zookeeper";
|
||||
rev = "66e1a360aff9c39af728c36092b540a4b6045f70";
|
||||
sha256 = "0xl8lcv9gfv0nn8vrrxa4az359whqdhmzw4r51nn3add8pn3s9ip";
|
||||
};
|
||||
buildInputs = [ pkgs.zookeeper_mt ];
|
||||
nativeBuildInputs = [ pkgs.gnused ];
|
||||
# fix "error: format not a string literal and no format arguments [-Werror=format-security]"
|
||||
hardeningDisable = [ "format" ];
|
||||
NIX_CFLAGS_COMPILE = "-I${pkgs.zookeeper_mt}/include";
|
||||
# Make the async API accessible
|
||||
NIX_CFLAGS_COMPILE = "-DTHREADED";
|
||||
NIX_CFLAGS_LINK = "-L${pkgs.zookeeper_mt.out}/lib -lzookeeper_mt";
|
||||
# Most tests are skipped as no server is available in the sandbox.
|
||||
# `t/35_log.t` seems to suffer from a race condition; remove it. See
|
||||
# https://github.com/NixOS/nixpkgs/pull/104889#issuecomment-737144513
|
||||
preCheck = ''
|
||||
rm t/35_log.t
|
||||
'' + stdenv.lib.optionalString stdenv.isDarwin ''
|
||||
rm t/30_connect.t
|
||||
rm t/45_class.t
|
||||
'';
|
||||
meta = {
|
||||
maintainers = [ maintainers.limeytexan ];
|
||||
maintainers = with maintainers; [ limeytexan ztzg ];
|
||||
homepage = "https://github.com/mark-5/p5-net-zookeeper";
|
||||
license = stdenv.lib.licenses.asl20;
|
||||
};
|
||||
|
|
Loading…
Reference in a new issue