The tag has no wiki summary.

learn more… | top users | synonyms

1
vote
2answers
198 views

ld.so.preload doesn't differ x86_32 and x86_64

— It's known you can run x86_32 programms with x86_64 kernel if it was compiled with support for that. But dynamic linker doesn't provide any way to define a separate set of preload libraries for ...
17
votes
2answers
2k views

What is ELF Magic?

I've seen discussion before about ELF magic (most recently the comments in this Security stack exchange question. I've seen it mentioned before, and I've seen it in my own boot logs.. But I'm not sure ...
2
votes
1answer
265 views

How does bash execute an ELF file?

When I'm on my Linux Box I use bash as a shell. Now I wondered how bash handles the execution of an ELF file, that is when I type ./program and program is an ELF file. I grepped the bash-4.3.tar.gz, ...
2
votes
1answer
102 views

Why does chroot get ENOENT on an existing file?

;TL-DR - Answer: because the dynamic linker ld-linux-x86-64.so.2 was missing. I have mounted a squashfs (shouldn't matter) filesystem -ro,loop at /mnt/foo. It contains among other things the ...
1
vote
2answers
76 views

How many sections can I create in object file?

I'm following the course of Baking Pi – Operating Systems Development. In it they created another section .init. So can we create as many sections as we want (not just .data, .bss, .text) and can we ...
5
votes
1answer
163 views

Why does readelf show “System V” as my OS instead of Linux?

I compiled a small C program (2 lines of codes) with gcc to try to understand ELF file format. Doing a readelf -h on the object file, I have in the header : OS/ABI: UNIX - ...
1
vote
1answer
50 views

How to compile to a specific executable format?

I'm a bit confused. I just read this: http://www.es.freebsd.org/doc/handbook/binary-formats.html, which basically says that freeBSD uses the elf binary format. But when I compile my code I using cc, I ...
1
vote
1answer
174 views

How to install Intel binary file on Arm?

I am trying to install a binary file and I get the output as "Cannot install binary" When I did file .bin Output is: c64plus-imglib_2_02_00_00_Linux-x86_Setup.bin: ELF 32-bit LSB executable, Intel ...
8
votes
2answers
2k views

Determine if a specific process is 32- or 64-Bit

Given a 2.6.x or newer Linux kernel and existing userland that is capable of running both ELF32 and ELF64 binaries (i.e. well past How do I know that my CPU supports 64bit operating systems under ...
0
votes
1answer
138 views

Is the ELF format bound to a CPU architecture or not? [closed]

If you go through wikipedia it states that "ELF is flexible and extensible by design, and it is not bound to any particular processor or architecture." Then why are there so many packages like ...
2
votes
1answer
133 views

Using prelink on manually loaded libraries? (like Java native libraries)

As far as I can tell, prelink can only works with dynamic libraries which an executable declares it needs at compile time (the libraries that can be found with ldd). It doesn't seem to include ...
3
votes
1answer
147 views

What does `*` mean using hexdump -C?

I've been doing an exersice in attempt to understanding some of what's going on under the hood of a program. I wrote a small C program, and compiled it on i386 Linux (Ubuntu 12.04) using gcc. I then ...
4
votes
1answer
112 views

Portions of the file Header

I was working through my C programs, I am new to Linux/UNIX development and was having a look around. I created a simple C program of Hello world and was inspecting the compilation process. I tried ...
4
votes
1answer
1k views

Which parts of an ELF executable get loaded into memory, and where?

What I already know: An ELF executable has a number of sections, obviously the .text and .data sections get loaded into memory as these are the main parts of the program. But for a program to work, ...
1
vote
1answer
209 views

Can I read what CCFLAGS were used for building a binary?

Is there any way to read from compiled code what CCFLAGS (particularly the optimizations) were set at compile time?
5
votes
1answer
718 views

Unix/Linux Loader Process

Can anyone tell me which process of the operating system loads the ELF(Executable and Linking format) file into RAM ?
25
votes
1answer
1k views

Oldest binary working on Linux?

In a discussion on backwards-compatibility in Linux kernel and GUI ABIs, Alan Cox notes that "my 3.6rc kernel will still run a Rogue binary built in 1992. X is back compatible to apps far older than ...
3
votes
1answer
485 views

Rationale for making user space text segment start at 0x8048000

I read somewhere that (at least since Linux v. 2.6) all user-space code is placed at load address 0x8048000 in the virtual memory address space. My own observations confirm this. I have done a cat ...
2
votes
3answers
5k views

How to find executable filetypes?

I want to find file types that are executable from the kernel's point of view. As far as I know all the executable files on Linux are ELF files. Thus I tried the following: find * | file | grep ELF ...
3
votes
1answer
1k views

When executable files aren't [duplicate]

Possible Duplicate: Can't execute some binaries in chroot environment (zsh: Not found) Today I ran into something that has me stumped. A co-worker is working with a specific ...
3
votes
2answers
144 views

Different formats of object files in Linux

I was wondering what are some formats of object files in Linux? There are two types of object files that I know: executable, which has ELF format object files that are generated by gcc after ...
2
votes
1answer
406 views

How does prelink work

I was wondering how prelinking works. If I prelink my whole system and than delete glibc, will the system 'get up' after restart?
7
votes
2answers
424 views

Detect if an ELF binary was built with gprof instrumentation?

Is it possible to check if given program was compiled with GNU gprof instrumentation, i.e. with '-pg' flag passed to both compiler and linker, without running it to check if it would generate a ...
12
votes
1answer
842 views

Why does the file command say that ELF binaries are for Linux 2.6.9?

Whenever I run file on an ELF binary I get this output: [jonescb@localhost ~]$ file a.out a.out: ELF 32-bit LSB executable, Intel 80386, version 1 (SYSV), for GNU/Linux 2.6.9, dynamically linked ...
3
votes
2answers
3k views

Why does LD keep outputting “no version information available”

On every loading of a lib, I get the error: no version information available This lib has been compiled on another PC (ubuntu 10.04) than the one running it (mandriva 2010.2). $ ldd ...
6
votes
1answer
2k views

Linux, GNU GCC, ld, version scripts and the ELF binary format — How does it work?

I'm trying to learn more about library versioning in Linux and how to put it all to work. Here's the context: -- I have two versions of a dynamic library which expose the same set of interfaces, say ...
12
votes
5answers
8k views

Can we get compiler information from an elf binary?

Is there some chance to know how a binary was built, under Linux? (and or other Unix) Compiler, version, time, flags etc... I looked at readelf and couldn't find much, but there might be other ways ...