r21979 - in /trunk/libcurses-widgets-perl: Widgets.pm Widgets/ListBox.pm debian/changelog debian/control debian/patches/ debian/patches/border-0.patch debian/patches/bottom-element.patch debian/patches/series debian/rules

gregoa at users.alioth.debian.org gregoa at users.alioth.debian.org
Fri Jun 20 17:08:59 UTC 2008


Author: gregoa
Date: Fri Jun 20 17:08:59 2008
New Revision: 21979

URL: http://svn.debian.org/wsvn/pkg-perl/?sc=1&rev=21979
Log:
* Refresh debian/rules, no functional changes. Don't install README any
  more.
* Split out changes to upstream code into proper patches; add quilt
  framework.

Added:
    trunk/libcurses-widgets-perl/debian/patches/
    trunk/libcurses-widgets-perl/debian/patches/border-0.patch
    trunk/libcurses-widgets-perl/debian/patches/bottom-element.patch
    trunk/libcurses-widgets-perl/debian/patches/series
Modified:
    trunk/libcurses-widgets-perl/Widgets.pm
    trunk/libcurses-widgets-perl/Widgets/ListBox.pm
    trunk/libcurses-widgets-perl/debian/changelog
    trunk/libcurses-widgets-perl/debian/control
    trunk/libcurses-widgets-perl/debian/rules

Modified: trunk/libcurses-widgets-perl/Widgets.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libcurses-widgets-perl/Widgets.pm?rev=21979&op=diff
==============================================================================
--- trunk/libcurses-widgets-perl/Widgets.pm (original)
+++ trunk/libcurses-widgets-perl/Widgets.pm Fri Jun 20 17:08:59 2008
@@ -719,7 +719,6 @@
   my $self = shift;
   my $mwh = shift;
   my $active = shift;
-  my $conf = $self->{CONF};
   my (@geom, $dwh, $cwh);
 
   # Get the canvas geometry and create a window handle to it
@@ -731,7 +730,7 @@
   $self->_caption($dwh);
 
   # Get the content area geometry and create a window handle to it
