Questions tagged [binutils]

The GNU binary utilities. A collection of tools for operating on object files. Most notably they include the GNU assembler and linker. They are typically used in conjunction with the GNU compiler collection (GCC).

418 questions
5
votes
2 answers

Error building ELLCC

Running the build script from ELLCC results in this error gcc -DHAVE_CONFIG_H -I. -I../../../src/binutils/binutils -I. -I../../../src/binutils/binutils -I../bfd -I../../../src/binutils/binutils/../bfd -I../../../src/binutils/binutils/../include…
Hanxue
  • 12,243
  • 18
  • 88
  • 130
5
votes
1 answer

Binutils ld linker how to configure emulation mode (no supported emulations after build with mingw)

After successfully building binutils/ld with mingw and trying to run it I am getting this message- $ ld-new h:/binutils-2.23.1/ld/.libs/ld-new.exe: unrecognised emulation mode: Supported emulations: I've looked through the internals documentation…
user2380227
  • 267
  • 4
  • 14
5
votes
1 answer

Building gold linker with MinGW on Windows, FLEX/bison 'YYSTYPE' was not declared in this scope

I'm trying to build the gold linker included with GNU binutils using mingw. The steps I have taken- Install mingw with all packages using the installer. Install the windows version of FLEX to the default location using the windows installer. Run…
user2380227
  • 267
  • 4
  • 14
5
votes
4 answers

Tutorial on building whole toolchain on CentOS

I am working on CentOS 6 machines, which has very old GCC/GlibC version. I want to build the whole glibc, binutils, gcc toolchain with latest or at least very recent versions in order to use c++11 support in latest gcc, and ld.gold in recent…
Kan Li
  • 8,557
  • 8
  • 53
  • 93
5
votes
1 answer

cross compiling, why "checking whether we are cross compiling... no"?

I'm trying to compile cross-platform tools-chain by myself. When I compiled binutils-2.22, it success but why appear "checking whether we are cross compiling... no"? I suppose it should be "yes", right? My host is i686 running ubuntu, and my target…
justnight
  • 143
  • 1
  • 2
  • 7
4
votes
2 answers

MIPS, ELF and partial linking

I have a big software project with a complicated build process, which works like this: Compile individual source files. Partially link object files for each module together into another .o using ld -r. Hide private symbols in each module using…
David Given
  • 13,277
  • 9
  • 76
  • 123
4
votes
2 answers

Is '.set noat' unsupported for MIPS assembly?

Currently, I'm learning GNU as, and find a lot useful information in "info as". I found ".set noat" is used in MIPS specified code, but when searching for this directive in "info as", I found its explanation in node "alpha directive", but not in…
Wangrui
  • 167
  • 2
  • 11
4
votes
1 answer

Error while building binutils 2.21.1a on Solaris

I'm trying to build binutils 2.21.1a from http://ftp.gnu.org/gnu/binutils on Solaris sun4u sparc SunOS 5.10. I am using gcc version 4.0.2. When I built this is the error: cc1: warnings being treated as errors compress.c: In function…
James
  • 1,754
  • 14
  • 22
4
votes
3 answers

How can I remove linked library from executable file

All. Someone created an executable file. # ldd test_bin libstdc++.so.6 => /usr/lib/libstdc++.so.6 (0x4082d000) libA.so.0 => /usr/lib/libA.so.0 (0x408fe000) libB.so.0 => /usr/lib/libB.so.0 (0x4093e000) libgobject-2.0.so.0 =>…
spbear
  • 41
  • 1
  • 2
4
votes
0 answers

What is the difference between read-only and read only data section?

Recently, I have dived into GCC Binutils nm documentation. I read the description of the symbols' classification and don't understand the differences between n and R (or r) symbols. As the manual says: for n The symbol is in the read-only data…
llwafelll
  • 53
  • 1
  • 4
4
votes
1 answer

Linux ELF files: Which byte will differ for static and dynamic ELF programs?

I'm working with linux elf files. I want to detect, if the given elf program is statically linked (full static link, ldd says "not a dynamic executable") or dynamically linked. The ELF is for embedded Linux, so I can't just run it or use ldd…
osgx
  • 90,338
  • 53
  • 357
  • 513
4
votes
2 answers

Adding to the *end* of the gnu ld library search paths

I know how to add to GNU ld's library search path using the -Ldir option and use it extensively. But as far as I can tell from reading the manuals of gcc and ld, there is no way to add to the end of the list of library search paths. The -L option…
Bryce Schober
  • 130
  • 10
4
votes
1 answer

Hide symbols from a 3rd party .a file that is linked into a .so file

I am building a shared (.so) library that is composed of several .a files and a thin API layer that invokes them. I only want my API and external dependencies to be visible, so I build my code using the "hidden" visibility offered by GCC…
BareMetalCoder
  • 569
  • 5
  • 17
4
votes
1 answer

Failure building cross-compiling 64-bit GCC

I'm trying to get a working gcc cross-compiler created that lives on my local machine [Darwin new-host-2.home 10.7.4 Darwin Kernel Version 10.7.4: Mon Apr 18 21:24:17 PDT 2011; root:xnu-1504.14.12~3/RELEASE_X86_64 x86_64] and targets a FreeBSD 8.2…
Nektarios
  • 10,173
  • 8
  • 63
  • 93
4
votes
0 answers

Is DWARF5 supported or experimental in GCC 8?

I asked this question on the gcc-help mailing list, but received no reply, so I'm trying here instead: The GCC 7 release notes state that "Version 5 of the DWARF debugging information standard is supported":…
acm
  • 12,183
  • 5
  • 39
  • 68