octave-maintainers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: How to change the autoload status of a single package?


From: David Bateman
Subject: Re: How to change the autoload status of a single package?
Date: Sat, 26 May 2007 21:51:31 +0200
User-agent: Thunderbird 1.5.0.7 (X11/20060921)

Michael Goffioul wrote:
> On 5/25/07, Michael Goffioul <address@hidden> wrote:
>> On 5/25/07, David Bateman <address@hidden> wrote:
>> > Yes, you found my bug in 2.9.12.. Please apply the patch in
>> >
>> >
>> http://www.cae.wisc.edu/pipermail/octave-maintainers/2007-May/002952.html
>> >
>> > In fact I think it probably only affects you at this point..
>>
>> Well, I have to double-check, but I already applied the patch... :-|
> 
> I can confirm that it does not work, even with the proposed patch.
> I don't know exactly how to solve it, but I can explain what's happening:
> in pkg::rebuild, old_descriptions is empty, because installed_packages
> returned {}; looking at pkg::installed_packages, local_packages gets
> empty because all my existing packages are global, and global_packages
> gets also empty because local_list==global_list in this call; hence no
> packages are returned.
> 
> Michael.
> 

This is in fact very strange. The call to pkg:rebuild is

      if (global_install)
        global_packages = rebuild (prefix, global_list, files, auto, verbose);
        save (global_list, "global_packages");
        local_packages = global_packages;
      else
        local_packages = rebuild (prefix, local_list, files, auto, verbose);
        save (local_list, "local_packages");
      endif

So if a global installation is detected, the global_list is passed as
the local_list to installed_packages, and then all following operations
in pkg:rebuild are on the global packages. The new structure is then
saved to the correct file immediately on returning from pkg:rebuild.
This is why I want local_list==global_list for this call, as it avoided
some code duplication. It also appears to work fine for me both as a
normal and as a superuser (global install) under linux..

Did you set the prefix for use the "-local" or "-global" flags? Sorry I
can't duplicate this, so can't fix it..

D.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]