Assume the x86 64 and linux platform.
If you look into the ELF header, the offset are all 64bit.
So it's easy to create an object file larger than 4G with relocatoin R_X86_64_64. This means a static .o file and executable can be as large as 64bit can represent.
However, for shared library, like gcc , we only have R_X86_64_PLT32 relocation. This means that it's impossible to create a shared library large than 4GB, right?
So if I want to build a huge program, one of the .o file is huge enough (>4GB) , the only choice is static linking?
Any comment is welcome.
Thanks, limi