Package: djvulibre
Severity: wishlist
Tags: patch

Hi,

it would be nice to have a -dbg package with the djvulibre debug
symbols. The current libdjvulibre21 is basically undebuggable with eg
gdb, also because the default CFLAGS include -03.

The attached patch (not that polished nor probably correct) can be a
base for providing such package, and making djvulibre debuggable.

Thanks

-- System Information:
Debian Release: lenny/sid
  APT prefers testing
  APT policy: (850, 'testing'), (800, 'unstable'), (750, 'experimental')
Architecture: amd64 (x86_64)

Kernel: Linux 2.6.25-2-amd64 (SMP w/2 CPU cores)
Locale: LANG=it_IT.UTF-8, LC_CTYPE=it_IT.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/bash
diff -ur djvulibre-3.5.20.orig/debian/changelog djvulibre-3.5.20/debian/changelog
--- djvulibre-3.5.20.orig/debian/changelog	2008-08-02 12:08:54.000000000 +0200
+++ djvulibre-3.5.20/debian/changelog	2008-08-02 10:50:21.000000000 +0200
@@ -1,3 +1,9 @@
+djvulibre (3.5.20-9) unstable; urgency=low
+
+  * Add djvulibre-dbg package with debug symbols.
+  
+ -- Pino Toscano <[EMAIL PROTECTED]>  Sat, 02 Aug 2008 10:50:21 +0200
+
 djvulibre (3.5.20-8) unstable; urgency=low
 
   * Raise djvudigital default resolution from 300 to 600 (closes: #478607)
diff -ur djvulibre-3.5.20.orig/debian/control djvulibre-3.5.20/debian/control
--- djvulibre-3.5.20.orig/debian/control	2008-08-02 12:08:54.000000000 +0200
+++ djvulibre-3.5.20/debian/control	2008-08-02 10:49:17.000000000 +0200
@@ -36,6 +36,13 @@
 Description: Runtime support for the DjVu image format
  DjVu runtime library.
 
+Package: djvulibre-dbg
+Section: libs
+Architecture: any
+Depends: libdjvulibre21 (= ${binary:Version})
+Description: Debug symbols for the DjVu image format
+ DjVu runtime debug symbols.
+
 Package: djvulibre-desktop
 Section: libs
 Architecture: any
diff -ur djvulibre-3.5.20.orig/debian/rules djvulibre-3.5.20/debian/rules
--- djvulibre-3.5.20.orig/debian/rules	2008-08-02 12:08:54.000000000 +0200
+++ djvulibre-3.5.20/debian/rules	2008-08-02 11:21:10.000000000 +0200
@@ -10,6 +10,7 @@
 # from having to guess our platform (since we know it already)
 DEB_HOST_GNU_TYPE   ?= $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE)
 DEB_BUILD_GNU_TYPE  ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE)
+DEB_BUILD_OPTIONS   ?= debug nostrip
 
 SHELL=/bin/bash
 
@@ -34,7 +35,7 @@
 else ifeq ($(DEB_HOST_GNU_TYPE),alpha-linux-gnu) # alpha GCC 4.1/4.2 breakage
 	CFLAGS += -O0
 else
-	CFLAGS += -O3
+	CFLAGS += -O2
 endif
 
 # extract library major version from source build system
@@ -155,7 +156,7 @@
 	dh_installchangelogs
 	-dh_icons		# hyphen protects pre-dh_icons systems like etch
 	dh_link
-	dh_strip
+	dh_strip --dbg-package=djvulibre-dbg
 	dh_compress --exclude=.djvu
 	dh_fixperms
 	dh_makeshlibs --version-info --exclude=/plugins

Reply via email to