From 638c2396a2a7c0481bea536775544364fbde6fa8 Mon Sep 17 00:00:00 2001 From: Bernhard Reutner-Fischer Date: Mon, 21 Jun 2010 11:25:11 +0200 Subject: fix race condition when generating linker scripts Signed-off-by: Bernhard Reutner-Fischer --- libpthread/linuxthreads/Makefile.in | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'libpthread') diff --git a/libpthread/linuxthreads/Makefile.in b/libpthread/linuxthreads/Makefile.in index fd9586a51..697371b08 100644 --- a/libpthread/linuxthreads/Makefile.in +++ b/libpthread/linuxthreads/Makefile.in @@ -94,8 +94,9 @@ $(top_builddir)lib/libpthread.so: $(libpthread_OUT)/libpthread_so.a $(libc.depen # $(call linkm.so,$(libpthread_FULL_NAME),$(ABI_VERSION)) #endif $(Q)$(RM) $@ - $(Q)cp $(top_srcdir)extra/scripts/format.lds $@ - $(Q)echo "GROUP ( $(notdir $@).$(ABI_VERSION) libpthread_nonshared.a )" >> $@ + $(Q)cat $(top_srcdir)extra/scripts/format.lds > $@.tmp + $(Q)echo "GROUP ( $(notdir $@).$(ABI_VERSION) libpthread_nonshared.a )" >> $@.tmp + $(Q)mv $@.tmp $@ ifeq ($(PTHREADS_DEBUG_SUPPORT),y) $(libpthread_OUT)/libpthread_so.a: STRIP_FLAGS:=$(STRIP_FLAGS:-x=-X --strip-debug) -- cgit v1.2.3