PORTNAME=	libcomps
DISTVERSION=	0.1.23
CATEGORIES=	misc

MAINTAINER=	yuri@FreeBSD.org
COMMENT=	Comps XML file manipulation library
WWW=		https://github.com/rpm-software-management/libcomps

LICENSE=	GPLv2
LICENSE_FILE=	${WRKSRC}/../COPYING

LIB_DEPENDS=	libexpat.so:textproc/expat2

USES=		cmake:testing cpe gnome localbase:ldflags
CPE_VENDOR=	rpm
USE_GNOME=	libxml2
USE_LDCONFIG=	yes

USE_GITHUB=	yes
GH_ACCOUNT=	rpm-software-management

WRKSRC_SUBDIR=	${PORTNAME}

CMAKE_OFF=	ENABLE_TESTS ENABLE_DOCS
CMAKE_TESTING_ON=	ENABLE_TESTS

OPTIONS_DEFINE=		PYTHON
OPTIONS_DEFAULT=	PYTHON
OPTIONS_SUB=		yes

PYTHON_CMAKE_BOOL=	BUILD_PYTHON_MODULE
PYTHON_USES=		python
PYTHON_BUILD_DEPENDS=	${PY_SETUPTOOLS}
PYTHON_CMAKE_ON=	-DPYTHON_DESIRED=${PYTHON_MAJOR_VER}

# tests as of 0.1.23:
# 100%: Checks: 5, Failures: 0, Errors: 0
# 100%: Checks: 8, Failures: 0, Errors: 0

.include <bsd.port.mk>
