https://sourceware.org/bugzilla/show_bug.cgi?id=25236
--- Comment #6 from Fangrui Song <i at maskray dot me> --- To make sure we are on the same page. In the case that both a.o and a.so define the common symbol: The definition from a.o wins. --version-script should apply versions on the definition. At runtime, the shared object should refer to the executable's symbol. (This is the regular rule for definitions.) st_size: largest st_size from all object files and shared objects alignment: largest st_value (alignment) from all object files and shared objects In my pasted example, mpi_fortran_argvs_null_ should have the default version OMPI_2.0.0 and st_size=8. Action items: gold/lld: respect st_size/st_value in shared objects ld: fix VER_NDX_LOCAL -- You are receiving this mail because: You are on the CC list for the bug.