Mysterious versioning reported by file command
I just noticed this, which doesn't actually seem to affect anything but does
create a mystery: [frankcox@mutt temp]$ cat test.c #include <stdio.h> int main(void) { printf("Hello world "); return 0; } [frankcox@mutt temp]$ gcc -o test test.c [frankcox@mutt temp]$ file test test: ELF 64-bit LSB executable, x86-64, version 1 (SYSV), dynamically linked (uses shared libs), for GNU/Linux 2.6.18, not stripped [frankcox@mutt temp]$ uname -a Linux mutt.melvilletheatre.net 2.6.32-220.17.1.el6.x86_64 #1 SMP Wed May 16 00:01:37 BST 2012 x86_64 x86_64 x86_64 GNU/Linux Why does the output from file say "Linux 2.6.18" when the actual kernel in use is 2.6.32? -- MELVILLE THEATRE ~ Real D 3D Digital Cinema ~ www.melvilletheatre.com www.creekfm.com - FIFTY THOUSAND WATTS of POW WOW POWER! _______________________________________________ CentOS mailing list CentOS@centos.org http://lists.centos.org/mailman/listinfo/centos |
Mysterious versioning reported by file command
On Sat, 26 May 2012 10:25:54 +0200
Reindl Harald wrote: > > Why does the output from file say "Linux 2.6.18" when the actual kernel in > > use is 2.6.32? > > it DOES NOT, learn to read outputs - it speaks about the elfutils > why should their output reflect the current kernel point version > it is not their job because "uname" exists [frankcox@mutt ~]$ rpm -q elfutils elfutils-0.152-1.el6.x86_64 That's not version 2.6.18 either. My question is, where does that 2.6.18 come from? It's not the current kernel version, it's not the gcc version, and it's not the current elfutils version either. -- MELVILLE THEATRE ~ Real D 3D Digital Cinema ~ www.melvilletheatre.com www.creekfm.com - FIFTY THOUSAND WATTS of POW WOW POWER! _______________________________________________ CentOS mailing list CentOS@centos.org http://lists.centos.org/mailman/listinfo/centos |
Mysterious versioning reported by file command
On Sun, May 27, 2012 at 12:51 AM, Frank Cox <theatre@melvilletheatre.com> wrote:
<snip> >> it DOES NOT, learn to read outputs - it speaks about the elfutils >> why should their output reflect the current kernel point version >> it is not their job because "uname" exists <snip> A mail is missing i guess ? > > [frankcox@mutt ~]$ rpm -q elfutils > elfutils-0.152-1.el6.x86_64 > > That's not version 2.6.18 either. > > My question is, where does *that 2.6.18 come from? > > It's not the current kernel version, it's not the gcc version, and it's not the > current elfutils version either. > > -- > MELVILLE THEATRE ~ Real D 3D Digital Cinema ~ www.melvilletheatre.com > www.creekfm.com - FIFTY THOUSAND WATTS of POW WOW POWER! > _______________________________________________ > CentOS mailing list > CentOS@centos.org > http://lists.centos.org/mailman/listinfo/centos -- -aft _______________________________________________ CentOS mailing list CentOS@centos.org http://lists.centos.org/mailman/listinfo/centos |
Mysterious versioning reported by file command
On Sat, 26 May 2012 21:32:52 +0200
Reindl Harald wrote: > from the binary, "file" does only print what a file contains Ok, then where does it come from, since it's not the current kernel version and it's not the elfutils version? gcc somehow finds that number and inserts it into the binary. Where did it find it and why is that number not the same as the other stuff, notably the kernel, since it appears to be a kernel version number? Just not the current kernel version number. -- MELVILLE THEATRE ~ Real D 3D Digital Cinema ~ www.melvilletheatre.com www.creekfm.com - FIFTY THOUSAND WATTS of POW WOW POWER! _______________________________________________ CentOS mailing list CentOS@centos.org http://lists.centos.org/mailman/listinfo/centos |
Mysterious versioning reported by file command
On Sat, 2012-05-26 at 17:21 -0600, Frank Cox wrote:
> Ok, then where does it come from, since it's not the current kernel version and > it's not the elfutils version? gcc somehow finds that number and inserts it > into the binary. Where did it find it and why is that number not the same as > the other stuff, notably the kernel, since it appears to be a kernel version > number? Just not the current kernel version number. An educated guess would be because the C and C++ ABI is backwards compatable with el5. Check it out...build the code on el5 and it should run under el6. For el5 you need the gcc44 update package. John _______________________________________________ CentOS mailing list CentOS@centos.org http://lists.centos.org/mailman/listinfo/centos |
| All times are GMT. The time now is 07:52 AM. |
VBulletin, Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.