aboutsummaryrefslogtreecommitdiffstats
path: root/math/speedcrunch/Makefile
blob: ef5b56ff232218e82357e1add2fa5d6ad9f776d8 (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
# New ports collection makefile for:    speedcrunch
# Date created:     27 Jul 2007
# Whom:                 Yinghong.Liu <relaxbsd@gmail.com>
#
# $FreeBSD$
#

PORTNAME=   speedcrunch
DISTVERSION=    0.10.1
PORTREVISION=   1
CATEGORIES= math
MASTER_SITES=   ${MASTER_SITE_GOOGLE_CODE}

MAINTAINER= makc@FreeBSD.org
COMMENT=    A desktop calculator for power users

USE_QT_VER= 4
QT_COMPONENTS=  qmake_build moc_build rcc_build uic_build gui xml
USE_CMAKE=  yes
CMAKE_SOURCE_PATH=  src

MAKE_JOBS_SAFE= yes

LRELEASE_CMD=   ${LOCALBASE}/bin/lrelease-qt4
LRELEASE_ARGS=  -compress -silent

.if !defined(WITHOUT_NLS)
QT_COMPONENTS+= linguist
PLIST_SUB+= NLS=""
.else
PLIST_SUB+= NLS="@comment "
.endif

pre-configure:
.if !defined(WITHOUT_NLS)
    cd ${WRKSRC}/src/i18n && ${LRELEASE_CMD} ${LRELEASE_ARGS} *.ts
.else
    ${REINPLACE_CMD} -e '/speedcrunch_TRANSLATIONS/d' ${WRKSRC}/src/CMakeLists.txt
.endif
    ${REINPLACE_CMD} -e 's,%%PREFIX%%,${PREFIX},g' ${WRKSRC}/src/gui/mainwindow.cpp

.include <bsd.port.mk>