t-libunwind-elf revision 146895
1146895Skan# Build libunwind for ELF with the GNU linker. 2146895Skan 3146895Skan# Use unwind-dw2-fde-glibc 4146895SkanLIBUNWIND = $(srcdir)/unwind-dw2.c $(srcdir)/unwind-dw2-fde-glibc.c 5146895SkanLIBUNWINDDEP = unwind.inc unwind-dw2-fde.h unwind-dw2-fde.c 6146895Skan 7146895SkanSHLIBUNWIND_SOVERSION = 7 8146895SkanSHLIBUNWIND_SONAME = @shlib_so_name@.so.$(SHLIBUNWIND_SOVERSION) 9146895SkanSHLIBUNWIND_NAME = @shlib_dir@@shlib_so_name@.so.$(SHLIBUNWIND_SOVERSION) 10146895Skan 11146895SkanSHLIBUNWIND_LINK = $(GCC_FOR_TARGET) $(LIBGCC2_CFLAGS) -shared \ 12146895Skan -nodefaultlibs -Wl,-h,$(SHLIBUNWIND_SONAME) \ 13146895Skan -Wl,-z,text -Wl,-z,defs -o $(SHLIBUNWIND_NAME).tmp \ 14146895Skan @multilib_flags@ $(SHLIB_OBJS) -lc && \ 15146895Skan rm -f $(SHLIB_SOLINK) && \ 16146895Skan if [ -f $(SHLIBUNWIND_NAME) ]; then \ 17146895Skan mv -f $(SHLIBUNWIND_NAME) $(SHLIBUNWIND_NAME).backup; \ 18146895Skan else true; fi && \ 19146895Skan mv $(SHLIBUNWIND_NAME).tmp $(SHLIBUNWIND_NAME) && \ 20146895Skan $(LN_S) $(SHLIBUNWIND_NAME) $(SHLIB_SOLINK) 21146895Skan 22146895Skan# $(slibdir) double quoted to protect it from expansion while building 23146895Skan# libgcc.mk. We want this delayed until actual install time. 24146895SkanSHLIBUNWIND_INSTALL = \ 25146895Skan $$(SHELL) $$(srcdir)/mkinstalldirs $$(DESTDIR)$$(slibdir)$(SHLIB_SLIBDIR_QUAL); \ 26146895Skan $(INSTALL_DATA) $(SHLIBUNWIND_NAME) \ 27146895Skan $$(DESTDIR)$$(slibdir)$(SHLIB_SLIBDIR_QUAL)/$(SHLIBUNWIND_SONAME); \ 28146895Skan rm -f $$(DESTDIR)$$(slibdir)$(SHLIB_SLIBDIR_QUAL)/$(SHLIB_SOLINK); \ 29146895Skan $(LN_S) $(SHLIBUNWIND_SONAME) \ 30146895Skan $$(DESTDIR)$$(slibdir)$(SHLIB_SLIBDIR_QUAL)/$(SHLIB_SOLINK) 31