Diff cppzmq-0_pre150606 with a cppzmq-4.6.0

/usr/portage/net-libs/cppzmq/cppzmq-4.6.0.ebuild 2020-07-04 16:09:00.000000000 +0300
1 1
# Copyright 1999-2020 Gentoo Authors
2 2
# Distributed under the terms of the GNU General Public License v2
3 3

  
4
EAPI=5
4
EAPI=7
5 5

  
6
inherit toolchain-funcs
6
inherit cmake
7 7

  
8 8
DESCRIPTION="High-level CPP Binding for ZeroMQ"
9 9
HOMEPAGE="https://github.com/zeromq/cppzmq"
10
SRC_URI="https://dev.gentoo.org/~jlec/distfiles/${P}.tar.xz"
10
SRC_URI="https://github.com/zeromq/${PN}/archive/v${PV}.tar.gz ->  ${P}.tar.gz"
11 11

  
12 12
SLOT="0"
13 13
LICENSE="MIT"
14
KEYWORDS="amd64 ~arm ~arm64 x86 ~amd64-linux ~x86-linux"
15
IUSE=""
14
KEYWORDS="~amd64 ~arm ~arm64 ~x86 ~x86-linux"
16 15

  
17
RDEPEND=">=net-libs/zeromq-3"
18
DEPEND=""
16
IUSE="test"
17
RESTRICT="!test? ( test )"
19 18

  
20
src_install() {
21
	doheader zmq.hpp
22
	dodoc README
19
RDEPEND=">=net-libs/zeromq-4.3.1"
20
# Tests require cmake modules from catch2 and headers from older version of catch
21
DEPEND="${RDEPEND}
22
	test? ( >=dev-cpp/catch-2.5.0
23
		<dev-cpp/catch-2
24
	)"
25

  
26
PATCHES=(
27
	"${FILESDIR}/${PN}-disable-static.patch"
28
	"${FILESDIR}/${PN}-use-system-catch2.patch"
29
)
30

  
31
src_configure() {
32
	local mycmakeargs=(
33
		-DCPPZMQ_CMAKECONFIG_INSTALL_DIR="/usr/$(get_libdir)/cmake/${PN}/"
34
		-DCPPZMQ_BUILD_TESTS="$(usex test)"
35
	)
36
	if has_version -d '>=net-libs/zeromq-4.3.1[drafts]'; then
37
		mycmakeargs+=( -DENABLE_DRAFTS=on )
38
	fi
39
	cmake_src_configure
23 40
}
24 41

  
25
src_test() {
26
	$(tc-getCC) -c ./zmq.hpp -L ./.libs/ -I ./include/ -o ./test.o || die "This version of cppzmq is not compatible with the installed version of net-libs/zeromq"
27
	rm -f ./test.o
42
src_install() {
43
	cmake_src_install
44
	einstalldocs
28 45
}
Thank you!