use alienfile;

plugin 'PkgConfig' => 'libzmq';

# http://zeromq.org/
share {
	plugin Download => (
		url => 'https://github.com/zeromq/libzmq/releases',
		version => qr/zeromq-([\d\.]+)\.tar\.gz/,
	);

	plugin Extract => 'tar.gz';

	plugin 'Build::Autoconf';
	my $enable_static = $^O ne 'MSWin32';
	build [
		join(' ', (
			'%{configure}',
			$enable_static ? '--enable-static' : '--disable-static',
			'--enable-shared'
		)),
		'%{make}',
		'%{make} install',
	];

	plugin 'Gather::Dino';
};
