Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

GDB error: Selected architecture i386 is not compatible with reported target architecture i386:x86-64

Does anyone know what this error means?

enter image description here

I'm working with Netbeans 8.0, gdb 7.8.1 on Linux Machine. Everything was good until two days ago, then I suddenly started to get this error when i'm starting t debug and I have no clue what it means.
So far, I'm trying to clean and reset everything I could think about: reinstall netbeans, clean all local files, rebase my code again, unset all breakpoints and so on and so on.
Could anyone please help me to understand what this error means? I've never set those breakpoints, where does Netbeans take themfrom?

Thanks in advance,
Rachel

EDIT

So now I have a bit more details: When I'm trying to debug my app directly with GDB, without netbeans I'm getting the following error:

Starting program: ....
warning: Selected architecture i386 is not compatible with reported target architecture i386:x86-64
warning: Architecture rejected target-supplied description
Warning:
Cannot insert breakpoint -1. Temporarily disabling shared library breakpoints: breakpoint #-1 Cannot insert breakpoint 1. Cannot access memory at address 0x8081527

how can I figure out what code\flag in compilation makes my app to be i386? how can I force it to be x86_64?

Thanks again.

like image 218
RRR Avatar asked Feb 09 '17 11:02

RRR


2 Answers

OK, the gdb installation on my machine was screwed. There's no chance anyone could imagine it. I moved to another machine and everything is good now.

like image 52
RRR Avatar answered Oct 06 '22 00:10

RRR


This error could appear when you try to use WSL gdb on non-WSL app.

like image 42
ephemerr Avatar answered Oct 06 '22 00:10

ephemerr