FedoraForum.org - Fedora Support Forums and Community
Results 1 to 6 of 6
  1. #1
    Join Date
    Feb 2011
    Location
    Moscow, Russia
    Posts
    140
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Insight does not work as required on x86-64 arch.

    I tried to compile and debug .c program with gcc/insight under Fedora 14 x86-64 bit.
    program:
    #include <stdio.h>

    main() {
    int a=100;
    int b=200;
    char *c = "Hello";

    printf("Hello\n");
    }

    I compile it with
    gcc -g x.c

    then I run debuger:

    insight a.out

    When I try to see local variables, i see that:
    a = (int) Could not read variable object value after assigment
    ...

    in terminal screen I have:

    BFD: /lib64/libc.so.6: invalid relocation type 37
    BFD: BFD (GNU Binutils) 2.18.50.20080226 assertion fail elf64-x86-64.c:278
    BFD: /lib64/libc.so.6: invalid relocation type 37
    BFD: BFD (GNU Binutils) 2.18.50.20080226 assertion fail elf64-x86-64.c:278

    I tried the same scenario under Fedora 14 686 - everything went OK.

    What gives?

  2. #2
    Join Date
    Aug 2009
    Location
    College Station, TX
    Posts
    502
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Insight does not work as required on x86-64 arch.

    Good question.

    Just for grins I tried the one from 13 and 15Alpha on 14 and had the same problem.

    Interestingly, when I recompile the 14 .src.rpm, it produces a binary that acts differently the one Fedora distributes. That is odd.

    The only luck I had was using the -m32 bit on the compile to force 32-bit compiles. It works then, but isn't much help if you are trying to debug 64-bit apps (and I assume you are debugging more than hello.c ).

    I didn't see a bug in the bugzilla. Maybe there should be one. gdb doesn't seem to have a problem with displaying the variable values so I wonder why insight has a problem.

    SS

  3. #3
    Join Date
    Feb 2011
    Location
    Moscow, Russia
    Posts
    140
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Insight does not work as required on x86-64 arch.

    Yesterday I tried to do this exercise on Ubuntu (I have .iso file for 10.4) 64 bit, but I had no time to install it on KVM. Maybe tomorrow

  4. #4
    Join Date
    Aug 2009
    Location
    College Station, TX
    Posts
    502
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Insight does not work as required on x86-64 arch.

    Don't waste your time... apparently Ubuntu/Debian dropped it. The thread on it (below) suggests using ddd or nemiver. Both are in the Fedora repos. The latter looks like the easiest/cleanest way to go a nice little variable window that works.

    The problem seems to be that the upstream is no longer maintained and the program is built with its own internal copies of certain things, gdb being the most important part here. It has its own copy of gdb 6.8 (with current fc14 being 7.2). If you do a 'rpm -q --requires' on ddd and nemiver you'll see they use the system gdb which is going to be much more up to date.

    I'm actually surprised this package is still in Fedora since the way it is currently packaged violates one of the packaging guidelines. Probably a non-trivial task to unbundle the libraries and thus the reason Debian dropped it.

    Anyway, for the Ubuntu thread with details on package dependencies, why it was dropped, and ways to work around the problem, is here:

    http://ubuntuforums.org/showthread.php?t=1512700

    Short answer, use nemiver (or ddd).

    SS

  5. #5
    Join Date
    Feb 2011
    Location
    Moscow, Russia
    Posts
    140
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Insight does not work as required on x86-64 arch.

    OK. I got the idea.

    Actually years ago I did little programming and used insight. So, that is a reason. Thanks for advice, I will switch to another debuger

    Thanks again!

    P.S. Tried nemiver - looks good.
    Last edited by alexeik; 8th April 2011 at 05:54 PM.

  6. #6
    Join Date
    Aug 2009
    Location
    College Station, TX
    Posts
    502
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Insight does not work as required on x86-64 arch.


Similar Threads

  1. [Fedora 12]insight crash
    By smalllixin in forum Using Fedora
    Replies: 2
    Last Post: 10th December 2009, 06:15 AM
  2. Replies: 0
    Last Post: 29th May 2008, 02:51 PM
  3. LVM Insight Please . . .
    By Tuche in forum Using Fedora
    Replies: 8
    Last Post: 11th December 2007, 04:12 AM
  4. Insight-gui on FC5
    By shun_zhao in forum Programming & Packaging
    Replies: 4
    Last Post: 20th June 2006, 12:35 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •