[Pkg-octave-commit] r935 - in octave/trunk/debian: in patches

Thomas Weber thomas-guest at alioth.debian.org
Thu May 24 17:23:23 UTC 2007


Author: thomas-guest
Date: 2007-05-24 17:23:23 +0000 (Thu, 24 May 2007)
New Revision: 935

Added:
   octave/trunk/debian/patches/50_fix_pkg_rebuild.m.dpatch
Modified:
   octave/trunk/debian/in/octave2.9-00list
Log:
Fix for pkg -rebuild, see ##DP: line in patch


Modified: octave/trunk/debian/in/octave2.9-00list
===================================================================
--- octave/trunk/debian/in/octave2.9-00list	2007-05-24 15:21:29 UTC (rev 934)
+++ octave/trunk/debian/in/octave2.9-00list	2007-05-24 17:23:23 UTC (rev 935)
@@ -1 +1,2 @@
 50_octave-bug-tempfile
+50_fix_pkg_rebuild.m.dpatch

Added: octave/trunk/debian/patches/50_fix_pkg_rebuild.m.dpatch
===================================================================
--- octave/trunk/debian/patches/50_fix_pkg_rebuild.m.dpatch	                        (rev 0)
+++ octave/trunk/debian/patches/50_fix_pkg_rebuild.m.dpatch	2007-05-24 17:23:23 UTC (rev 935)
@@ -0,0 +1,49 @@
+#! /bin/sh /usr/share/dpatch/dpatch-run
+## 50_fix_pkg_rebuild.m.dpatch by Thomas Weber <thomas.weber.mail at gmail.com>
+##
+## All lines beginning with `## DP:' are a description of the patch.
+## DP: Fix -rebuild issue with pkg.m, patch taken from CVS, version 1.47
+## DP: http://www.nabble.com/Small-bug-in-%22pkg-rebuild%22-tf3807246.html
+
+ at DPATCH@
+diff -urNad octave-2.9.12~/scripts/pkg/pkg.m octave-2.9.12/scripts/pkg/pkg.m
+--- octave-2.9.12~/scripts/pkg/pkg.m	2007-05-22 19:25:29.000000000 +0000
++++ octave-2.9.12/scripts/pkg/pkg.m	2007-05-24 18:24:31.000000000 +0000
+@@ -291,7 +291,7 @@
+ 
+     case "rebuild"
+       if (global_install)
+-	global_packages = rebuild (prefix, global_list, auto, verbose);
++	global_packages = rebuild (prefix, global_list, files,  auto, verbose);
+ 	save (global_list, "global_packages");
+ 	local_packages = global_packages;
+       else
+@@ -315,9 +315,12 @@
+   else
+     old_descriptions = installed_packages (list, list);
+     wd = pwd ();
+-    cd (prefix);
+-    dirlist = glob (cellfun(@(x) [x, '-*'], files, 'UniformOutput', 0))
+-    cd (wd);
++    unwind_protect
++      cd (prefix);
++      dirlist = glob (cellfun(@(x) [x, '-*'], files, 'UniformOutput', 0))
++    unwind_protect_cleanup
++      cd (wd);
++    end_unwind_protect
+   endif
+   descriptions = {};
+   for k = 1:length (dirlist)
+@@ -351,10 +354,10 @@
+     endif
+   endfor
+ 
+-  if (isempty (files))
++  if (! isempty (files))
+     ## We are rebuilding for a particular package(s) so we should take
+     ## care to keep the other untouched packages in the descriptions
+-    descriptions = {desriptions{:}, old_desriptions{:}};
++    descriptions = {descriptions{:}, old_descriptions{:}};
+ 
+     dup = [];
+     for i = 1:length (descriptions)


Property changes on: octave/trunk/debian/patches/50_fix_pkg_rebuild.m.dpatch
___________________________________________________________________
Name: svn:executable
   + *




More information about the Pkg-octave-commit mailing list