当在使用c++ compiler 时,出现error:
file format not recognized; treating as linker script
这是说明 该文件的格式不能被识别, 被当作链接脚本对待。
为什么被当作链接脚本?
If you specify a linker input file which the linker can not recognize as an object file or an archive file, it will try to read the file as a linker script. If the file can not be parsed as a linker script, the linker will report an error.
An implicit linker script will not replace the default linker script.
Typically an implicit linker script would contain only symbol assignments, or the INPUT
, GROUP
, or VERSION
commands.
Any input files read because of an implicit linker script will be read at the position in the command line where the implicit linker script was read. This can affect archive searching.