svn commit: r321568 - in head/x11/libfm: . files

William Grzybowski wg at FreeBSD.org
Sat Jun 22 11:57:09 UTC 2013


Author: wg
Date: Sat Jun 22 11:57:08 2013
New Revision: 321568
URL: http://svnweb.freebsd.org/changeset/ports/321568

Log:
  x11/libfm: minor fixes
  
  - Fix NLS option [1]
  - Preserve .conf files [1]
  - Pass maintainership to submitter [1]
  - Fix pkg-plist and install of .conf
  
  PR:		ports/179703 [1]
  Submitted by:	nemysis <nemysis at gmx.ch>

Deleted:
  head/x11/libfm/files/
Modified:
  head/x11/libfm/Makefile
  head/x11/libfm/pkg-plist

Modified: head/x11/libfm/Makefile
==============================================================================
--- head/x11/libfm/Makefile	Sat Jun 22 11:47:57 2013	(r321567)
+++ head/x11/libfm/Makefile	Sat Jun 22 11:57:08 2013	(r321568)
@@ -7,7 +7,7 @@ PORTREVISION=	1
 CATEGORIES=	x11
 MASTER_SITES=	SF/pcmanfm/PCManFM%20%2B%20Libfm%20%28tarball%20release%29/libfm%20%28required%20by%20PCManFM%29/
 
-MAINTAINER=	ports at FreeBSD.org
+MAINTAINER=	nemysis at gmx.ch
 COMMENT=	The libFM backend library to PCManFM
 
 LICENSE=	GPLv2
@@ -15,38 +15,53 @@ LICENSE=	GPLv2
 LIB_DEPENDS=	startup-notification-1:${PORTSDIR}/x11/startup-notification \
 		menu-cache:${PORTSDIR}/x11/menu-cache
 
+USES=		pkgconfig
 USE_GNOME=	gnomehack gtk20
 USE_AUTOTOOLS=	libtool
+CONFIGURE_ARGS+=--sysconfdir=${LOCALBASE}/etc
 USE_GMAKE=	yes
 USE_FAM=	yes
 USE_LDCONFIG=	yes
-USES=		pkgconfig
+
 CPPFLAGS+=	-I${LOCALBASE}/include
 LDFLAGS+=	-L${LOCALBASE}/lib
-CONFIGURE_ARGS+=--sysconfdir=${LOCALBASE}/etc
 
 MAN1=		libfm-pref-apps.1
 
 OPTIONS_DEFINE=	NLS
+OPTIONS_SUB=	yes
 
-.include <bsd.port.options.mk>
+NLS_USES=	gettext
 
-.if ${PORT_OPTIONS:MNLS}
-USES+=		gettext
-PLIST_SUB+=	NLS=""
-.else
-CONFIGURE_ARGS+=--disable-nls
-PLIST_SUB+=	NLS="@comment "
-.endif
+.include <bsd.port.options.mk>
 
 post-patch:
+	@${REINPLACE_CMD} -e 's|^VALAC.*|VALAC=""|' \
+		${WRKSRC}/configure
 	@${REINPLACE_CMD} -e 's|-DG_DISABLE_DEPRECATED||g' \
 		${WRKSRC}/src/Makefile.in
 	@${REINPLACE_CMD} -e \
 		's|-Wno-unused-but-set-variable||' \
 		${WRKSRC}/src/actions/Makefile.am ${WRKSRC}/src/actions/Makefile.in
+	@${REINPLACE_CMD} -e '/libfm.conf/,/pref-apps.conf/ d' ${WRKSRC}/data/Makefile.in
+
+.if ! ${PORT_OPTIONS:MNLS}
+	@${REINPLACE_CMD} -e 's|src po|src|' \
+		${WRKSRC}/Makefile.in
+.endif
 
 pre-install:
