linuxldfreepascal

How to remove warning: link.res contains output sections; did you forget -T?


I use the Free Pascal Compiler (FPC) and I want to remove this warning. I have read FPC’s options but I cannot find out how to do that. Is this even possible? It appears when I run a command such as:

fpc foo.pas

Output sample:

Target OS: Linux for i386
Compiling foo.pas
Linking p2 /usr/bin/ld:
warning: link.res contains output sections; did you forget -T?
79 lines compiled, 0.1 sec


Solution

  • It's a bug in certain LD versions. Just ignore it for now, or see if your distro has an update for your LD. (package binutils)

    http://www.freepascal.org/faq.var#unix-ld219