ld Questions
1
I am trying to compile a simple hello program using gcc, but getting the below error. i am using ubuntu.
gcc -g -o hello hello.c
collect2: fatal error: ld terminated with signal 11 [Segmentatio...
Odeen asked 16/7, 2019 at 21:9
3
I have a bunch of object files that have been compiled without the -fPIC option. So the calls to the functions do not use @PLT. (source code is C and is compiled with clang).
I want to link these ...
7
I'm trying to build precimonious on Ubuntu 16.04.3 x64. I allocated 1GB memory for it. My file structure looks like
~
|--- llvm/
|--- precimonious/
where the llvm is on version 3.0 as mentioned ...
3
I am facing an error whenever I try to compile fortran code:
% gfortran Testing_Fortran.f90 -o Testing_Fortran
ld: unsupported tapi file type '!tapi-tbd' in YAML file '/Library/Developer/CommandLi...
Cartulary asked 4/11, 2022 at 13:47
4
Solved
I have updated my arm-none-eabi GCC and the associated tools and rebuilt an embedded project I develop.
$ arm-none-eabi-ld --version
GNU ld (GNU Binutils) 2.39
Suddenly, I'm getting the warning
/u...
Pfister asked 20/8, 2022 at 20:28
6
I'm trying to create a simple kernel using Ubuntu. In the terminal I typed
ld -Ttext 0x1000 -o kernel.bin loader.o main.o Video.o
But I got the following error message in return:
ld: i386 architec...
3
I compiled the same project on ubuntu20.04 in wsl and my main used OS archLinux respectively. On wsl, everything went normal, while on archlinux the error message as follows would show:
/usr/bin/ld...
Inveracity asked 21/8, 2022 at 15:8
8
Solved
to clarify, my question refers to wrapping/intercepting calls from one function/symbol to another function/symbol when the caller and the callee are defined in the same compilation unit with the GC...
Greer asked 19/12, 2012 at 21:45
2
Solved
Is there a way to get compilers to prefer libraries from LIBRARY_PATH instead of system paths. I am particularly looking for Clang. I partially solved the problem for GCC while writing this questio...
3
Solved
I want to know when I should use ld linker instead off gcc.
I just wrote a simply hello world in c++, of course I include iostream library. If I want make a binary file with gcc, I just use: g++ he...
3
I am building some legacy code from projects that uses static libraries. Now, I get lots of errors like this:
ld: warning: option -m is obsolete and being ignored
ld: duplicate symbol <functio...
5
Solved
For convenience I added the relevant manpages below.
My (mis)understanding first: If I need to separate options with ,, that means that the second -Wl is not another option because it comes before ...
1
I am trying to install a project which was developed on Ubuntu, but now I am trying to make it run on Max OSX - version: 10.10.5 (Yosemite).
My current ld version that comes by default with OSX:
...
1
I have a linker script like this:
OUTPUT_FORMAT(binary)
SECTIONS
{
. = 0xFFFF800000000000 ;
.startup_text : { processor.o(.text) }
.text : { *(EXCLUDE_FILE (processor.o) .text) }
.data : { *(....
Comenius asked 25/1, 2016 at 16:34
3
Solved
For an embedded device, I have file containing an array with function pointers storing interrupt handlers, define like that (I can't modify it):
typedef void (*const ISRFunction)(void);
__attribu...
Gabriel asked 1/8, 2016 at 9:55
2
I'm currently trying to profile a preloaded shared library by using the LD_PROFILE environment variable.
I compile the library with "-g" flag and export LD_PROFILE_OUTPUT as well as LD_PROFILE bef...
9
Solved
I'm looking for a way to load generated object code directly from memory.
I understand that if I write it to a file, I can call dlopen to dynamically load its symbols and link them. However, this ...
Hog asked 19/2, 2011 at 21:30
1
Why GCC does not do function dead code elimination with LTO when compiling the object file with -O0?
Example:
notmain.c
int __attribute__ ((noinline)) notmain(int i) {
return i + 1;
}
int notmain2(int i) {
return i + 2;
}
main.c
int notmain(int);
int main(int argc, char **argv) {
return notm...
13
Solved
5
Solved
What does the ALIGN keyword do in linker scripts? I read many tutorials about linker scripts but I cant understand what really ALIGN do. Can any one explain it simply. Thanks!
Zapateado asked 10/12, 2011 at 16:43
2
Solved
When compiling a c++ project in a conda environment on MacOS Big Sur, the error
ld: unsupported tapi file type '!tapi-tbd' in YAML file may occur. How to proceed?
Daciadacie asked 18/9, 2021 at 16:8
21
I have a virtual Debian system which I use to develop. Today I wanted to try llvm/clang. After installing clang I can't compile my old c-projects (with gcc).
This is the error:
/usr/bin/ld: cannot ...
1
I don't find any useful information on the differences between "-fno-pie" and "-no-pie". Are they gcc flags or ld flags? Are they both necessary or not?
I found a piece of makef...
Stirk asked 3/11, 2022 at 8:42
2
Solved
What is the meaning of -l (lowercase "L") flags passed to gcc/g++? And where can I find documentation or tutorials on it?
I've tried searching man gcc and man ld for -l, but that has tho...
4
Solved
1 Next >
© 2022 - 2025 — McMap. All rights reserved.