tags 515316 + patch
thank you
Hi,
Here is a debdiff that includes a fix for this, building with gcc-4.3,
adding a desktop file and bringing the package up to date. Hope it helps.
Thanks,
Barry deFreese
Debian QA
diff -u grpn-1.1.2/debian/changelog grpn-1.1.2/debian/changelog
--- grpn-1.1.2/debian/changelog
+++ grpn-1.1.2/debian/changelog
@@ -1,3 +1,24 @@
+grpn (1.1.2-2.1) hardy; urgency=low
+
+ * Build with Gtk2. (Closes: #515316).
+ + Change libgtk1.2-dev build-dep to libgtk2.0-dev.
+ + 03_gtk2.dpatch.
+ * Added .desktop file (Closes: #375515)
+ + Thanks to Vassilis Pandis.
+ * debian/patches/02_add_includes.dpatch: add missing includes
+ + Thanks to Michael Bienia.
+ * Make clean not ignore errors.
+ * Add ${misc:Depends} for debhelper package.
+ * Quote strings in menu file.
+ * Add appropriate copyright holder to debian/copyright.
+ * Version path to GPL license. (GPL-2).
+ * Bump debhelper build-dep to >= 5.
+ * Move DH_COMPAT from rules to debian/compat and set to 5.
+ * Bump Standards Version to 3.8.0.
+ + Menu policy transition.
+
+ -- Barry deFreese <bdefre...@debian.org> Wed, 25 Feb 2009 15:47:20 -0500
+
grpn (1.1.2-2) unstable; urgency=low
* Fixed problems with locale (Closes: #253415)
diff -u grpn-1.1.2/debian/copyright grpn-1.1.2/debian/copyright
--- grpn-1.1.2/debian/copyright
+++ grpn-1.1.2/debian/copyright
@@ -7,7 +7,8 @@
-Author:
-Paul Wilkins <paul.wilk...@analog.com>
+Upstream Author: Paul Wilkins <paul.wilk...@analog.com>
-Copyright:
+Copyright: Copyright (C) 2000,2002 Paul Wilkins <paul.wilk...@analog.com>
+
+License:
GPL (GNU GPL license v2 included in source code)
The GNU GPL may be viewed on Debian GNU/Linux systems in
-/usr/share/common-licenses/GPL
+/usr/share/common-licenses/GPL-2
diff -u grpn-1.1.2/debian/control grpn-1.1.2/debian/control
--- grpn-1.1.2/debian/control
+++ grpn-1.1.2/debian/control
@@ -2,12 +2,12 @@
Section: math
Priority: extra
Maintainer: Wartan Hachaturow <w...@debian.org>
-Build-Depends: libgtk1.2-dev, debhelper (>= 4), dpatch
-Standards-Version: 3.5.2.0
+Build-Depends: debhelper (>= 5), dpatch, libgtk2.0-dev
+Standards-Version: 3.8.0
Package: grpn
Architecture: any
-Depends: ${shlibs:Depends}
+Depends: ${shlibs:Depends}, ${misc:Depends}
Description: GTK+ reverse polish notation calculator
grpn is an RPN calculator which uses the GTK+ widgets. It
works with real and complex numbers, has 4 different radix
diff -u grpn-1.1.2/debian/patches/00list grpn-1.1.2/debian/patches/00list
--- grpn-1.1.2/debian/patches/00list
+++ grpn-1.1.2/debian/patches/00list
@@ -1,0 +2,2 @@
+02_add_includes
+03_gtk2.dpatch
diff -u grpn-1.1.2/debian/rules grpn-1.1.2/debian/rules
--- grpn-1.1.2/debian/rules
+++ grpn-1.1.2/debian/rules
@@ -5,8 +5,6 @@
# Uncomment this to turn on verbose mode.
#export DH_VERBOSE=1
-DH_COMPAT=4
-export DH_COMPAT
PACKAGE=grpn
include /usr/share/dpatch/dpatch.make
@@ -22,7 +20,7 @@
clean1:
dh_testdir
dh_testroot
- -$(MAKE) clean
+ $(MAKE) clean
dh_clean
@@ -32,6 +30,8 @@
dh_testroot
dh_clean -k
dh_installdirs
+ dh_desktop -pgrpn
+ install -D -m644 debian/grpn.desktop
$(CURDIR)/debian/$(PACKAGE)/usr/share/applications/grpn.desktop
install -o root -m 0755 $(CURDIR)/$(PACKAGE)
$(CURDIR)/debian/$(PACKAGE)/usr/bin/
# Build architecture-independent files here.
diff -u grpn-1.1.2/debian/menu grpn-1.1.2/debian/menu
--- grpn-1.1.2/debian/menu
+++ grpn-1.1.2/debian/menu
@@ -1,2 +1,2 @@
-?package(grpn):needs=X11 section=Apps/Math\
+?package(grpn):needs="X11" section="Applications/Science/Mathematics"\
title="grpn" hints="Calculators" command="/usr/bin/grpn"
only in patch2:
unchanged:
--- grpn-1.1.2.orig/debian/grpn.desktop
+++ grpn-1.1.2/debian/grpn.desktop
@@ -0,0 +1,9 @@
+[Desktop Entry]
+Version=1.0
+Name=Grpn Calculator
+GenericName=Calculator
+Comment=A reverse polish notation calculator
+Exec=grpn
+Icon=grpn
+Type=Application
+Categories=Calculator;Utility;
only in patch2:
unchanged:
--- grpn-1.1.2.orig/debian/compat
+++ grpn-1.1.2/debian/compat
@@ -0,0 +1 @@
+5
only in patch2:
unchanged:
--- grpn-1.1.2.orig/debian/patches/03_gtk2.dpatch
+++ grpn-1.1.2/debian/patches/03_gtk2.dpatch
@@ -0,0 +1,67 @@
+#! /bin/sh /usr/share/dpatch/dpatch-run
+## 03_gtk2.dpatch by <bdefre...@debian2.bddebian.com>
+##
+## All lines beginning with `## DP:' are a description of the patch.
+## DP: Build with Gtk2.
+
+...@dpatch@
+diff -urNad grpn-1.1.2~/Makefile grpn-1.1.2/Makefile
+--- grpn-1.1.2~/Makefile 2002-04-04 22:56:05.000000000 -0500
++++ grpn-1.1.2/Makefile 2009-02-25 16:07:39.000000000 -0500
+@@ -8,11 +8,6 @@
+ # What compiler should be used
+ CC = gcc
+
+-# Where to find the gtk-config script
+-GTK_DIR =
+-#GTK_DIR = /loc/libs/gtk+-1.0.6/bin/
+-
+-
+ # NOTE:
+ #
+ # add -DGTK_VER_1_1 to the CFLAGS if you are using GTK version 1.1.0 or higher
+@@ -20,7 +15,7 @@
+ # add -DUSE_GNOME if you want to make grpn GNOME compliant.
+
+
+-CFLAGS = -g -O2 -I/usr/X11/include `$(GTK_DIR)gtk-config --cflags`
-DGTK_VER_1_1
++CFLAGS = -g -O2 -I/usr/X11/include `pkg-config --cflags gtk+-2.0`
-DGTK_VER_1_1
+
+ DFLAGS = -L/usr/X11/lib
+
+@@ -37,7 +32,7 @@
+
+
+
+-LIBS = `$(GTK_DIR)gtk-config --libs` -lX11 -lm
++LIBS = `pkg-config --libs gtk+-2.0` -lX11 -lm
+
+
+ grpn: $(OBJS)
+diff -urNad grpn-1.1.2~/lcd.c grpn-1.1.2/lcd.c
+--- grpn-1.1.2~/lcd.c 2009-02-25 16:06:14.000000000 -0500
++++ grpn-1.1.2/lcd.c 2009-02-25 16:06:45.000000000 -0500
+@@ -679,7 +679,7 @@
+ #else
+ switch(selection->target){
+ #endif
+- case GDK_TARGET_STRING:
++/* case GDK_TARGET_STRING: */
+ case TARGET_STRING:
+ gtk_selection_data_set(
+ selection,
+diff -urNad grpn-1.1.2~/main.c grpn-1.1.2/main.c
+--- grpn-1.1.2~/main.c 2009-02-25 16:06:14.000000000 -0500
++++ grpn-1.1.2/main.c 2009-02-25 16:08:30.000000000 -0500
+@@ -159,8 +159,9 @@
+ exit(0);
+ }
+ new_style = gtk_style_copy(default_style);
+- new_style->font = new_font;
+- gtk_widget_set_default_style(new_style);
++ new_style->font_desc = new_font;
++/* BDD - No longer in Gtk2.x */
++/* gtk_widget_set_default_style(new_style); */
+ }
+
+
only in patch2:
unchanged:
--- grpn-1.1.2.orig/debian/patches/02_add_includes.dpatch
+++ grpn-1.1.2/debian/patches/02_add_includes.dpatch
@@ -0,0 +1,97 @@
+#! /bin/sh /usr/share/dpatch/dpatch-run
+## 02_add_includes.dpatch by Michael Bienia <ge...@ubuntu.com>
+##
+## All lines beginning with `## DP:' are a description of the patch.
+## DP: Add missing includes
+
+...@dpatch@
+
+diff -Nur grpn-1.1.2/callback_menu.c grpn-1.1.2.patched/callback_menu.c
+--- grpn-1.1.2/callback_menu.c 2002-04-04 05:46:10.000000000 +0200
++++ grpn-1.1.2.patched/callback_menu.c 2006-12-13 15:46:29.000000000 +0100
+@@ -20,6 +20,7 @@
+ /* callback_menu.h by Paul Wilkins 3/15/97 */
+
+ #include <stdio.h>
++#include <stdlib.h>
+ #include <gtk/gtk.h>
+
+ #include "menu.h"
+diff -Nur grpn-1.1.2/complex.c grpn-1.1.2.patched/complex.c
+--- grpn-1.1.2/complex.c 2002-04-04 05:46:10.000000000 +0200
++++ grpn-1.1.2.patched/complex.c 2006-12-13 15:43:45.000000000 +0100
+@@ -22,6 +22,7 @@
+ #include <stdio.h>
+ #include <stdlib.h>
+ #include <math.h>
++#include <string.h>
+
+ #include "complex.h"
+ #include "real.h"
+diff -Nur grpn-1.1.2/help.c grpn-1.1.2.patched/help.c
+--- grpn-1.1.2/help.c 2002-04-04 05:46:11.000000000 +0200
++++ grpn-1.1.2.patched/help.c 2006-12-13 15:48:01.000000000 +0100
+@@ -19,6 +19,7 @@
+ */
+ #include <stdio.h>
+ #include <stdlib.h>
++#include <string.h>
+ #include <gtk/gtk.h>
+
+ #include "help.h"
+diff -Nur grpn-1.1.2/lcd.c grpn-1.1.2.patched/lcd.c
+--- grpn-1.1.2/lcd.c 2002-04-04 05:46:11.000000000 +0200
++++ grpn-1.1.2.patched/lcd.c 2006-12-13 15:46:09.000000000 +0100
+@@ -20,6 +20,8 @@
+ /* lcd.c by Paul Wilkins 3/22/97 */
+
+ #include <stdio.h>
++#include <stdlib.h>
++#include <string.h>
+ #include <gtk/gtk.h>
+ #include <gdk/gdkkeysyms.h>
+
+diff -Nur grpn-1.1.2/main.c grpn-1.1.2.patched/main.c
+--- grpn-1.1.2/main.c 2006-12-13 15:58:54.000000000 +0100
++++ grpn-1.1.2.patched/main.c 2006-12-13 15:59:57.000000000 +0100
+@@ -23,6 +23,7 @@
+ */
+
+ #include <stdio.h>
++#include <stdlib.h>
+ #include <locale.h>
+ #ifdef USE_GNOME
+ #include <gnome.h>
+diff -Nur grpn-1.1.2/mode.c grpn-1.1.2.patched/mode.c
+--- grpn-1.1.2/mode.c 2002-04-04 05:46:11.000000000 +0200
++++ grpn-1.1.2.patched/mode.c 2006-12-13 15:48:15.000000000 +0100
+@@ -20,6 +20,7 @@
+ /* setup mode.c by Paul Wilkins 2/8/98 */
+
+ #include <stdio.h>
++#include <string.h>
+ #include <gtk/gtk.h>
+
+ #include "mode.h"
+diff -Nur grpn-1.1.2/process_input.c grpn-1.1.2.patched/process_input.c
+--- grpn-1.1.2/process_input.c 2002-04-04 05:46:11.000000000 +0200
++++ grpn-1.1.2.patched/process_input.c 2006-12-13 15:46:51.000000000 +0100
+@@ -20,6 +20,7 @@
+ /* process_input.c by Paul Wilkins 3/21/97 */
+
+ #include <stdio.h>
++#include <stdlib.h>
+ #include <gtk/gtk.h>
+ #include <gdk/gdkkeysyms.h>
+
+diff -Nur grpn-1.1.2/run_cmd.c grpn-1.1.2.patched/run_cmd.c
+--- grpn-1.1.2/run_cmd.c 2002-04-04 05:46:11.000000000 +0200
++++ grpn-1.1.2.patched/run_cmd.c 2006-12-13 15:44:09.000000000 +0100
+@@ -20,6 +20,7 @@
+ /* run_cmd.c by Paul Wilkins */
+
+ #include <stdio.h>
++#include <string.h>
+ #include <gtk/gtk.h>
+
+ #include "buttons.h"