[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Bug when installing packages
From: |
Dr. Alexander Klein |
Subject: |
Bug when installing packages |
Date: |
Fri, 26 Aug 2011 13:04:11 +0200 |
Hello,
While trying to install some packages from octave-forge under
Octave-3.2.3, which is the latest available in Xubuntu 10.04, I have
encountered the following bug:
Although I try to force an install in local mode, pkg install -local
always wants to put the packages in the global directory, which is not
writable, of course. When I tried to debug pkg I got the following
result:
octave:4> dbstop ("pkg",1)
ans = 200
octave:5> pkg install -local "struct-1.0.9.tar.gz"
pkg: line 200, column 1
keyboard: stopped in /usr/share/octave/3.2.3/m/pkg/pkg.m at line 200
200: persistent user_prefix = false;
debug> user_prefix
error: `user_prefix' undefined near line 5 column 1
debug> dbstep
pkg: line 201, column 3
keyboard: stopped in /usr/share/octave/3.2.3/m/pkg/pkg.m at line 201
201: persistent prefix = -1;
debug> user_prefix
user_prefix = 1
debug> prefix
error: `prefix' undefined near line 5 column 1
debug> dbstep
pkg: line 202, column 3
keyboard: stopped in /usr/share/octave/3.2.3/m/pkg/pkg.m at line 202
202: persistent archprefix = -1;
debug> prefix
prefix = /usr/share/octave/packages/3.2
Obviously, neither user_prefix nor prefix are initialised, so pkg has
run before, probably during startup and with a prefix issued.
Later on in pkg, at line 245, user_prefix being persistently true
seems to prevent "-local" from ever becoming effective again:
case "-local"
global_install = false;
if (! user_prefix)
prefix = tilde_expand (fullfile ("~", "octave"));
archprefix = prefix;
endif
The easiest fix I see would be to remove the persistence of
user_prefix, which would necessitate issuing the prefix in each pkg
command. A bit less convenient, but still more transparent I'd think.
Then again, maybe someone else has a better idea?
Kind regards,
Alex
--
Dr. Alexander Klein, Diplom-Mathematiker
Physiologisches Institut | TransMIT Zentrum
Raum 543 | für Numerische Methoden
Aulweg 129 | Heinrich-Buff-Ring 44
35392 Giessen | 35392 Giessen
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- Bug when installing packages,
Dr. Alexander Klein <=