blob: 0b15d97bb35e00ca85a0b00cdd4dea9abe38e006 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
|
# Copyright 2015-2022 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI="8"
inherit cmake
if [[ "${PV}" == "9999" ]]; then
inherit git-r3
EGIT_REPO_URI="https://github.com/nemtrif/utfcpp"
EGIT_SUBMODULES=()
else
FTEST_GIT_REVISION=""
FTEST_DATE=""
fi
DESCRIPTION="UTF-8 C++ library"
HOMEPAGE="https://github.com/nemtrif/utfcpp"
if [[ "${PV}" == "9999" ]]; then
SRC_URI=""
else
SRC_URI="https://github.com/nemtrif/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz
test? ( https://github.com/nemtrif/ftest/archive/${FTEST_GIT_REVISION}.tar.gz -> ftest-${FTEST_DATE}.tar.gz )"
fi
LICENSE="Boost-1.0"
SLOT="0"
KEYWORDS=""
IUSE="test"
RESTRICT="!test? ( test )"
BDEPEND=""
DEPEND=""
RDEPEND=""
src_unpack() {
if [[ "${PV}" == "9999" ]]; then
git-r3_src_unpack
if use test; then
git-r3_fetch https://github.com/nemtrif/ftest refs/heads/master
git-r3_checkout https://github.com/nemtrif/ftest "${WORKDIR}/ftest"
fi
else
default
if use test; then
mv ftest-${FTEST_GIT_REVISION} ftest || die
fi
fi
rmdir "${S}/extern/ftest" || die
ln -s ../../ftest "${S}/extern/ftest" || die
}
src_configure() {
local mycmakeargs=(
-DUTF8_SAMPLES=OFF
-DUTF8_TESTS=$(usex test ON OFF)
)
cmake_src_configure
}
|