Package: distccmon-gnome
Version: 3.1-6
Severity: minor
Tags: patch

Dear Maintainer,

distccmon-gnome looks in PKGDATADIR for distccmon-gnome-icon.png, but this icon
has been relocated downstream to /usr/share/pixmaps.

Here's a modified version of debian/patches/08_gnome-data-public-dirs.patch that
incorporates this fix, and the interdiff between the old and new patches.

-- System Information:
Debian Release: jessie/sid
  APT prefers utopic-updates
  APT policy: (500, 'utopic-updates'), (500, 'utopic-security'), (500, 
'utopic'), (100, 'utopic-backports')
Architecture: amd64 (x86_64)
Foreign Architectures: i386

Kernel: Linux 3.17.3-hyper1 (SMP w/4 CPU cores; PREEMPT)
Locale: LANG=en_GB.UTF-8, LC_CTYPE=en_GB.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash

Versions of packages distccmon-gnome depends on:
ii  libc6         2.19-10ubuntu2.1
ii  libglib2.0-0  2.42.1-1~ubuntu1
ii  libgnome2-0   2.32.1-4ubuntu1
ii  libgnomeui-0  2.24.5-3
ii  libgtk2.0-0   2.24.25-0ubuntu1

distccmon-gnome recommends no packages.

Versions of packages distccmon-gnome suggests:
ii  distcc  3.1-6

-- no debconf information

-- 
Kind regards,
Loong Jin
Description: Install distccmon-gnome desktop, icon files to public dirs
 These files are currently put in /usr/share/distcc and as a result
 the program is not integrated in to the applications menu.
 .
 This patch puts them in /usr/share/applications and /usr/share/pixmaps
 respectively.
 .
 Ideally those paths should be configurable at build time.
Author: Daniel Hartwig <mand...@gmail.com>
Bug: http://code.google.com/p/distcc/issues/detail?id=111
Bug-Ubuntu: https://bugs.launchpad.net/bugs/512288

--- a/source/Makefile.in
+++ b/source/Makefile.in
@@ -113,7 +113,8 @@
 	$(conf_files)                                           \
 	$(default_files)                                        \
 	$(dist_extra)						\
-	$(gnome_data)
+	$(desktop_files)					\
+	$(icon_files)
 
 dist_dirs = m4 include_server/test_data
 
@@ -373,8 +374,11 @@
 	   man/pump_1.html man/include_server_1.html man/distccmon-gnome_1.html
 MEN = $(man1_MEN)
 
-gnome_data = gnome/distccmon-gnome-icon.png	\
-	gnome/distccmon-gnome.desktop
+desktopdir = $(datadir)/applications
+desktop_files = gnome/distccmon-gnome.desktop
+
+icondir = $(datadir)/pixmaps
+icon_files = gnome/distccmon-gnome-icon.png
 
 popt_OBJS=popt/findme.o  popt/popt.o  popt/poptconfig.o \
 	popt/popthelp.o popt/poptparse.o
@@ -1085,10 +1089,14 @@
 	$(INSTALL_DATA) "$(srcdir)/$$p" "$(DESTDIR)$(docdir)/example" || exit 1; \
 	done
 
-install-gnome-data: $(gnome_data)
-	$(mkinstalldirs) "$(DESTDIR)$(pkgdatadir)"
-	for p in $(gnome_data); do				\
-	$(INSTALL_DATA) "$$p" "$(DESTDIR)$(pkgdatadir)" || exit 1; \
+install-gnome-data: $(desktop_files) $(icon_files)
+	$(mkinstalldirs) "$(DESTDIR)$(desktopdir)"
+	$(mkinstalldirs) "$(DESTDIR)$(icondir)"
+	for p in $(desktop_files); do				\
+	$(INSTALL_DATA) "$$p" "$(DESTDIR)$(desktopdir)" || exit 1; \
+	done
+	for p in $(icon_files); do				\
+	$(INSTALL_DATA) "$$p" "$(DESTDIR)$(icondir)" || exit 1; \
 	done
 
 install-conf: $(conf_files) $(default_files)
@@ -1168,11 +1176,16 @@
 	-rmdir "$(DESTDIR)$(docdir)/example"
 
 uninstall-gnome-data:
-	for p in $(gnome_data); do				\
-	  file="$(DESTDIR)$(pkgdir)/`basename $$p`";            \
+	for p in $(icon_files); do                              \
+	  file="$(DESTDIR)$(icondir)/`basename $$p`";           \
+	  if [ -e "$$file" ]; then rm -fv "$$file"; fi          \
+	done
+	for p in $(desktop_files); do                           \
+	  file="$(DESTDIR)$(desktopdir)/`basename $$p`";        \
 	  if [ -e "$$file" ]; then rm -fv "$$file"; fi          \
 	done
-	-[ `basename $(pkgdir)` = $(PACKAGE) ] && rmdir "$(DESTDIR)$(pkgdir)"
+	-[ `basename $(icondir)` = $(PACKAGE) ] && rmdir "$(DESTDIR)$(icondir)"
+	-[ `basename $(desktopdir)` = $(PACKAGE) ] && rmdir "$(DESTDIR)$(desktopdir)"
 
 uninstall-conf:
 	for p in $(conf_files); do                              \
diff -u b/source/Makefile.in distcc-3.1/source/Makefile.in
--- b/source/Makefile.in
+++ distcc-3.1/source/Makefile.in       2015-01-05 14:21:29.006455909 +0800
@@ -55,7 +55,7 @@
 
 # These must be done from here, not from autoconf, because they can 
 # contain variable expansions written in Make syntax.  Ew.
-DIR_DEFS = -DSYSCONFDIR="\"${sysconfdir}\"" -DPKGDATADIR="\"${pkgdatadir}\""
+DIR_DEFS = -DSYSCONFDIR="\"${sysconfdir}\"" -DPKGDATADIR="\"${pkgdatadir}\"" 
-DICONDIR="\"${icondir}\""
 
 # arguments to pkgconfig
 GNOME_PACKAGES = @GNOME_PACKAGES@
only in patch2:
unchanged:
--- distcc-3.1.orig/source/src/mon-gnome.c      2015-01-05 12:16:21.000000000 
+0800
+++ distcc-3.1/source/src/mon-gnome.c   2015-01-05 14:15:01.417143103 +0800
@@ -599,7 +599,7 @@
 
 #if GTK_CHECK_VERSION(2,2,0)
   gtk_window_set_icon_from_file (GTK_WINDOW (mainwin),
-                                 PKGDATADIR "/distccmon-gnome-icon.png",
+                                 ICONDIR "/distccmon-gnome-icon.png",
                                  NULL);
 #endif
 

Attachment: signature.asc
Description: Digital signature

Reply via email to