Mailing list archive (omnetpp-l at omnetpp.org)


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [omnetpp] build JSimpleModule



Hi Nuno,

Thanks for the patch. As for why it crashes with -O2, I don't know. Do you
have -fno-strict-aliasing in the compiler flags? It may help.

Regards,
Andras

> -----Original Message-----
> From: omnetpp-l-bounces at xxx [mailto:omnetpp-l-bounces at xxx]
> On Behalf Of Nuno Alexandre Carvalho
> Sent: Tuesday, April 08, 2008 3:51 PM
> To: OMNeT++ Discussion List
> Subject: Re: [omnetpp] build JSimpleModule
> 
> Hi,
> 
> Today I returned to this problem, i solved it replacing the "? : ;"
> conditional for a "if then else". The patch follows as attachment.
> 
> Other problem that I found was, when I build the JSimpleModule with the
> default Makefile (created with opp_makemake), which contains the -O2
> flag. When I run the simulation it simply stops with a segmentation
> fault when Java code tries to access OMNeT++ core.
> If I build it whit a lower -O flag or without it, the simulation runs
> normally.
> Anyone can explain this?
> 
> Thanks
> 
> Best regards,
> Nuno
> 
> On 03/27/2008 03:26 PM, Nuno Alexandre Carvalho wrote:
> > Hi,
> >
> > When I try to build the JSimpleModule v3.3-1, the JUtil.cc file
> > generates the following error:
> >> JUtil.cc: In member function 'void
> JObjectAccess::setBooleanJavaField(const char*, jboolean)':
> >> JUtil.cc:153: error: 'JUtil::jenv-
> >JNIEnv_::SetBooleanField(((JObjectAccess*)this)->JObjectAccess::javaPeer,
> fieldID, ((int)value))' has type 'void' and is not a throw-expression
> >> ...
> > You can see with more detail in the attachment.
> >
> > This files are from the JSimpleModule tarball, available at
> > http://www.omnetpp.org/filemgmt/singlefile.php?lid=126
> > I'm using Ubuntu linux, OMNeT++ 3.3, Java SUN 1.6.0_03-b05 and g++
> 4.1.3.
> >
> > Thanks
> >
> > Best regards,
> > Nuno
> >

_______________________________________________
OMNeT++ Mailing List
options: http://lists.omnetpp.org/mailman/listinfo/omnetpp-l
archive: http://www.omnetpp.org/listarchive/index.php

Home | Main Index | Thread Index