Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

How can I install a package in Gnu Octave? I have tried, for example, with the splines-package after downloading it in my home directory with:

Octave1>> pkg install splines-1.0.7.tar.gz

I get the following error message:

couldn't create installation directory /usr/share/octave/packages/3.2/splines-1.0.7     
: Permission denied
error: called from `pkg>copy_files' in file /usr/share/octave/3.2.4/m/pkg/pkg.m near line 1431, column 7
error: called from:
error:   /usr/share/octave/3.2.4/m/pkg/pkg.m at line 756, column 5
error:   /usr/share/octave/3.2.4/m/pkg/pkg.m at line 287, column 7
share|improve this question
up vote 2 down vote accepted

run Octave as SU:

sudo octave

and then try the same as You did.

share|improve this answer
    
Thank you, now everything works well. – Mac-Cherony Feb 13 '12 at 11:35

or sudo -i then octave Before you run octave, you must download and store the package to /usr/share/octave/packages

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.