binutils/gcc: shared lib support (with classy OS file)

This commit is contained in:
Lephenixnoir 2021-11-07 18:04:26 +01:00
parent 5cbd1de540
commit 46eb2a9a2e
Signed by untrusted user: Lephenixnoir
GPG Key ID: 1BBA026E13FC0495
3 changed files with 19 additions and 1 deletions

View File

@ -3252,6 +3252,7 @@ sh-*-elf* | sh[12346l]*-*-elf* | \
tm_file="${tm_file} sh/embed-elf.h"
tm_file="${tm_file} sh/superh.h"
extra_options="${extra_options} sh/superh.opt" ;;
sh*-*-vhex*) tm_file="${tm_file} sh/vhex.h" ;;
*) if test x$with_newlib = xyes \
&& test x$with_libgloss = xyes; then
tm_file="${tm_file} sh/newlib.h"

View File

@ -0,0 +1,16 @@
#undef STARTFILE_SPEC
#define STARTFILE_SPEC \
""
#undef ENDFILE_SPEC
#define ENDFILE_SPEC \
""
#undef LIB_SPEC
#define LIB_SPEC "-lc"
#undef USER_LABEL_PREFIX
#define USER_LABEL_PREFIX "_"
#undef LINK_SPEC
#define LINK_SPEC SH_LINK_SPEC "%{shared:-shared} %{static:-static} %{!shared: %{!static: %{rdynamic:-export-dynamic}}}"

View File

@ -1359,7 +1359,8 @@ sh-*-rtems*)
libgcc-Os-4-200.a libgcc-4-300.a"
;;
sh*-*-vhex*)
tmake_file="${tmake_file} sh/t-sh t-slibgcc-libgcc t-libgcc-pic"
tmake_file="${tmake_file} sh/t-sh t-slibgcc t-slibgcc-libgcc t-libgcc-pic \
t-fdpbit"
;;
sh-wrs-vxworks)
tmake_file="$tmake_file sh/t-sh t-crtstuff-pic t-fdpbit"