
Ubuntu日本語フォーラム

ログインしていません。
Ubuntu 12.04
Linux 3.2.0-25
gcc 4.6 を使っています
この環境で、gccでコンパイルした実行ファイルを、fileコマンドで見ると
hello: ELF 32-bit LSB executable, Intel 80386, version 1 (SYSV), dynamically linked (uses shared libs), for GNU/Linux 2.6.24, BuildID[sha1]=0xb066c97f40adeb5ac786e5eb75c6b5d32eddc400, not stripped
と表示されます。
ここに表示される、for GNU/Linux 2.6.24 はどこから来ているんでしょうか?
オフライン
ELFのNOTESかと思います。
$ readelf -n ./hoge
Notes at offset 0x00000254 with length 0x00000020:
Owner Data size Description
GNU 0x00000010 NT_GNU_ABI_TAG (ABI version tag)
OS: Linux, ABI: 2.6.24
Notes at offset 0x00000274 with length 0x00000024:
Owner Data size Description
GNU 0x00000014 NT_GNU_BUILD_ID (unique build ID bitstring)
Build ID: c74e4457d8457012db755de685d9447098998bae
オフライン