Error installation for octave-optim from Octave Forge in Arch Linux

Error installation for octave-optim

  • How can I replicate the Octave problem?

Over Arch Linux system (virtual machine, docker container o real machine) install some AUR helper or in other hand install octave, the dependencies octave-statistics, octave-struct, later run

$ git clone https://aur.archlinux.org/octave-optim.git
$ cd octave-optim
$ makepkg
  • What did I expect to happen and what did happen?

I expect that the package will be installed as 1 week ago, but we have an error message.

error: parse error near line 118 of file /tmp/makepkg/octave-optim/src/install_prefix/optim-1.6.1/lsqlin.m

  n_out: invalid use of symbol as both variable and command

>>>     n_out --;
       ^
error: called from
    doc_cache_create>create_cache at line 116 column 20
    gen_doc_cache_in_dir>@<anonymous> at line 150 column 16
    doc_cache_create>gen_doc_cache_in_dir at line 151 column 9
    doc_cache_create at line 62 column 12
    install>generate_lookfor_cache at line 840 column 5
    install at line 241 column 7
    pkg at line 603 column 9

System

  • OS: Arch Linux
  • Octave version: e.g. 7.1.0-1
  • Installation method: From [community] repository with pacman package manager.
  • octave-optim from Arch User Repository.

octave-optim-log.txt (35.6 KB)

That is probably bug #60920, [octave forge] (optim) New warnings on loading package
The bug has been fixed upstream. But no new release has been made in the meantime.
For possible workarounds, see: Signal package does not install with Octave 7 - help - GNU Octave

Thanks for quick response.

Thank you.

From the savannah link is the comment: “The whitespace before ‘–’ and ‘++’ is now removed in vfzero.m and lsqlin.m. Closing as fixed.”

I edited the two aforementioned files in my 7.1.0 installation as recommended, and I no longer get the following warnings on the “optim” package load:

warning: optimset: no defaults for function ‘vfzero’
warning: called from
all_opts at line 62 column 9
C:\engineer\Octave-7.1.0\mingw64\share\octave\packages\optim-1.6.1\PKG_ADD at line 8 column 5
load_packages_and_dependencies at line 56 column 5
load_packages at line 53 column 3
pkg at line 623 column 7
oustart at line 13 column 1
C:\Users\gwhite.octaverc at line 58 column 1

warning: optimset: no defaults for function ‘lsqlin’
warning: called from
all_opts at line 62 column 9
C:\engineer\Octave-7.1.0\mingw64\share\octave\packages\optim-1.6.1\PKG_ADD at line 10 column 5
load_packages_and_dependencies at line 56 column 5
load_packages at line 53 column 3
pkg at line 623 column 7
oustart at line 13 column 1
C:\Users\gwhite.octaverc at line 58 column 1