diff options
author | araujo <araujo@FreeBSD.org> | 2013-01-21 11:40:30 +0800 |
---|---|---|
committer | araujo <araujo@FreeBSD.org> | 2013-01-21 11:40:30 +0800 |
commit | f5599ef8eb2b56c5761a5c301ffa41c787352ace (patch) | |
tree | 074b2c353257c29b1e72e3f8b3d6b9639b7db50d /graphics | |
parent | 9615bfc4ea40e83e292ab83b3cc54718edb06984 (diff) | |
download | freebsd-ports-gnome-f5599ef8eb2b56c5761a5c301ffa41c787352ace.tar.gz freebsd-ports-gnome-f5599ef8eb2b56c5761a5c301ffa41c787352ace.tar.zst freebsd-ports-gnome-f5599ef8eb2b56c5761a5c301ffa41c787352ace.zip |
- Support CXXFLAGS properly.
- Support PLIST_FILES.
- Add LICENSE.
- Bump PORTREVISION.
PR: ports/174187
Submitted by: KATO Tsuguru <tkato432@yahoo.com>
Diffstat (limited to 'graphics')
-rw-r--r-- | graphics/darknock/Makefile | 42 | ||||
-rw-r--r-- | graphics/darknock/pkg-plist | 10 |
2 files changed, 25 insertions, 27 deletions
diff --git a/graphics/darknock/Makefile b/graphics/darknock/Makefile index d2c3c66ebfeb..0f85cb6cd2ed 100644 --- a/graphics/darknock/Makefile +++ b/graphics/darknock/Makefile @@ -2,26 +2,23 @@ # $FreeBSD$ PORTNAME= darknock -DISTVERSION= 0.3.0 -PORTREVISION= 3 +PORTVERSION= 0.3.0 +PORTREVISION= 4 CATEGORIES= graphics MASTER_SITES= SF/${PORTNAME}/${PORTNAME}/${PORTNAME}-${PORTVERSION} MAINTAINER= ports@FreeBSD.org COMMENT= Program that can detect edges in images -USE_QT4= qmake_build moc_build rcc_build uic_build linguist_build gui +LICENSE= GPLv2 # (or later) + WRKSRC= ${WRKDIR}/${PORTNAME} -LRELEASE= ${QT_PREFIX}/bin/lrelease-qt4 -MAKE_JOBS_SAFE= yes -PORTDOCS= changelog copyright +USE_QT4= gui linguist_build moc_build qmake_build rcc_build uic_build +MAKE_JOBS_SAFE= yes -.if !defined(WITHOUT_NLS) -PLIST_SUB+= NLS="" -.else -PLIST_SUB+= NLS="@comment " -.endif +PORTDOCS= changelog +PLIST_FILES= bin/darknock share/pixmaps/darknock.png DESKTOP_ENTRIES= "${PORTNAME}" \ "${COMMENT}" \ @@ -30,25 +27,36 @@ DESKTOP_ENTRIES= "${PORTNAME}" \ "Graphics;Qt;" \ "false" +LRELEASE= ${QT_PREFIX}/bin/lrelease-qt4 + +.include <bsd.port.options.mk> + +.if ${PORT_OPTIONS:MNLS} +.for lang in fr it pl ro sv tr +PLIST_FILES+= %%DATADIR%%/locale/darknock_${lang}.qm +.endfor +PLIST_DIRS+= %%DATADIR%%/locale %%DATADIR%% +.endif + post-patch: @${REINPLACE_CMD} -e 's|/usr/share/darknock|${DATADIR}|g' \ ${WRKSRC}/src/main.cpp pre-build: @${LRELEASE} ${BUILD_WRKSRC}/${PORTNAME}.pro - @cd ${BUILD_WRKSRC}; ${SETENV} ${MAKE_ENV} ${QMAKE} -spec ${QMAKESPEC} + @(cd ${BUILD_WRKSRC} && ${SETENV} ${MAKE_ENV} ${QMAKE} ${QMAKEFLAGS}) do-install: - @${INSTALL_PROGRAM} ${WRKSRC}/${PORTNAME} ${PREFIX}/bin - @${INSTALL_DATA} ${WRKSRC}/images/${PORTNAME}.png ${PREFIX}/share/pixmaps -.if !defined(WITHOUT_NLS) + ${INSTALL_PROGRAM} ${WRKSRC}/${PORTNAME} ${PREFIX}/bin + ${INSTALL_DATA} ${WRKSRC}/images/${PORTNAME}.png ${PREFIX}/share/pixmaps +.if ${PORT_OPTIONS:MNLS} @${MKDIR} ${DATADIR}/locale - @${INSTALL_DATA} ${WRKSRC}/locale/*.qm ${DATADIR}/locale + ${INSTALL_DATA} ${WRKSRC}/locale/*.qm ${DATADIR}/locale .endif .if !defined(NOPORTDOCS) @${MKDIR} ${DOCSDIR} .for doc in ${PORTDOCS} - @${INSTALL_DATA} ${WRKSRC}/${doc} ${DOCSDIR} + ${INSTALL_DATA} ${WRKSRC}/${doc} ${DOCSDIR} .endfor .endif diff --git a/graphics/darknock/pkg-plist b/graphics/darknock/pkg-plist deleted file mode 100644 index 7b36e1b4e583..000000000000 --- a/graphics/darknock/pkg-plist +++ /dev/null @@ -1,10 +0,0 @@ -bin/darknock -%%NLS%%%%DATADIR%%/locale/darknock_fr.qm -%%NLS%%%%DATADIR%%/locale/darknock_it.qm -%%NLS%%%%DATADIR%%/locale/darknock_pl.qm -%%NLS%%%%DATADIR%%/locale/darknock_ro.qm -%%NLS%%%%DATADIR%%/locale/darknock_sv.qm -%%NLS%%%%DATADIR%%/locale/darknock_tr.qm -share/pixmaps/darknock.png -%%NLS%%@dirrm %%DATADIR%%/locale -%%NLS%%@dirrm %%DATADIR%% |