bugGNU Octave - Bugs: bug #52815, Incompatible api-v51 in 4.2.1 vs...

 
 

bug #52815: Incompatible api-v51 in 4.2.1 vs 4.3.0+

Submitter:  Petr Mikulik <mikulik>
Submitted:  Fri 05 Jan 2018 01:43:35 PM UTC
   
 
Category:  Configuration and Build System Severity:  3 - Normal
Priority:  5 - Normal Item Group:  Segfault, Bus Error, etc.
Status:  Fixed Assigned to:  jwe
Originator Name:  Open/Closed:  * Closed
Release:  * dev Operating System:  * GNU/Linux
Fixed Release:  None Planned Release:  None
* Mandatory Fields

Add a New Comment Rich Markup
   

Jump to the original submission

Mon 08 Jan 2018 06:45:41 PM UTC, comment #8: 

With the addtwomatrices.cc file I was able to verify the segfault.  I added a '+' to the OCTAVE_API_VERSION number for the development branch.  I also added a note to etc/CHECKLIST that this variable should be updated at each release.  See http://hg.savannah.gnu.org/hgweb/octave/rev/ac9b4751c223.

Marking as fixed and closing report.

Rik <rik5>
Group administrator
Mon 08 Jan 2018 09:46:01 AM UTC, comment #7: 

My scripts make Octave to segfault.

Trying the helloworld.cc from the examples directory, it fails to load as you indicate.

However, executing other codes from that directory produces different results. For example, "addtwomatrices.cc" segfaults Octave, while "globaldemo.cc" freezes Octave.

Appending "+" to the API name or doing any other rename would be very helpful to avoid loading incompatible .oct files.

Petr Mikulik <mikulik>
Sat 06 Jan 2018 02:56:54 PM UTC, comment #6: 

@Petr: When you say "crashes the other Octave", do you mean there is an actual segfault and you are returned to the shell prompt?

I get an error about not being able to load a library, but that is expected because it was created with the wrong version of Octave.

For testing I used helloworld.cc which is available in the examples/code directory.


~/wip/Projects_Mine/octave-dev/examples/code: octave-4.2.1 -f -q --no-gui
octave:1> mkoctfile helloworld.cc
octave:2> helloworld (1,2)
Hello World has 2 input arguments and 0 output arguments.
octave:3> exit

~/wip/Projects_Mine/octave-dev/examples/code: ../../run-octave -f -q --no-gui
octave:1> helloworld (1,2)
error: /home/rik/wip/Projects_Mine/octave-dev/examples/code/helloworld.oct: failed to load: /home/rik/wip/Projects_Mine/octave-dev/examples/code/helloworld.oct: undefined symbol: _ZN19octave_pager_stream6streamEv
octave:1>


It would be nice if Octave simply warned about the version mismatch (there is a routine check_version for that, but it isn't getting run or maybe the library has to load correctly before the version can be checked), but I don't get a segfault.

Rik <rik5>
Group administrator
Fri 05 Jan 2018 07:12:05 PM UTC, comment #5: 

Anything that makes it clear to octave that it can't necessarily load binaries compiled on one version and executed on another would be fine.

Rik <rik5>
Group administrator
Fri 05 Jan 2018 06:53:39 PM UTC, comment #4: 

Maybe we could append a "+" to the name until the release?

John W. Eaton <jwe>
Group administrator
Fri 05 Jan 2018 06:42:31 PM UTC, comment #3: 

Yes, but I think it would be good to change the api version the moment a new release is created so that stable and development versions can co-exist nicely.  If there is a year or more between major releases that is a long time to have this issue be present.

Rik <rik5>
Group administrator
Fri 05 Jan 2018 06:24:00 PM UTC, comment #2: 

This is always changed during the normal release candidate process, so there's not really a bug here.

Mike Miller <mtmiller>
Group Member
Fri 05 Jan 2018 04:14:22 PM UTC, comment #1: 

Yes, this is typically done just before a release when the API version is bumped.  But you're right, for developers running both stable and development versions of Octave the api is currently the same which is bad.

Rik <rik5>
Group administrator
Fri 05 Jan 2018 01:43:35 PM UTC, original submission:  

Both Octave 4.2.1 and 4.3.0+ (development version) report "api-v51", see octave_config_info('api_version'). However, .oct files compiled by either mkoctfile crashes the other Octave. Thus, the oct files produced are not compatible. Can you change the api name so that directories with *.oct files do not clash?
Thanks.


Petr Mikulik <mikulik>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by jwe (Posted a comment)
  • -email is unavailable- added by mtmiller (Posted a comment)
  • -email is unavailable- added by rik5 (Posted a comment)
  • -email is unavailable- added by mikulik (Submitted the item)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

    Only group members can vote.

     

    Follow 5 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2018-01-08 rik5 StatusWorks For Me Fixed
        Open/ClosedOpen Closed
    2018-01-06 rik5 StatusConfirmed Works For Me
    2018-01-05 rik5 StatusNone Confirmed
        Assigned toNone jwe

    Back to the top

    Powered by Savane 3.13-caa5.
    Corresponding source code