https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96190
--- Comment #4 from CVS Commits <cvs-commit at gcc dot gnu.org> --- The releases/gcc-10 branch has been updated by Sergei Trofimovich <sly...@gcc.gnu.org>: https://gcc.gnu.org/g:ca47325f300462b6f4ea84de2103eef81a4a7684 commit r10-8527-gca47325f300462b6f4ea84de2103eef81a4a7684 Author: Sergei Trofimovich <siarh...@google.com> Date: Thu Jul 23 23:58:35 2020 +0100 sparc/sparc64: use crtendS.o for default-pie executables [PR96190] In --enable-default-pie mode compiler should switch from using crtend.o to crtendS.o. On sparc it is especially important because crtend.o contains PIC-unfriendly code. We use GNU_USER_TARGET_ENDFILE_SPEC as a baseline spec to get crtendS.o instead of crtend.o in !no-pie mode. gcc: 2020-07-14 Sergei Trofimovich <siarh...@google.com> PR target/96190 * config/sparc/linux.h (ENDFILE_SPEC): Use GNU_USER_TARGET_ENDFILE_SPEC to get crtendS.o for !no-pie mode. * config/sparc/linux64.h (ENDFILE_SPEC): Ditto. (cherry picked from commit 87891d5eafe8d1de90b9d9b056eca81c508d1c77)