1# Compile crtbeginS.o and crtendS.o with pic. 2CRTSTUFF_T_CFLAGS_S = -fPIC 3 4# Compile libgcc2.a with pic. 5TARGET_LIBGCC2_CFLAGS = -fPIC 6 7# Build a shared libgcc library. 8SHLIB_EXT = .so 9SHLIB_NAME = @shlib_base_name@.so 10SHLIB_SONAME = @shlib_base_name@.so.1 11SHLIB_OBJS = @shlib_objs@ 12 13# Hide all POSIX threads related symbols provided by gthr-posix.c. This 14# only has an effect if t-osf-pthread is in use. 15SHLIB_LINK = $(GCC_FOR_TARGET) $(LIBGCC2_CFLAGS) -shared -nodefaultlibs \ 16 -Wl,-hidden_symbol,pthread\* -Wl,-hidden_symbol,__pthread\* \ 17 -Wl,-hidden_symbol,sched_get_\* -Wl,-hidden_symbol,sched_yield \ 18 -Wl,-msym -Wl,-set_version,gcc.1 -Wl,-soname,$(SHLIB_SONAME) \ 19 -o $(SHLIB_NAME).tmp @multilib_flags@ $(SHLIB_OBJS) -lc && \ 20 rm -f $(SHLIB_SONAME) && \ 21 if [ -f $(SHLIB_NAME) ]; then \ 22 mv -f $(SHLIB_NAME) $(SHLIB_NAME).backup; \ 23 else true; fi && \ 24 mv $(SHLIB_NAME).tmp $(SHLIB_NAME) && \ 25 $(LN_S) $(SHLIB_NAME) $(SHLIB_SONAME) 26# $(slibdir) double quoted to protect it from expansion while building 27# libgcc.mk. We want this delayed until actual install time. 28SHLIB_INSTALL = \ 29 $$(mkinstalldirs) $$(DESTDIR)$$(slibdir); \ 30 $(INSTALL_DATA) $(SHLIB_NAME) $$(DESTDIR)$$(slibdir)/$(SHLIB_SONAME); \ 31 rm -f $$(DESTDIR)$$(slibdir)/$(SHLIB_NAME); \ 32 $(LN_S) $(SHLIB_SONAME) $$(DESTDIR)$$(slibdir)/$(SHLIB_NAME) 33