This is the mail archive of the binutils@sourceware.org mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: relation between kernel , gcc and binutils versions


Hi Ganesh,

is there any relation between binutils version and kernel version?

For the assignment of version numbers no. (ie kernel version numbers and binutils version numbers are maintained independently). It may be the case however that a given version of the kernel may require a minimum binutils version number in order to work. It is the intent of the binutils to always remain backwards compatible however, so you always have the option of using a newer version of the binutils to the one recommended in the kernel release notes.


Inside the makefile i saw a comment like "gcc-3.4 and binutils-2.14 are a fatal combination".

This must have been because of a bug. Either in gcc or the binutils or both. Since both gcc and the binutils have moved on from these particular versions this should not be an issue for you.


Can someone explain to me what is the relation between the gcc, binutils and kernel versions?

It is sometimes the case that a compiler enhancement requires support from the assembler and/or linker in order to work properly. This then introduces a dependency between gcc and the binutils. ie in order to use new feature "FOO" provided by gcc version G.GG it would also be necessary to install binutils version B.BB or later.


If the kernel makes use of new feature "FOO" then it too inherits this dependency upon a minimum binutils release version.


Do newer versions of binutils output a different object file format
> (which will be understood only by particular versions of kernel onwards).

No - the object file format is fixed when the tools (gcc and binutils) are configured and built. If you obtain a new release of the sources for one of tools and re-run the configure/build process, then providing that you have not changed the configuration you will still be using the same object file format.

Please note however that it may be the case that the new version of binutils will put things into the object files that it creates which cannot be understood by older versions of the binutils. ie the format of the object files has not changed, but the contents of the object files may well be different.

In such case if i use a new compiler/binutils(gcc-4.x,binutils-2.12)

binutils 2.12 is a *old* version. The latest version is 2.17.


and an old kernel(linux-2.4.20), will there be problems?

Almost certainly. But not because of the binutils version, but rather the gcc version. The 4.x series of gcc compilers are a lot more strict about language conformance and will probably complain about all kinds of things in the 2.4.20 sources.


Cheers
  Nick


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]