svn commit: r398050 - head/graphics/djview4
Ruslan Makhmatkhanov
rm at FreeBSD.org
Sun Sep 27 21:01:40 UTC 2015
Author: rm
Date: Sun Sep 27 21:01:38 2015
New Revision: 398050
URL: https://svnweb.freebsd.org/changeset/ports/398050
Log:
graphics/djview4: port improvements
There are some improvements for graphics/djview4 port to make it usable on
desktop. For example, while there is a need to use register-djview-menu shell
script (on post-install stage, which is not available currently) to setup the
djview4 menu entries and icons, it is possible to install them manually, as
described in ${WRKSRC}/desktopfiles/README file. Also this application is
translated to different languages.
- add LICENSE_FILE
- add libtiff.so to LIB_DEPENDS as required shared library
- add desktop-file-utils to USES and sort it
- add linguist to USE_QT4, because there are available messages to translate
- add --disable-desktopfiles option to CONFIGURE_ARGS, which do not install
scripts to register icons and menus
- replace CFLAGS and CXXFLAGS with CPPFLAGS for include directory
- improve sed patch by using & for replacement part
- strip web-plugin library, install icons and desktop files on post-install
stage
- remove unneeded files after --disable-desktopfiles option from pkg-plist
- add translated files, icons and desktop files to pkg-plist
PR: 196409
Submitted by: lightside <lightside at gmx.com>
Modified:
head/graphics/djview4/Makefile
head/graphics/djview4/pkg-plist
Modified: head/graphics/djview4/Makefile
==============================================================================
--- head/graphics/djview4/Makefile Sun Sep 27 20:39:37 2015 (r398049)
+++ head/graphics/djview4/Makefile Sun Sep 27 21:01:38 2015 (r398050)
@@ -3,7 +3,7 @@
PORTNAME= djview
PORTVERSION= 4.9
-PORTREVISION= 4
+PORTREVISION= 5
CATEGORIES= graphics
MASTER_SITES= SF/djvu/DjView/${PORTVERSION}
@@ -11,21 +11,23 @@ MAINTAINER= ports at FreeBSD.org
COMMENT= Standalone Djvu viewer and plugin based on Qt4 toolkit
LICENSE= GPLv2
+LICENSE_FILE= ${WRKSRC}/COPYING
-LIB_DEPENDS= libdjvulibre.so:${PORTSDIR}/graphics/djvulibre
+LIB_DEPENDS= libdjvulibre.so:${PORTSDIR}/graphics/djvulibre \
+ libtiff.so:${PORTSDIR}/graphics/tiff
GNU_CONFIGURE= yes
-USES= pkgconfig webplugin:native libtool
-USE_QT4= gui network rcc_build uic_build moc_build qmake_build
+USES= desktop-file-utils libtool pkgconfig webplugin:native
+USE_QT4= gui network linguisttools_build moc_build qmake_build rcc_build \
+ uic_build
USE_XORG= sm ice xt
QT_NONSTANDARD= yes
CONFIGURE_ARGS= --x-includes="${LOCALBASE}/include" \
- --x-libraries="${LOCALBASE}/lib"
+ --x-libraries="${LOCALBASE}/lib" --disable-desktopfiles
CONFIGURE_ENV= QMAKE="${QMAKE}" \
QMAKESPEC="${QMAKESPEC}"
+CPPFLAGS+= -I${LOCALBASE}/include
LDFLAGS+= -L${LOCALBASE}/lib
-CFLAGS+= -I${LOCALBASE}/include
-CXXFLAGS+= -I${LOCALBASE}/include
MAKE_ENV= INSTALL_SCRIPT="${INSTALL_SCRIPT}"
WRKSRC= ${WRKDIR}/djview4-${PORTVERSION}
@@ -36,10 +38,20 @@ WEBPLUGIN_FILES= nsdejavu.so
post-patch:
@${REINPLACE_CMD} -e 's,/netscape/,/djview4/,' \
${WRKSRC}/nsdejavu/Makefile.in ${WRKSRC}/nsdejavu/nsdejavu.1.in
- @${REINPLACE_CMD} -e 's, at NSDEJAVU_LIBS@, at NSDEJAVU_LIBS@ -lXt -lXext,g' \
+ @${REINPLACE_CMD} -e 's, at NSDEJAVU_LIBS@,& -lXt -lXext,g' \
${WRKSRC}/nsdejavu/Makefile.in
post-install:
+.for f in ${WEBPLUGIN_FILES}
+ @${STRIP_CMD} ${STAGEDIR}${WEBPLUGIN_DIR}/${f}
+.endfor
+.for d in 32 64
+ @${MKDIR} ${STAGEDIR}${PREFIX}/share/icons/hicolor/${d}x${d}/apps
+ ${INSTALL_DATA} ${WRKSRC}/desktopfiles/hi${d}-djview4.png \
+ ${STAGEDIR}${PREFIX}/share/icons/hicolor/${d}x${d}/apps/djvulibre-djview4.png
+.endfor
+ ${INSTALL_DATA} ${WRKSRC}/desktopfiles/djvulibre-djview4.desktop \
+ ${STAGEDIR}${PREFIX}/share/applications
${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib/djview4/plugins/nsdejavu.so
.include <bsd.port.mk>
Modified: head/graphics/djview4/pkg-plist
==============================================================================
--- head/graphics/djview4/pkg-plist Sun Sep 27 20:39:37 2015 (r398049)
+++ head/graphics/djview4/pkg-plist Sun Sep 27 21:01:38 2015 (r398050)
@@ -4,10 +4,13 @@ lib/djview4/plugins/nsdejavu.so
man/man1/djview.1.gz
man/man1/djview4.1.gz
man/man1/nsdejavu.1.gz
-share/djvu/djview4/desktop/djvulibre-djview4.desktop
-share/djvu/djview4/desktop/hi-djview4.svgz
-share/djvu/djview4/desktop/hi32-djview4.png
-share/djvu/djview4/desktop/hi64-djview4.png
-share/djvu/djview4/desktop/prebuilt-hi32-djview4.png
-share/djvu/djview4/desktop/prebuilt-hi64-djview4.png
-share/djvu/djview4/desktop/register-djview-menu
+share/applications/djvulibre-djview4.desktop
+share/djvu/djview4/djview_cs.qm
+share/djvu/djview4/djview_de.qm
+share/djvu/djview4/djview_fr.qm
+share/djvu/djview4/djview_ru.qm
+share/djvu/djview4/djview_uk.qm
+share/djvu/djview4/djview_zh_cn.qm
+share/djvu/djview4/djview_zh_tw.qm
+share/icons/hicolor/32x32/apps/djvulibre-djview4.png
+share/icons/hicolor/64x64/apps/djvulibre-djview4.png
More information about the svn-ports-all
mailing list