bugSimulavr: an AVR simulator - Bugs: bug #38535, 1.0.0 does not build with...

 
 

bug #38535: 1.0.0 does not build with swig-2.0.x

Submitted by:  Thomas Zimmermann <heinervdm>
Submitted on:  Sun 17 Mar 2013 12:43:44 PM UTC  
 
Category: NoneSeverity: 3 - Normal
Item Group: NoneStatus: Fixed
Privacy: PublicAssigned to: Thomas K. <tomk>
Open/Closed: ClosedComponent Version: simulavr

Add a New Comment (Rich MarkupRich Markup):
   

You are not logged in

Please log in, so followups can be emailed to you.

 

(Jump to the original submission Jump to the original submission)

Sun 04 Aug 2013 03:12:20 PM UTC, comment #8:

Fixed in master branch

Thomas K. <tomk>
Project AdministratorIn charge of this item.
Tue 16 Jul 2013 10:31:21 PM UTC, comment #7:

The problem seems to be that '%include "types.h"' is put too low in the src/python/pysimulavr.i file. Moving it in front of

fixes the problem.

Pieter Agten <pietr>
Tue 16 Jul 2013 10:09:02 PM UTC, comment #6:

Compiling HEAD with swig 2.0.8 gives me:

Pieter Agten <pietr>
Mon 20 May 2013 02:58:17 PM UTC, comment #5:

I could run actual sources with swig 2.0.8 and also 1.x.x versions on older systems. I think the bugs are already fixed.

If there are still problems with building wrappers, please reopen this entry or add a new one.

Klaus Rudolph <zfrdh>
Project Administrator
Sun 24 Mar 2013 06:53:07 PM UTC, comment #4:

Checked the patch and I believe it's better just to add a single line: %include "types.h" before the template, so that SWIG knows the type. Works for me anyway. I can commit that to master branch.

Marek Pietrzak <mpie>
Project Member
Sun 24 Mar 2013 09:17:43 AM UTC, comment #3:

For me it looks like the Patch is already attached:
https://savannah.nongnu.org/bugs/download.php?file_id=27616

But i did not comment out the std_vector.i but used std::vector instead of namespace std {}

And i changed std::vector<dword> to std::vector<unsigned int> because swig was not able to find dword.

Thomas Zimmermann <heinervdm>
Sun 24 Mar 2013 09:15:58 AM UTC, comment #2:

Hi Thomas,

sorry, patch was available, but I haven't found it. :-)

cu, Thomas

Thomas K. <tomk>
Project AdministratorIn charge of this item.
Sun 24 Mar 2013 09:09:13 AM UTC, comment #1:

Hi Thomas,

could you attach the patch, as you wrote? :-) But I think, this is a problem with your SWIG installation. I assume, that you have commented out std_vector.i? But this wouldn't be a solution, because it would remove necessary functionality.

And btw. the last warning is removed in current development head (master branch)

cu, Thomas

Thomas K. <tomk>
Project AdministratorIn charge of this item.
Sun 17 Mar 2013 12:43:44 PM UTC, original submission:

When trying to build simulavr with swig-2.0.9 I'm getting the following error:

--
[ 318s] /usr/bin/swig -c++ -python -Ipython -o pysimulavr_wrap.cpp python/pysimulavr.i
[ 320s] /usr/share/swig/2.0.9/std/std_vector.i:87: Error: Can't copy typemap (directorout) std::vector< dword,std::allocator< dword > > = std::vector< dword,std::allocator< dword > > &DIRECTOROUT
[ 320s] /usr/share/swig/2.0.9/std/std_vector.i:87: Error: Can't copy typemap (in) std::vector< dword,std::allocator< dword > > INPUT = std::vector< dword,std::allocator< dword > > INOUT
[ 320s] /usr/share/swig/2.0.9/std/std_vector.i:87: Error: Can't copy typemap (in) std::vector< dword,std::allocator< dword > > &INPUT = std::vector< dword,std::allocator< dword > > &INOUT
[ 320s] /usr/share/swig/2.0.9/std/std_vector.i:87: Error: Can't copy typemap (typecheck) std::vector< dword,std::allocator< dword > > INPUT = std::vector< dword,std::allocator< dword > > INOUT
[ 320s] /usr/share/swig/2.0.9/std/std_vector.i:87: Error: Can't copy typemap (typecheck) std::vector< dword,std::allocator< dword > > &INPUT = std::vector< dword,std::allocator< dword > > &INOUT
[ 320s] /usr/share/swig/2.0.9/std/std_vector.i:87: Error: Can't copy typemap (argout) std::vector< dword,std::allocator< dword > > OUTPUT = std::vector< dword,std::allocator< dword > > INOUT
[ 320s] /usr/share/swig/2.0.9/std/std_vector.i:87: Error: Can't copy typemap (argout) std::vector< dword,std::allocator< dword > > &OUTPUT = std::vector< dword,std::allocator< dword > > &INOUT
[ 320s] /usr/share/swig/2.0.9/std/std_vector.i:87: Error: Can't copy typemap (typecheck) std::vector< dword,std::allocator< dword > > INPUT = std::vector< dword,std::allocator< dword > > INOUT
[ 320s] /usr/share/swig/2.0.9/std/std_vector.i:87: Error: Can't copy typemap (typecheck) std::vector< dword,std::allocator< dword > > &INPUT = std::vector< dword,std::allocator< dword > > &INOUT
[ 320s] /usr/share/swig/2.0.9/std/std_vector.i:87: Error: Can't copy typemap (freearg) std::vector< dword,std::allocator< dword > > INPUT = std::vector< dword,std::allocator< dword > > INOUT
[ 320s] /usr/share/swig/2.0.9/std/std_vector.i:87: Error: Can't copy typemap (freearg) std::vector< dword,std::allocator< dword > > &INPUT = std::vector< dword,std::allocator< dword > > &INOUT
[ 321s] python/pysimulationmember.h:38: Warning 514: Director base class PySimulationMember has no virtual destructor.
[ 322s] make[3]: *** [pysimulavr_wrap.cpp] Error 11
--

It's possible that this might be a problem of swig...

I worked around this issue with the attached patch, but I don't know if this is correct, as I haven't tried the python part of simulavr.

Thomas Zimmermann <heinervdm>

 

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

Attach File(s):
   
   
Comment:
   

Attached Files
file #27616:  swig-fix added by heinervdm (1kB - application/octet-stream)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by pietr (Posted a comment)
  • -unavailable- added by zfrdh (Posted a comment)
  • -unavailable- added by mpie (Posted a comment)
  • -unavailable- added by tomk (Posted a comment)
  • -unavailable- added by heinervdm (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follow 5 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Sun 04 Aug 2013 02:45:06 PM UTCtomkAssigned toNone=>tomk
    Mon 20 May 2013 02:58:17 PM UTCzfrdhStatusPostponed=>Fixed
      Open/ClosedOpen=>Closed
    Sun 24 Mar 2013 09:09:13 AM UTCtomkStatusNone=>Postponed
    Sun 17 Mar 2013 12:43:44 PM UTCheinervdmAttached File-=>Added swig-fix, #27616

    Back to the top


    Powered by Savane 3.1-cleanup