[Pkg-octave-devel] Removal of SWIG octave-forge packages

Rafael Laboissiere rafael at debian.org
Sat May 16 14:42:30 UTC 2009


* Thomas Weber <thomas.weber.mail at gmail.com> [2009-05-16 11:26]:

> Removal request filed for octave-ftp.
> 
> I also sent an explaining e-mail to the ITPs for octave-ann and
> octave-database. The latter will probably be rewritten in the near
> future.

I have thought a little bit about this and also reread the relevant
thread in bug-octave [1].  I think that there is no hope in waiting this
bug to be fixed for Octave 3.0.  John Eaton has expressed clearly that,
although the bug does not seem to happen in the 3.1 branch, he has no
desire to backport the fix into 3.0.  

Actually, it is not really a bug, but an unfortunate case of global
variables been defined in a .oct function (BTW, this may happen to
anybody, not only with code generated by SWIG).

Now, I propose the following: since it is not really desirable to prevent
users of using octave-ann and other SWIG-based packages, we could force
all of them to have "Autoload: no".  Furthermore, we could add a warning
when the package is loaded by the user.

I implemented the above for octave-ann in patches autoload-no.diff (Git
commit d9f3669 [2]) and warn-clear-all-at-init.diff (Git commit d27be0e
[3]). With these changes, we have:

$ dpkg -l octave-ann | grep ^ii
ii  octave-ann                        1.0.2+dfsg-1                octave binding to the approximate nearest neighbors library
$ octave -q
octave:1> foo = 0;
octave:2> clear all
octave:3> pkg load ann
warning: You loaded the ann module.
A call to "clear all" from now on will make Octave crash.
You have been warned.
octave:4> clear all
panic: Segmentation fault -- stopping myself...
attempting to save variables to `octave-core'...
save to `octave-core' complete
Segmentation fault
$

Do you think that this is acceptable?

[1] http://www.nabble.com/"clear-all"-problem-for-classes-defined-in-oct-files-(Was%3A-%3A-bug)-(Concerns%3A-SWIG)-td17473917.html#a17473917
[2] http://git.debian.org/?p=pkg-octave/octave-ann.git;a=commit;h=d9f36695b2d222a2848504618d2421dc725abfb1
[3] http://git.debian.org/?p=pkg-octave/octave-ann.git;a=commit;h=d27be0e0f7611e5189f7c4b4bc9b73b602f049f5

-- 
Rafael



More information about the Pkg-octave-devel mailing list