summaryrefslogblamecommitdiff
path: root/user/kholidays/APKBUILD
blob: e6018c534d962025f3e068368f6735fc68968d76 (plain) (tree)












































                                                                                                                                                                       
# Contributor: A. Wilcox <awilfox@adelielinux.org>
# Maintainer: A. Wilcox <awilfox@adelielinux.org>
pkgname=kholidays
pkgver=17.08.1
pkgrel=0
pkgdesc="List of national holidays for many countries"
url="https://www.kde.org/"
arch="all"
license="LGPL-2.1"
depends=""
depends_dev="qt5-qtbase-dev qt5-qtdeclarative-dev"
makedepends="$depends_dev cmake extra-cmake-modules qt5-qttools-dev"
install=""
subpackages="$pkgname-dev $pkgname-lang"
source="http://download.kde.org/stable/applications/$pkgver/src/kholidays-$pkgver.tar.xz"
builddir="$srcdir/kholidays-$pkgver"

build() {
	cd "$builddir"
	if [ "$CBUILD" != "$CHOST" ]; then
		CMAKE_CROSSOPTS="-DCMAKE_SYSTEM_NAME=Linux -DCMAKE_HOST_SYSTEM_NAME=Linux"
	fi
	cmake \
		-DCMAKE_INSTALL_PREFIX=/usr \
		-DCMAKE_INSTALL_LIBDIR=lib \
		-DBUILD_SHARED_LIBS=True \
		-DCMAKE_BUILD_TYPE=RelWithDebugInfo \
		-DCMAKE_CXX_FLAGS="$CXXFLAGS" \
		-DCMAKE_C_FLAGS="$CFLAGS" \
		${CMAKE_CROSSOPTS}
	make
}

check() {
	cd "$builddir"
	# Requires *actual* *locale* *support*!
	CTEST_OUTPUT_ON_FAILURE=TRUE ctest -E testholidayregion
}

package() {
	cd "$builddir"
	make DESTDIR="$pkgdir" install
}

sha512sums="6a369bf20ee711bc1fc5134245f2909fac8754eb73291c7cfedb6cc131833b8d6156e4a444d4a56f36bfab8ed1a7fa23efd91f671ec8c496db73440fd08201df  kholidays-17.08.1.tar.xz"