-	cd ${WRKDIR}/libfm-${PORTVERSION} && ${CHMOD} 755 install-sh
+	@(cd ${WRKDIR}/libfm-${PORTVERSION} && ${CHMOD} 755 install-sh)
+
+post-install:
+	${MKDIR} ${PREFIX}/etc/xdg/libfm
+	${INSTALL_DATA} ${WRKSRC}/data/libfm.conf ${PREFIX}/etc/xdg/libfm/libfm.conf.sample
+	${INSTALL_DATA} ${WRKSRC}/data/pref-apps.conf ${PREFIX}/etc/xdg/libfm/pref-apps.conf.sample
+.if ! exists(${PREFIX}/etc/xdg/libfm/libfm.conf)
+	${INSTALL_DATA} ${WRKSRC}/data/libfm.conf ${PREFIX}/etc/xdg/libfm/libfm.conf
+.endif
+.if ! exists(${PREFIX}/etc/xdg/libfm/pref-apps.conf)
+	${INSTALL_DATA} ${WRKSRC}/data/pref-apps.conf ${PREFIX}/etc/xdg/libfm/pref-apps.conf
+.endif
 
 .include <bsd.port.mk>

Modified: head/x11/libfm/pkg-plist
==============================================================================
--- head/x11/libfm/pkg-plist	Sat Jun 22 11:47:57 2013	(r321567)
+++ head/x11/libfm/pkg-plist	Sat Jun 22 11:57:08 2013	(r321568)
@@ -1,7 +1,11 @@
 bin/libfm-pref-apps
-etc/xdg/libfm/libfm.conf
-etc/xdg/libfm/pref-apps.conf
 include/libfm
+ at unexec if cmp -s %D/etc/xdg/libfm/libfm.conf %D/etc/xdg/libfm/libfm.conf.sample; then rm -f %D/etc/xdg/libfm/libfm.conf; fi
+etc/xdg/libfm/libfm.conf.sample
+ at exec if [ ! -f %D/etc/xdg/libfm/libfm.conf ] ; then cp -p %D/%F %B/libfm.conf; fi
+ at unexec if cmp -s %D/etc/xdg/libfm/pref-apps.conf %D/etc/xdg/libfm/pref-apps.conf.sample; then rm -f %D/etc/xdg/libfm/pref-apps.conf; fi
+etc/xdg/libfm/pref-apps.conf.sample
+ at exec if [ ! -f %D/etc/xdg/libfm/pref-apps.conf ] ; then cp -p %D/%F %B/pref-apps.conf; fi
 include/libfm-1.0/fm-actions.h
 include/libfm-1.0/fm-app-chooser-combo-box.h
 include/libfm-1.0/fm-app-chooser-dlg.h
@@ -140,19 +144,19 @@ share/applications/libfm-pref-apps.deskt
 %%NLS%%share/locale/zh_CN/LC_MESSAGES/libfm.mo
 %%NLS%%share/locale/zh_TW/LC_MESSAGES/libfm.mo
 share/mime/packages/libfm.xml
- at dirrm etc/xdg/libfm
- at dirrm etc/xdg
- at dirrmtry share/locale/es_VE/LC_MESSAGES
- at dirrmtry share/locale/es_VE
- at dirrmtry share/locale/lg/LC_MESSAGES
- at dirrmtry share/locale/lg
- at dirrmtry share/locale/tt_RU/LC_MESSAGES
- at dirrmtry share/locale/tt_RU
- at dirrmtry share/locale/ur_PK/LC_MESSAGES
- at dirrmtry share/locale/ur_PK
- at dirrmtry share/applications
+ at dirrmtry etc/xdg/libfm
+ at dirrmtry etc/xdg
 @dirrmtry share/mime/packages
 @dirrmtry share/mime
+%%NLS%%@dirrmtry share/locale/ur_PK/LC_MESSAGES
+%%NLS%%@dirrmtry share/locale/ur_PK
+%%NLS%%@dirrmtry share/locale/tt_RU/LC_MESSAGES
+%%NLS%%@dirrmtry share/locale/tt_RU
+%%NLS%%@dirrmtry share/locale/lg/LC_MESSAGES
+%%NLS%%@dirrmtry share/locale/lg
+%%NLS%%@dirrmtry share/locale/es_VE/LC_MESSAGES
+%%NLS%%@dirrmtry share/locale/es_VE
 @dirrm %%DATADIR%%/ui
 @dirrm %%DATADIR%%
+ at dirrmtry share/applications
 @dirrm include/libfm-1.0


More information about the svn-ports-all mailing list