2019-01-07 10:48:20 +03:00
|
|
|
# Copyright 1999-2019 Gentoo Authors
|
2017-12-22 15:06:21 +03:00
|
|
|
# Distributed under the terms of the GNU General Public License v2
|
|
|
|
|
2019-01-07 10:48:20 +03:00
|
|
|
EAPI=7
|
2017-12-22 15:06:21 +03:00
|
|
|
|
2019-04-17 00:08:09 +03:00
|
|
|
PYTHON_COMPAT=( python3_{5,6,7} )
|
2017-12-22 15:06:21 +03:00
|
|
|
inherit cmake-utils python-any-r1
|
|
|
|
|
|
|
|
DESCRIPTION="An implementation of basic iCAL protocols"
|
|
|
|
HOMEPAGE="https://github.com/libical/libical"
|
2019-01-07 10:48:20 +03:00
|
|
|
SRC_URI="https://github.com/${PN}/${PN}/releases/download/v${PV}/${P}.tar.gz"
|
2017-12-22 15:06:21 +03:00
|
|
|
|
2018-01-07 09:16:01 +03:00
|
|
|
LICENSE="|| ( MPL-2.0 LGPL-2.1 )"
|
2017-12-22 15:06:21 +03:00
|
|
|
SLOT="0/3"
|
2019-03-30 17:40:05 +03:00
|
|
|
KEYWORDS="alpha amd64 arm ~arm64 ~hppa ia64 ~mips ppc ppc64 sparc x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x86-macos ~x86-solaris"
|
2018-01-07 09:16:01 +03:00
|
|
|
IUSE="berkdb doc examples static-libs test"
|
|
|
|
|
|
|
|
# TODO: disabled until useful
|
|
|
|
# glib? (
|
|
|
|
# dev-libs/glib:2
|
|
|
|
# dev-libs/libxml2:2
|
|
|
|
# )
|
|
|
|
# introspection? ( dev-libs/gobject-introspection:= )
|
2019-01-07 10:48:20 +03:00
|
|
|
DEPEND="
|
2017-12-22 15:06:21 +03:00
|
|
|
dev-libs/icu:=
|
|
|
|
berkdb? ( sys-libs/db:= )
|
|
|
|
"
|
2019-01-07 10:48:20 +03:00
|
|
|
BDEPEND="
|
2017-12-22 15:06:21 +03:00
|
|
|
dev-lang/perl
|
2018-05-30 09:07:54 +03:00
|
|
|
virtual/pkgconfig
|
2017-12-22 15:06:21 +03:00
|
|
|
doc? ( app-doc/doxygen )
|
|
|
|
test? ( ${PYTHON_DEPS} )
|
|
|
|
"
|
2019-01-07 10:48:20 +03:00
|
|
|
RDEPEND="${DEPEND}
|
2017-12-22 15:06:21 +03:00
|
|
|
sys-libs/timezone-data
|
|
|
|
"
|
|
|
|
|
|
|
|
DOCS=(
|
|
|
|
AUTHORS ReadMe.txt ReleaseNotes.txt TEST THANKS TODO
|
|
|
|
doc/{AddingOrModifyingComponents,UsingLibical}.txt
|
|
|
|
)
|
|
|
|
|
2018-05-30 09:07:54 +03:00
|
|
|
PATCHES=(
|
|
|
|
"${FILESDIR}/${PN}-3.0.1-pkgconfig-libdir.patch"
|
2019-01-07 10:48:20 +03:00
|
|
|
"${FILESDIR}/${P}-tests.patch"
|
2018-05-30 09:07:54 +03:00
|
|
|
)
|
2017-12-22 15:06:21 +03:00
|
|
|
|
|
|
|
pkg_setup() {
|
|
|
|
use test && python-any-r1_pkg_setup
|
|
|
|
}
|
|
|
|
|
|
|
|
src_prepare() {
|
|
|
|
cmake-utils_src_prepare
|
|
|
|
use examples || cmake_comment_add_subdirectory examples
|
|
|
|
}
|
|
|
|
|
|
|
|
src_configure() {
|
|
|
|
local mycmakeargs=(
|
2018-01-07 09:16:01 +03:00
|
|
|
-DICAL_GLIB=OFF
|
|
|
|
-DGOBJECT_INTROSPECTION=OFF
|
2017-12-22 15:06:21 +03:00
|
|
|
$(cmake-utils_use_find_package berkdb BDB)
|
2018-05-30 09:07:54 +03:00
|
|
|
-DICAL_BUILD_DOCS=$(usex doc)
|
2017-12-22 15:06:21 +03:00
|
|
|
-DSHARED_ONLY=$(usex !static-libs)
|
|
|
|
)
|
2018-01-07 09:16:01 +03:00
|
|
|
# TODO: disabled until useful
|
|
|
|
# -DICAL_GLIB=$(usex glib)
|
|
|
|
# -DGOBJECT_INTROSPECTION=$(usex introspection)
|
2017-12-22 15:06:21 +03:00
|
|
|
cmake-utils_src_configure
|
|
|
|
}
|
|
|
|
|
|
|
|
src_compile() {
|
|
|
|
cmake-utils_src_compile
|
|
|
|
use doc && cmake-utils_src_compile docs
|
|
|
|
}
|
|
|
|
|
|
|
|
src_test() {
|
2019-01-07 10:48:20 +03:00
|
|
|
local myctestargs=(
|
|
|
|
-E "(icalrecurtest|icalrecurtest-r)" # bug 660282
|
|
|
|
)
|
|
|
|
|
2017-12-22 15:06:21 +03:00
|
|
|
cmake-utils_src_test
|
|
|
|
}
|
|
|
|
|
|
|
|
src_install() {
|
|
|
|
use doc && HTML_DOCS=( "${BUILD_DIR}"/apidocs/html/. )
|
|
|
|
|
|
|
|
cmake-utils_src_install
|
|
|
|
|
|
|
|
if use examples; then
|
|
|
|
rm examples/CMakeLists.txt || die
|
|
|
|
dodoc -r examples
|
|
|
|
fi
|
|
|
|
}
|