Rashid Mirza(deleted)
|
Momentics IDE error while doing Debug
|
Rashid Mirza(deleted)
07/16/2010 7:57 AM
post59634
|
Momentics IDE error while doing Debug
I am trying to Debug a C project, and do a QConn onto a target system.
My IDE environment is Momentics 6.3 with SP3, and IDE 4.0. The target is runtime neutrino 6.3.
I get the error shown in the attachment, and the thread suspends with a SIGSEV.
I have included a view of the Disassembly window, if it helps.
The Run configuration executes properly on the target.
|
|
|
Andy Jin(deleted)
|
Re: Momentics IDE error while doing Debug
|
Andy Jin(deleted)
07/16/2010 10:16 AM
post59647
|
Re: Momentics IDE error while doing Debug
Did you program try to step into the kernel memory space, e.g. pointer
error to any library function? Your program got SIGSEGV because it tried
to make an invalid memory reference.
Also make sure you compile your program with debug option (-g) so you
have symbol information in the debug view. Try to put a break point in
"main()" to start debugging.
-----Original Message-----
From: Rashid Mirza <community-noreply@qnx.com>
Reply-to: post59634@community.qnx.com
To: general-ide <post59634@community.qnx.com>
Subject: Momentics IDE error while doing Debug
Date: Fri, 16 Jul 2010 07:57:32 -0400 (EDT)
I am trying to Debug a C project, and do a QConn onto a target system.
My IDE environment is Momentics 6.3 with SP3, and IDE 4.0. The target is runtime neutrino 6.3.
I get the error shown in the attachment, and the thread suspends with a SIGSEV.
I have included a view of the Disassembly window, if it helps.
The Run configuration executes properly on the target.
_______________________________________________
General
http://community.qnx.com/sf/go/post59634
|
|
|
Rashid Mirza(deleted)
|
Re: Momentics IDE error while doing Debug
|
Rashid Mirza(deleted)
07/16/2010 10:48 AM
post59652
|
Re: Momentics IDE error while doing Debug
where can i insert the -g option, which part of the build window or properties?
|
|
|
Andy Jin(deleted)
|
Re: Momentics IDE error while doing Debug
|
Andy Jin(deleted)
07/16/2010 11:00 AM
post59655
|
Re: Momentics IDE error while doing Debug
If it's a QNX C project, you can open the project properties -> Build
Variants, select the "debug" variant.
If it's a standard make project, you can add "-g" option to the CCFLAGS
in your make file.
You can reference the IDE user's guide for the 6.3.2 release for more
information on build and debug options:
http://www.qnx.com/download/download/16839/ide_user_guide.pdf
-----Original Message-----
From: Rashid Mirza <community-noreply@qnx.com>
Reply-to: post59652@community.qnx.com
To: general-ide <post59652@community.qnx.com>
Subject: Re: Momentics IDE error while doing Debug
Date: Fri, 16 Jul 2010 10:48:50 -0400 (EDT)
where can i insert the -g option, which part of the build window or properties?
_______________________________________________
General
http://community.qnx.com/sf/go/post59652
|
|
|
Rashid Mirza(deleted)
|
Re: Momentics IDE error while doing Debug
|
Rashid Mirza(deleted)
07/16/2010 11:49 AM
post59661
|
Re: Momentics IDE error while doing Debug
already the debug build variant has been selected.
do i still need to do a -g option?
Is there anything else i could try, in order to get this working?
|
|
|
Andy Jin(deleted)
|
Re: Momentics IDE error while doing Debug
|
Andy Jin(deleted)
07/16/2010 11:52 AM
post59662
|
Re: Momentics IDE error while doing Debug
Did you put a break point at the beginning of your "main()"? Did the
program stop at that break point?
-----Original Message-----
From: Rashid Mirza <community-noreply@qnx.com>
Reply-to: post59661@community.qnx.com
To: general-ide <post59661@community.qnx.com>
Subject: Re: Momentics IDE error while doing Debug
Date: Fri, 16 Jul 2010 11:49:25 -0400 (EDT)
already the debug build variant has been selected.
do i still need to do a -g option?
Is there anything else i could try, in order to get this working?
_______________________________________________
General
http://community.qnx.com/sf/go/post59661
|
|
|
Rashid Mirza(deleted)
|
Re: Momentics IDE error while doing Debug
|
Rashid Mirza(deleted)
07/16/2010 12:12 PM
post59666
|
Re: Momentics IDE error while doing Debug
yes it did, and it seems these errors take place, even before control reaches main().
|
|
|
Andy Jin(deleted)
|
Re: Momentics IDE error while doing Debug
|
Andy Jin(deleted)
07/16/2010 12:17 PM
post59669
|
Re: Momentics IDE error while doing Debug
This is strange. Can you attach your project to this post?
-----Original Message-----
From: Rashid Mirza <community-noreply@qnx.com>
Reply-to: post59666@community.qnx.com
To: general-ide <post59666@community.qnx.com>
Subject: Re: Momentics IDE error while doing Debug
Date: Fri, 16 Jul 2010 12:12:17 -0400 (EDT)
yes it did, and it seems these errors take place, even before control reaches main().
_______________________________________________
General
http://community.qnx.com/sf/go/post59666
|
|
|
Rashid Mirza(deleted)
|
Re: Momentics IDE error while doing Debug
|
Rashid Mirza(deleted)
07/16/2010 12:51 PM
post59672
|
Re: Momentics IDE error while doing Debug
I am doing a Qconn onto a QNX environment in a virtual machine. Could this be a cause for this error?
I need to try it on a dedicated QNX box and see if it makes a difference.
|
|
|
Rashid Mirza(deleted)
|
Re: Momentics IDE error while doing Debug
|
Rashid Mirza(deleted)
07/18/2010 8:13 AM
post59767
|
Re: Momentics IDE error while doing Debug
just want to make sure, should i be using the QN GDB Debugger?
any additions to Main or Shared Libraries under Debugger tab?
|
|
|
Elena Laskavaia
|
Re: Momentics IDE error while doing Debug
|
Elena Laskavaia
07/19/2010 11:47 AM
post59824
|
Re: Momentics IDE error while doing Debug
Yes if you debugging with shared library you need to add shared library
paths to Debugger tab. Also they have to be compiled with -g.
See also debugger FAQ:
http://community.qnx.com/sf/wiki/do/viewPage/projects.ide/wiki/DebuggerFAQ
Rashid Mirza wrote:
> just want to make sure, should i be using the QN GDB Debugger?
> any additions to Main or Shared Libraries under Debugger tab?
>
>
>
>
>
> _______________________________________________
>
> General
> http://community.qnx.com/sf/go/post59767
>
>
|
|
|
Rashid Mirza(deleted)
|
Re: Momentics IDE error while doing Debug
|
Rashid Mirza(deleted)
07/19/2010 2:53 PM
post59859
|
Re: Momentics IDE error while doing Debug
this is my doubt, where do i insert the -g, as part of which statement and where?
|
|
|
Rashid Mirza(deleted)
|
Re: Momentics IDE error while doing Debug
|
Rashid Mirza(deleted)
07/19/2010 2:51 PM
post59858
|
Re: Momentics IDE error while doing Debug
tried with a dedicated QNX box, and still have the same error...
|
|
|
Rashid Mirza(deleted)
|
Re: Momentics IDE error while doing Debug
|
Rashid Mirza(deleted)
07/19/2010 1:15 PM
post59841
|
Re: Momentics IDE error while doing Debug
wel,l i checked on a dedicated QNX box, and still get the same error...
|
|
|
Rashid Mirza(deleted)
|
Re: Momentics IDE error while doing Debug
|
Rashid Mirza(deleted)
07/19/2010 3:42 PM
post59863
|
Re: Momentics IDE error while doing Debug
the project uses static libraries, do i have to move then (.a) to qnx6/x86/lib and usr/qnx632/target?
|
|
|
Dave Bott(deleted)
|
Re: Momentics IDE error while doing Debug
|
Dave Bott(deleted)
07/19/2010 4:56 PM
post59868
|
Re: Momentics IDE error while doing Debug
Pp
----- Original Message -----
From: Rashid Mirza <community-noreply@qnx.com>
To: general-ide <post59863@community.qnx.com>
Sent: Mon Jul 19 15:42:07 2010
Subject: Re: Momentics IDE error while doing Debug
the project uses static libraries, do i have to move then (.a) to qnx6/x86/lib and usr/qnx632/target?
_______________________________________________
General
http://community.qnx.com/sf/go/post59863
|
|
|
Rashid Mirza(deleted)
|
Re: Momentics IDE error while doing Debug
|
Rashid Mirza(deleted)
07/20/2010 7:41 AM
post59917
|
Re: Momentics IDE error while doing Debug
ok, made some progress, and found out where the execution is coming to a halt.
I have attached a screen shot.
Also i replaced ntox86-gdb.exe ver 6.7 (did a backup of the old notx86-gdb file, cuase could not determine which version
it was), to get more info, and found in the console window a mismatch of the host and target libc.so file.
How can i solve this issue? Where do i have to do the change? Where can i donwload the neccessary file, and how do i
install it?
console window:
MsgNak received - resending
Remote target is little-endian
attach 1376294
Setting Dynamic-Linker Breakpoint based on C:/QNX630/target/qnx6/x86/usr/lib/ldqnx.so.2
warning: Host file C:/QNX630/target/qnx6/x86/usr/lib/ldqnx.so.2 does not match target file /usr/lib/ldqnx.so.2
0xb0334792 in ?? ()
mi_cmd_var_create: unable to create variable object
mi_cmd_var_create: unable to create variable object
i did a qconfig on my target and got the following information:
Installtion Name: QNX Neutrino RTOS x86 Runtime Kit 6.3.2
Version: 6.3.2
Base Directory: /
QNX_HOST: /
QNX_TARGET: /
should there be a path for QNX_HOST and QNX_TARGET?
if so, how do i set the path?
Appreciate the help..want to finish this ASAP...
|
|
|
Andy Jin(deleted)
|
RE: Momentics IDE error while doing Debug
|
Andy Jin(deleted)
07/20/2010 8:25 AM
post59926
|
RE: Momentics IDE error while doing Debug
I don't see the screen shot, did you forget to attach it?
You have mismatching libc because you are running 6.3.0 SP3 on host but 6.3.2 on target. You can contact your QNX sales
rep for an upgrade to 6.3.2. But I suspect this is the root cause of your problem.
Have you tried the latest gdb? you can download it from this link http://community.qnx.com/sf/frs/do/listReleases/
projects.toolchain/frs.gdb
Another possibility is error in your code. Going back to your first post that your program got SIGSEGV and now you got "
mi_cmd_var_create: unable to create variable object", you can check in the "Breakpoint" view to see where you put your
breakpoint. Remove all other breakpoints except the one at your "main()".
-----Original Message-----
From: Rashid Mirza [mailto:community-noreply@qnx.com]
Sent: Tue 20/07/2010 7:41 AM
To: general-ide
Subject: Re: Momentics IDE error while doing Debug
ok, made some progress, and found out where the execution is coming to a halt.
I have attached a screen shot.
Also i replaced ntox86-gdb.exe ver 6.7 (did a backup of the old notx86-gdb file, cuase could not determine which version
it was), to get more info, and found in the console window a mismatch of the host and target libc.so file.
How can i solve this issue? Where do i have to do the change? Where can i donwload the neccessary file, and how do i
install it?
console window:
MsgNak received - resending
Remote target is little-endian
attach 1376294
Setting Dynamic-Linker Breakpoint based on C:/QNX630/target/qnx6/x86/usr/lib/ldqnx.so.2
warning: Host file C:/QNX630/target/qnx6/x86/usr/lib/ldqnx.so.2 does not match target file /usr/lib/ldqnx.so.2
0xb0334792 in ?? ()
mi_cmd_var_create: unable to create variable object
mi_cmd_var_create: unable to create variable object
i did a qconfig on my target and got the following information:
Installtion Name: QNX Neutrino RTOS x86 Runtime Kit 6.3.2
Version: 6.3.2
Base Directory: /
QNX_HOST: /
QNX_TARGET: /
should there be a path for QNX_HOST and QNX_TARGET?
if so, how do i set the path?
Appreciate the help..want to finish this ASAP...
_______________________________________________
General
http://community.qnx.com/sf/go/post59917
|
|
|
Rashid Mirza(deleted)
|
Re: RE: Momentics IDE error while doing Debug
|
Rashid Mirza(deleted)
07/20/2010 8:36 AM
post59930
|
Re: RE: Momentics IDE error while doing Debug
fine i will look into preparing my host with qnx 6.3.2 sp3.
Is there a way to obtain what my existing installation is on the host, i.e the version on QNX?
i have attached screen dump now.
|
|
|
Andy Jin(deleted)
|
RE: RE: Momentics IDE error while doing Debug
|
Andy Jin(deleted)
07/20/2010 8:42 AM
post59933
|
RE: RE: Momentics IDE error while doing Debug
You need 6.3.2, not "6.3.2 sp3". There is no "sp3" for 6.3.2.
I don't understand your question of "existing installation is on the host". You are going to install 6.3.2 to your host
and run IDE from 6.3.2. By default it installs to "C:\QNX632" directory so it will not remove your existing installation
of 6.3.0 SP3.
-----Original Message-----
From: Rashid Mirza [mailto:community-noreply@qnx.com]
Sent: Tue 20/07/2010 8:36 AM
To: general-ide
Subject: Re: RE: Momentics IDE error while doing Debug
fine i will look into preparing my host with qnx 6.3.2 sp3.
Is there a way to obtain what my existing installation is on the host, i.e the version on QNX?
i have attached screen dump now.
|
|
|
Rashid Mirza(deleted)
|
Re: RE: RE: Momentics IDE error while doing Debug
|
Rashid Mirza(deleted)
07/20/2010 8:49 AM
post59939
|
Re: RE: RE: Momentics IDE error while doing Debug
ok, a installation to another directory is good, let me try and i will get back
|
|
|
Andy Jin(deleted)
|
Re: RE: Momentics IDE error while doing Debug
|
Andy Jin(deleted)
07/20/2010 8:49 AM
post59938
|
Re: RE: Momentics IDE error while doing Debug
Looking at your screen shot, it seems like your program is not compiled with debug info. Did you compile it with "-g"
option?
|
|
|
Rashid Mirza(deleted)
|
Re: RE: Momentics IDE error while doing Debug
|
Rashid Mirza(deleted)
07/20/2010 8:59 AM
post59941
|
Re: RE: Momentics IDE error while doing Debug
since i am using the IDE for compilation, i dont know where i have to insert the -g option. which part of the IDE?
|
|
|
Rashid Mirza(deleted)
|
Re: RE: Momentics IDE error while doing Debug
|
Rashid Mirza(deleted)
07/20/2010 9:12 AM
post59945
|
Re: RE: Momentics IDE error while doing Debug
i would like to add, i had similar error (as my first attachment) when i checked Debug with a dedicated QNX box, but
that was running 6.3.0 SP3, therefore it was matching my host which was also 6.3.0 with SP3.
|
|
|
Elena Laskavaia
|
Re: Momentics IDE error while doing Debug
|
Elena Laskavaia
07/20/2010 9:21 AM
post59950
|
Re: Momentics IDE error while doing Debug
If you using debug variant it is inserted automatically. You can check
that but looking at the build output on console - you will see full
command line, make
sure it includes -g. Answer on your question about where to insert -g
depends on what type of project you are using. Is it qnx project?
Rashid Mirza wrote:
> since i am using the IDE for compilation, i dont know where i have to insert the -g option. which part of the IDE?
>
>
>
>
> _______________________________________________
>
> General
> http://community.qnx.com/sf/go/post59941
>
>
|
|
|
|