ports/91084: [patch] Add a menu entry for sysutils/gtk-send-pr

"Panagiotis Astithas" <Panagiotis Astithas past at ebs.gr
Fri Dec 30 11:20:06 UTC 2005


>Number:         91084
>Category:       ports
>Synopsis:       [patch] Add a menu entry for sysutils/gtk-send-pr
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Fri Dec 30 11:20:03 GMT 2005
>Closed-Date:
>Last-Modified:
>Originator:     Panagiotis Astithas
>Release:        FreeBSD 6.0-STABLE i386
>Organization:
EBS Ltd. 
>Environment:


System: FreeBSD 6.0-STABLE #4: Thu Dec 22 19:57:57 EET 2005
    past at ajax.ebs.gr:/usr/obj/usr/src/sys/AJAX



>Description:


This patch adds a menu entry for gtk-send-pr on GNOME, KDE, etc., thus
making it easier for inexperienced users to spot it. Since it is now
included in gnome2-power-tools its usage from both newbies and 
old-timers should be increased. In order to do this I had to use a
pkg-plist to hold the necessary invocations of update-desktop-database.


>How-To-Repeat:





>Fix:


--- gtk-send-pr.patch begins here ---
diff -ruN /usr/ports/sysutils/gtk-send-pr/Makefile gtk-send-pr/Makefile
--- /usr/ports/sysutils/gtk-send-pr/Makefile	Sat Nov  5 07:21:14 2005
+++ gtk-send-pr/Makefile	Fri Dec 30 13:01:04 2005
@@ -17,14 +17,22 @@
 LIB_DEPENDS=	esmtp.6:${PORTSDIR}/mail/libesmtp
 
 USE_REINPLACE=	yes
-USE_GNOME=	gtk20
+USE_GNOME=	gtk20 desktopfileutils
 USE_X_PREFIX=	yes
 
 MAN1=		gtk-send-pr.1
-PLIST_FILES=	bin/gtk-send-pr
+
+post-patch:
+	@${SED} -e 's|%%PREFIX%%|${PREFIX}|g' ${FILESDIR}/${PORTNAME}.desktop.in \
+		> ${WRKSRC}/${PORTNAME}.desktop
 
 do-install:
 	@${INSTALL_PROGRAM} ${WRKSRC}/gtk-send-pr ${PREFIX}/bin
 	@${INSTALL_MAN} ${WRKSRC}/gtk-send-pr.1 ${PREFIX}/man/man1
+	@${INSTALL_DATA} ${WRKSRC}/ladybird.gif ${PREFIX}/share/pixmaps
+
+post-install:
+	${INSTALL_DATA} ${WRKSRC}/${PORTNAME}.desktop ${PREFIX}/share/applications/${PORTNAME}.desktop
+	@-update-desktop-database
 
 .include <bsd.port.mk>
diff -ruN /usr/ports/sysutils/gtk-send-pr/files/gtk-send-pr.desktop.in gtk-send-pr/files/gtk-send-pr.desktop.in
--- /usr/ports/sysutils/gtk-send-pr/files/gtk-send-pr.desktop.in	Thu Jan  1 02:00:00 1970
+++ gtk-send-pr/files/gtk-send-pr.desktop.in	Fri Dec 30 13:02:12 2005
@@ -0,0 +1,9 @@
+[Desktop Entry]
+Comment=Send a FreeBSD PR
+Name=Send Problem Report
+Exec=%%PREFIX%%/bin/gtk-send-pr
+Encoding=UTF-8
+Terminal=false
+Type=Application
+Icon=%%PREFIX%%/share/pixmaps/ladybird.gif
+Categories=Application;System;
diff -ruN /usr/ports/sysutils/gtk-send-pr/pkg-plist gtk-send-pr/pkg-plist
--- /usr/ports/sysutils/gtk-send-pr/pkg-plist	Thu Jan  1 02:00:00 1970
+++ gtk-send-pr/pkg-plist	Fri Dec 30 12:55:51 2005
@@ -0,0 +1,5 @@
+bin/gtk-send-pr
+share/pixmaps/ladybird.gif
+share/applications/gtk-send-pr.desktop
+ at exec %%LOCALBASE%%/bin/update-desktop-database > /dev/null || /usr/bin/true
+ at unexec %%LOCALBASE%%/bin/update-desktop-database > /dev/null || /usr/bin/true
--- gtk-send-pr.patch ends here ---



>Release-Note:
>Audit-Trail:
>Unformatted:



More information about the freebsd-ports-bugs mailing list