-  $cwh = $$conf{BORDER} ? $self->_canvas($dwh, $self->_cgeometry) : $dwh;
+  $cwh = $self->_canvas($dwh, $self->_cgeometry);
   unless (defined $cwh) {
     $dwh->delwin;
     return 0;
@@ -741,10 +740,8 @@
   $self->_cursor($cwh) if $active;
 
   # Flush the changes to the screen and release the window handles
-  if ($$conf{BORDER}) {
-  	$cwh->refresh;
-  	$cwh->delwin;
-  }
+  $cwh->refresh;
+  $cwh->delwin;
   $dwh->refresh;
   $dwh->delwin;
 

Modified: trunk/libcurses-widgets-perl/Widgets/ListBox.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libcurses-widgets-perl/Widgets/ListBox.pm?rev=21979&op=diff
==============================================================================
--- trunk/libcurses-widgets-perl/Widgets/ListBox.pm (original)
+++ trunk/libcurses-widgets-perl/Widgets/ListBox.pm Fri Jun 20 17:08:59 2008
@@ -314,8 +314,6 @@
   my $sel = $$conf{VALUE};
   my @items = @{$$conf{LISTITEMS}};
   my $pos = $$conf{CURSORPOS};
-  my $top = $$conf{TOPELEMENT};
-  my $lines = $$conf{LINES};
   my $re = $$conf{TOGGLE};
   my $np;
 
@@ -339,23 +337,17 @@
       if ($in eq KEY_HOME) {
         beep if $pos == 0;
         $pos = 0;
-        $top = 0;
       } elsif ($in eq KEY_END) {
         beep if $pos == $#items;
         $pos = $#items;
-        $top = $#items - $lines + 1;
       } elsif ($in eq KEY_PPAGE) {
         beep if $pos == 0;
-        $pos -= ($lines - 1);
-        $top -= ($lines - 1);
+        $pos -= $$conf{LINES};
         $pos = 0 if $pos < 0;
-        $top = 0 if $top < 0;
       } elsif ($in eq KEY_NPAGE) {
         beep if $pos == $#items;
-        $pos += ($lines - 1);
-        $top += ($lines - 1);
+        $pos += $$conf{LINES};
         $pos = $#items if $pos > $#items;
-        $top = ($#items - $lines + 1) if $pos > ($#items - $lines + 1);
       }
     } else {
       beep;
@@ -385,7 +377,7 @@
   }
 
   # Save the changes
-  @$conf{qw(VALUE CURSORPOS TOPELEMENT)} = ($sel, $pos, $top);
+  @$conf{qw(VALUE CURSORPOS)} = ($sel, $pos);
 }
 
 sub match_key {

Modified: trunk/libcurses-widgets-perl/debian/changelog
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libcurses-widgets-perl/debian/changelog?rev=21979&op=diff
==============================================================================
--- trunk/libcurses-widgets-perl/debian/changelog (original)
+++ trunk/libcurses-widgets-perl/debian/changelog Fri Jun 20 17:08:59 2008
@@ -5,6 +5,10 @@
     Vcs-Svn fields.
   * debian/rules: remove /usr/lib/perl5 directory only if it exists.
   * debian/watch: use dist-based URL.
+  * Refresh debian/rules, no functional changes. Don't install README any
+    more.
+  * Split out changes to upstream code into proper patches; add quilt
+    framework.
 
  -- gregor herrmann <gregor+debian at comodo.priv.at>  Tue, 09 Oct 2007 22:28:25 +0200
 

Modified: trunk/libcurses-widgets-perl/debian/control
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libcurses-widgets-perl/debian/control?rev=21979&op=diff
==============================================================================
--- trunk/libcurses-widgets-perl/debian/control (original)
+++ trunk/libcurses-widgets-perl/debian/control Fri Jun 20 17:08:59 2008
@@ -7,7 +7,7 @@
 Homepage: http://search.cpan.org/dist/Curses-Widgets/
 Vcs-Svn: svn://svn.debian.org/pkg-perl/trunk/libcurses-widgets-perl/
 Vcs-Browser: http://svn.debian.org/wsvn/pkg-perl/trunk/libcurses-widgets-perl/
-Build-Depends: debhelper (>> 4)
+Build-Depends: debhelper (>> 4), quilt (>= 0.40)
 Build-Depends-Indep: perl (>> 5.8.1), libcurses-perl
 
 Package: libcurses-widgets-perl

Added: trunk/libcurses-widgets-perl/debian/patches/border-0.patch
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libcurses-widgets-perl/debian/patches/border-0.patch?rev=21979&op=file
==============================================================================
--- trunk/libcurses-widgets-perl/debian/patches/border-0.patch (added)
+++ trunk/libcurses-widgets-perl/debian/patches/border-0.patch Fri Jun 20 17:08:59 2008
@@ -1,0 +1,36 @@
+Author: David Moreno Garza <damog at debian.org>
+Description: BORDER => 0 now displaying widgets
+Bug: #341715
+
+--- libcurses-widgets-perl-1.997.orig/Widgets.pm
++++ libcurses-widgets-perl-1.997/Widgets.pm
+@@ -719,6 +719,7 @@
+   my $self = shift;
+   my $mwh = shift;
+   my $active = shift;
++  my $conf = $self->{CONF};
+   my (@geom, $dwh, $cwh);
+ 
+   # Get the canvas geometry and create a window handle to it
+@@ -730,7 +731,7 @@
+   $self->_caption($dwh);
+ 
+   # Get the content area geometry and create a window handle to it
+-  $cwh = $self->_canvas($dwh, $self->_cgeometry);
++  $cwh = $$conf{BORDER} ? $self->_canvas($dwh, $self->_cgeometry) : $dwh;
+   unless (defined $cwh) {
+     $dwh->delwin;
+     return 0;
+@@ -740,8 +741,10 @@
+   $self->_cursor($cwh) if $active;
+ 
+   # Flush the changes to the screen and release the window handles
+-  $cwh->refresh;
+-  $cwh->delwin;
++  if ($$conf{BORDER}) {
++  	$cwh->refresh;
++  	$cwh->delwin;
++  }
+   $dwh->refresh;
+   $dwh->delwin;
+ 

Added: trunk/libcurses-widgets-perl/debian/patches/bottom-element.patch
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libcurses-widgets-perl/debian/patches/bottom-element.patch?rev=21979&op=file
==============================================================================
--- trunk/libcurses-widgets-perl/debian/patches/bottom-element.patch (added)
+++ trunk/libcurses-widgets-perl/debian/patches/bottom-element.patch Fri Jun 20 17:08:59 2008
@@ -1,0 +1,51 @@
+Author: Stephen Zander <gibreel at debian.org>
+Description: make ListBox.pm keep the bottom element of a list in view when
+paging down & the top element of a list in view when paging up,
+Bug: #171719
+
+--- libcurses-widgets-perl-1.997.orig/Widgets/ListBox.pm
++++ libcurses-widgets-perl-1.997/Widgets/ListBox.pm
+@@ -314,6 +314,8 @@
+   my $sel = $$conf{VALUE};
+   my @items = @{$$conf{LISTITEMS}};
+   my $pos = $$conf{CURSORPOS};
++  my $top = $$conf{TOPELEMENT};
++  my $lines = $$conf{LINES};
+   my $re = $$conf{TOGGLE};
+   my $np;
+ 
+@@ -337,17 +339,23 @@
+       if ($in eq KEY_HOME) {
+         beep if $pos == 0;
+         $pos = 0;
++        $top = 0;
+       } elsif ($in eq KEY_END) {
+         beep if $pos == $#items;
+         $pos = $#items;
++        $top = $#items - $lines + 1;
+       } elsif ($in eq KEY_PPAGE) {
+         beep if $pos == 0;
+-        $pos -= $$conf{LINES};
++        $pos -= ($lines - 1);
++        $top -= ($lines - 1);
+         $pos = 0 if $pos < 0;
++        $top = 0 if $top < 0;
+       } elsif ($in eq KEY_NPAGE) {
+         beep if $pos == $#items;
+-        $pos += $$conf{LINES};
++        $pos += ($lines - 1);
++        $top += ($lines - 1);
+         $pos = $#items if $pos > $#items;
++        $top = ($#items - $lines + 1) if $pos > ($#items - $lines + 1);
+       }
+     } else {
+       beep;
+@@ -377,7 +385,7 @@
+   }
+ 
+   # Save the changes
+-  @$conf{qw(VALUE CURSORPOS)} = ($sel, $pos);
++  @$conf{qw(VALUE CURSORPOS TOPELEMENT)} = ($sel, $pos, $top);
+ }
+ 
+ sub match_key {

Added: trunk/libcurses-widgets-perl/debian/patches/series
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libcurses-widgets-perl/debian/patches/series?rev=21979&op=file
==============================================================================
--- trunk/libcurses-widgets-perl/debian/patches/series (added)
+++ trunk/libcurses-widgets-perl/debian/patches/series Fri Jun 20 17:08:59 2008
@@ -1,0 +1,2 @@
+border-0.patch
+bottom-element.patch

Modified: trunk/libcurses-widgets-perl/debian/rules
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libcurses-widgets-perl/debian/rules?rev=21979&op=diff
==============================================================================
--- trunk/libcurses-widgets-perl/debian/rules (original)
+++ trunk/libcurses-widgets-perl/debian/rules Fri Jun 20 17:08:59 2008
@@ -1,57 +1,63 @@
-#! /usr/bin/make -f
-# -*-makefile-*-
-# debian/rules file for libcurses-widgets-perl
+#!/usr/bin/make -f
+# This debian/rules file is provided as a template for normal perl
+# packages. It was created by Marc Brockschmidt <marc at dch-faq.de> for
+# the Debian Perl Group (http://pkg-perl.alioth.debian.org/) but may
+# be used freely wherever it is useful.
 
-PERL	?= /usr/bin/perl
+# Uncomment this to turn on verbose mode.
+#export DH_VERBOSE=1
 
-package	:= $(firstword $(shell dh_listpackages))
-prefix	:= $(CURDIR)/debian/$(package)/usr
+# If set to a true value then MakeMaker's prompt function will
+# always return the default without waiting for user input.
+export PERL_MM_USE_DEFAULT=1
 
-version	:= $(shell dpkg-parsechangelog | \
-			sed -ne 's/^Version: *\([0-9]\+:\)*//p')
+include /usr/share/quilt/quilt.make
 
-tag:
-	cvs tag -c -F $(subst .,_,debian_version_$(version))
-ifeq ($(findstring -,$(version)),)
-	cvs tag -c -F $(subst .,_,upstream_version_$(version))
-endif
+PERL   ?= /usr/bin/perl
+PACKAGE = $(shell dh_listpackages)
+TMP     = $(CURDIR)/debian/$(PACKAGE)
 
-build:	build-stamp
-build-stamp:
+build: build-stamp
+build-stamp: $(QUILT_STAMPFN)
 	dh_testdir
-	$(PERL) Makefile.PL INSTALLDIRS=vendor PERL=$(PERL)
+	$(PERL) Makefile.PL INSTALLDIRS=vendor
+	$(MAKE)
 	# No, we don't run make test. Don't include it - Interactive :-/
-	$(MAKE) LD_RUN_PATH=
+	# $(MAKE) test
 	touch $@
 
-clean:	checkroot
-	rm -f build-stamp
-	[ ! -f Makefile ] || $(MAKE) distclean
-	dh_clean
+clean: unpatch
+	dh_testdir
+	dh_testroot
+	dh_clean build-stamp install-stamp
+	[ ! -f Makefile ] || $(MAKE) realclean
 
-binary-indep:	checkroot build
-	dh_clean
-	dh_installdirs
+install: install-stamp
+install-stamp: build-stamp
+	dh_testdir
+	dh_testroot
+	dh_clean -k
+	$(MAKE) install DESTDIR=$(TMP) PREFIX=/usr
+	[ ! -d $(TMP)/usr/lib/perl5 ] || \
+		rmdir --ignore-fail-on-non-empty --parents --verbose \
+		$(TMP)/usr/lib/perl5
+	touch $@
 
-	$(MAKE) pure_install PREFIX=$(prefix)
-	[ ! -d $(prefix)/lib/perl5 ] || rmdir --ignore-fail-on-non-empty --parents $(prefix)/lib/perl5
-	dh_installdocs README
+binary-arch:
+# We have nothing to do here for an architecture-independent package
+
+binary-indep: build install
+	dh_testdir
+	dh_testroot
+	dh_installdocs
 	dh_installchangelogs CHANGELOG
-
+	dh_perl
 	dh_compress
 	dh_fixperms
-	dh_perl
 	dh_installdeb
 	dh_gencontrol
 	dh_md5sums
 	dh_builddeb
 
-binary-arch:	checkroot build
-
-binary:	binary-indep binary-arch
-
-checkroot:
-	dh_testdir
-	dh_testroot
-
-.PHONY:	binary binary-arch binary-indep clean checkroot build
+binary: binary-indep binary-arch
+.PHONY: build clean binary-indep binary-arch binary install




More information about the Pkg-perl-cvs-commits mailing list