aboutsummaryrefslogtreecommitdiffstats
path: root/graphics/tiled/Makefile
blob: a0462046170588795cdd5effe2412a853004cddb (plain) (blame)
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
# Created by: Dmitry Marakasov <amdmi3@FreeBSD.org>
# $FreeBSD$

PORTNAME=   tiled
PORTVERSION=    0.9.0
CATEGORIES= graphics editors games
MASTER_SITES=   SF/tiled/tiled-qt/${PORTVERSION}
DISTNAME=   tiled-qt-${PORTVERSION}

MAINTAINER= amdmi3@FreeBSD.org
COMMENT=    General purpose tile map editor

USE_QT4=    corelib gui opengl \
        linguist_build qmake_build moc_build uic_build rcc_build
MAKE_JOBS_SAFE= yes
USE_LDCONFIG=   yes

MAN1=       tiled.1 tmxrasterizer.1 tmxviewer.1

PORTDOCS=   *

post-patch:
    @${REINPLACE_CMD} -e 's|lrelease|&-qt4|' \
        ${WRKSRC}/translations/translations.pro
    @${REINPLACE_CMD} -e 's|.*\(QT += opengl\)|\1|' \
        ${WRKSRC}/src/tiled/tiled.pro
    @${REINPLACE_CMD} -e 's|/usr|${PREFIX}|' ${WRKSRC}/docs/tiled.desktop
    @${FIND} ${WRKSRC} -name "*.pro" -exec ${REINPLACE_CMD} -e 's|share/man|man|' {} \;

do-configure:
    cd ${WRKSRC} && ${SETENV} ${CONFIGURE_ENV} \
        ${QMAKE} ${QMAKEFLAGS} PREFIX="${PREFIX}" tiled.pro

.include <bsd.port.options.mk>

.if ${PORT_OPTIONS:MDOCS}
post-install:
    ${MKDIR} ${DOCSDIR}
    ${INSTALL_DATA} ${WRKSRC}/README.md ${DOCSDIR}/
.endif

.include <bsd.port.mk>