From 143b7505a2cc505e94bde9b82cad4f695d15433d Mon Sep 17 00:00:00 2001 From: Bernhard Reutner-Fischer Date: Wed, 10 Sep 2014 22:18:55 +0200 Subject: nptl: rephrase *.sym handling Avoids circular dependency warning from make by generating the .h directly from the .sym files, elimination intermediate files. Signed-off-by: Bernhard Reutner-Fischer --- libpthread/nptl/sysdeps/Makefile.commonarch | 18 +++++++----------- 1 file changed, 7 insertions(+), 11 deletions(-) (limited to 'libpthread/nptl/sysdeps/Makefile.commonarch') diff --git a/libpthread/nptl/sysdeps/Makefile.commonarch b/libpthread/nptl/sysdeps/Makefile.commonarch index 8f5d61dcd..a5952a67b 100644 --- a/libpthread/nptl/sysdeps/Makefile.commonarch +++ b/libpthread/nptl/sysdeps/Makefile.commonarch @@ -40,15 +40,12 @@ librt_arch_COBJ = $(patsubst %.c,$(libpthread_arch_OUT)/%.o,$(librt_arch_CSRC)) librt_arch_SOBJ = $(patsubst %.S,$(libpthread_arch_OUT)/%.o,$(librt_arch_SSRC)) librt_arch_OBJS = $(librt_arch_COBJ) $(librt_arch_SOBJ) -CFLAGS-gen_tcb-offsets.c = -S -$(libpthread_arch_OUT)/gen_tcb-offsets.c: $(libpthread_arch_DIR)/tcb-offsets.sym | $(libpthread_arch_OUT) - $(do_awk) $(top_srcdir)extra/scripts/gen-as-const.awk $< > $@ - -$(libpthread_arch_OUT)/gen_tcb-offsets.s: $(libpthread_arch_OUT)/gen_tcb-offsets.c | headers - $(compile.c) -libpthread-generated-y += $(libpthread_arch_OUT)/gen_tcb-offsets.s -$(libpthread_arch_OUT)/tcb-offsets.h: $(libpthread_arch_OUT)/gen_tcb-offsets.s - $(do_sed) $(PTHREAD_GENERATE_MANGLE) $< > $@ +$(libpthread_arch_OUT)/tcb-offsets.h: $(top_srcdir)extra/scripts/gen-as-const.awk | headers +$(libpthread_arch_OUT)/tcb-offsets.h: $(libpthread_arch_DIR)/tcb-offsets.sym + @$(disp_gen) + $(do_awk) $(top_srcdir)extra/scripts/gen-as-const.awk $< \ + | $(CC) $(CFLAGS) -x c - -S -o - \ + | $(SED) $(PTHREAD_GENERATE_MANGLE) > $@ @if test ! -s $@ ; then rm -f $@ ; false ; fi pregen-headers-$(UCLIBC_HAS_THREADS_NATIVE) += $(libpthread_arch_OUT)/tcb-offsets.h @@ -59,8 +56,7 @@ headers_clean-y+= HEADERCLEAN_$(subst $(top_builddir),,$(libpthread_arch_OUT)) CLEAN_$(subst $(top_builddir),,$(libpthread_arch_OUT)): $(do_rm) $(addprefix $(libpthread_arch_OUT)/*., o os oS) HEADERCLEAN_$(subst $(top_builddir),,$(libpthread_arch_OUT)): - $(do_rm) $(libpthread_arch_OUT)/tcb-offsets.h \ - $(addprefix $(libpthread_arch_OUT)/gen_tcb-offsets., c h s) + $(do_rm) $(libpthread_arch_OUT)/tcb-offsets.h ifneq ($(TARGET_SUBARCH),) objclean-y += CLEAN_$(subst $(top_builddir),,$(libpthread_subarch_OUT)) CLEAN_$(subst $(top_builddir),,$(libpthread_subarch_OUT)): -- cgit v1.2.3