PORTNAME=	declarative-test
DISTVERSION=	${QT5_VERSION}
PORTREVISION=	1
CATEGORIES=	x11-toolkits
PKGNAMEPREFIX=	qt5-

MAINTAINER=	ports@MidnightBSD.org
COMMENT=	Qt declarative framework for dynamic user interface (testing)

USES=		compiler:c++11-lang gl python:build qmake:norecursive \
		qt-dist:5,declarative
USE_GL=		gl
USE_QT=		core declarative gui network sql testlib widgets \
		buildtools_build

CONFLICTS=	qt5-declarative-render2d-* qt5-qml qt5-quick

BINARY_ALIAS=	python=${PYTHON_CMD}

QT_BINARIES=	yes
TOOLS=		qmltestrunner

post-patch:
# qtdeclarative.pro wants to run python, replace that with PYTHON_CMD
	${REINPLACE_CMD} '/py_out/s#python#${PYTHON_CMD}#g' \
		${WRKSRC}/qtdeclarative.pro
	${REINPLACE_CMD} 's,python,${PYTHON_CMD},g' \
		${WRKSRC}/src/3rdparty/masm/masm.pri

post-install:
	${REINPLACE_CMD} 's|/../../../../|/../../../|g' \
		${PREFIX}/lib/cmake/Qt5*/Qt5*Config.cmake

.include <bsd.port.mk>
