[Pkg-octave-devel] compilation with gcc-4.3

John W. Eaton jwe at bevo.che.wisc.edu
Fri Feb 8 09:52:24 UTC 2008


On  8-Feb-2008, Rafael Laboissiere wrote:

| I still cannot replicate the bug.  It is very strange, but I take your word
| (and Pascal's) for it.  I am just curious : which version of GCC did you
| used?  I have here:
| 
| (sid) $ /usr/lib/gcc-snapshot/bin/g++ --version
| g++ (Debian 20080113-1) 4.3.0 20080113 (experimental) [trunk revision 131510]
| Copyright (C) 2007 Free Software Foundation, Inc.
| This is free software; see the source for copying conditions.  There is NO
| warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

I used

  segfault:9> g++-4.3 -v
  Using built-in specs.
  Target: x86_64-linux-gnu
  Configured with: ../src/configure -v --with-pkgversion='Debian 4.3-20080116-1' --with-bugurl=file:///usr/share/doc/gcc-4.3/README.Bugs --enable-languages=c,c++,fortran,objc,obj-c++,treelang --prefix=/usr --enable-shared --with-system-zlib --libexecdir=/usr/lib --without-included-gettext --enable-threads=posix --enable-nls --with-gxx-include-dir=/usr/include/c++/4.3 --program-suffix=-4.3 --enable-clocale=gnu --enable-libstdcxx-debug --enable-mpfr --enable-checking=release --build=x86_64-linux-gnu --host=x86_64-linux-gnu --target=x86_64-linux-gnu
  Thread model: posix
  gcc version 4.3.0 20080116 (experimental) [trunk revision 131577] (Debian 4.3-20080116-1) 
  segfault:10> g++-4.3 --version
  g++-4.3 (Debian 4.3-20080116-1) 4.3.0 20080116 (experimental) [trunk revision 131577]
  Copyright (C) 2007 Free Software Foundation, Inc.
  This is free software; see the source for copying conditions.  There is NO
  warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

| I am interested on compiling octave on arm with this version of g++ to see
| whether the bug in loading oct files would persist.
| 
| > | About the tests, the only one failing is:
| > |  processing /usr/src/octave3.0-3.0.0/scripts/optimization/sqp.m
| > |   ***** test
| > |  x0 = [-1.8; 1.7; 1.9; -0.8; -0.8];
| > | 
| > |  [x, obj, info, iter, nf, lambda] = sqp (x0, @phi, @g, [])
| > | 
| > |  x_opt = [-1.717143501952599;
| > |            1.595709610928535;
| > |            1.827245880097156;
| > |           -0.763643103133572;
| > |           -0.763643068453300];
| > |  obj_opt = 0.0539498477702739
| > | 
| > |  assert (all (abs (x-x_opt) < sqrt (eps)) && abs (obj-obj_opt) < sqrt (eps));
| > | !!!!! test failed
| > | error: error creating function handle "@phi"
| > 
| > This is separate from GCC 4.3, and I think it is fixed in the
| > release-3-0-x branch in my hg archive.
| 
| I might introduce a patch for fixing this bug in the Debian package.  Could
| you please give me a short tutorial on how to extract the patch from hg?

I don't see how this bug can be in Octave 3.0.0, since the tests for
the sqp function were not added until later.

But anyway, you can extract a changset from hg with a command like

  hg export REV

where REV is the changeset id, something like "5a7effe7d8f6".  Using a
single REV will give you the diffs for that version relative to its
parent.

jwe



More information about the Pkg-octave-devel mailing list