Public bug reported:

Problem:

On Ubuntu 11.10 64bit using tcc version 0.9.25 (Ubuntu package version
0.9.25-10) I cannot get tcc to produce an executable elf binary.

Reproduction:

echo 'main(){puts("hello");}' | tcc -
./a.out

What I expect to happen:

Same as when I run
echo 'main(){puts("hello");}' | tcc -run -

What actually happens:

bash: ./a.out: No such file or directory

The binary obviously does exist and readelf -h a.out shows the following
elf header:

ELF Header:
  Magic:   7f 45 4c 46 02 01 01 00 00 00 00 00 00 00 00 00 
  Class:                             ELF64
  Data:                              2's complement, little endian
  Version:                           1 (current)
  OS/ABI:                            UNIX - System V
  ABI Version:                       0
  Type:                              EXEC (Executable file)
  Machine:                           Advanced Micro Devices X86-64
  Version:                           0x1
  Entry point address:               0x8048280
  Start of program headers:          64 (bytes into file)
  Start of section headers:          1600 (bytes into file)
  Flags:                             0x0
  Size of this header:               64 (bytes)
  Size of program headers:           56 (bytes)
  Number of program headers:         4
  Size of section headers:           64 (bytes)
  Number of section headers:         28
  Section header string table index: 27

objdump -x exists with:
objdump: a.out: Bad value

Somethings probably wrong with the header but I have not really looked
into it in any depth.

** Affects: tcc (Ubuntu)
     Importance: Undecided
         Status: New

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/910544

Title:
  tcc produces invalid elf header

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/tcc/+bug/910544/+subscriptions

-- 
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to