summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Makefile.in2
-rw-r--r--libpthread/nptl/Makefile.in35
-rw-r--r--libpthread/nptl/sysdeps/unix/sysv/linux/Makefile.in4
3 files changed, 18 insertions, 23 deletions
diff --git a/Makefile.in b/Makefile.in
index d6faec0f5..628091876 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -395,7 +395,7 @@ hostutils:
install_hostutils: hostutils
$(Q)$(MAKE) CROSS="$(CROSS)" CC="$(CC)" HOSTCC="$(HOSTCC)" DOTHOST=.host -C utils utils_install
-$(addprefix $(top_builddir),include/bits include/sys include/config lib extra/config/lxdialog extra/locale extra/scripts $(subdirs)):
+$(addprefix $(top_builddir),include include/bits include/sys include/config lib extra/config/lxdialog extra/locale extra/scripts $(subdirs)):
$(do_mkdir)
# configuration
diff --git a/libpthread/nptl/Makefile.in b/libpthread/nptl/Makefile.in
index 853ac501e..3accff70f 100644
--- a/libpthread/nptl/Makefile.in
+++ b/libpthread/nptl/Makefile.in
@@ -320,26 +320,21 @@ pregen-headers-$(UCLIBC_HAS_THREADS_NATIVE) += $(PTHREAD_OUT)/pthread-errnos.h
headers-$(UCLIBC_HAS_THREADS_NATIVE) += $(nptl_headers_bootstrap)
-$(top_builddir)include/pthread.h:
- $(do_ln) ../$(PTDIR)/sysdeps/pthread/$(@F) $(top_builddir)$@
-$(top_builddir)include/semaphore.h:
- $(do_ln) ../$(PTDIR)/$(@F) $(top_builddir)$@
-$(top_builddir)include/bits/semaphore.h: | include/bits
- $(do_ln) ../../$(PTDIR)/sysdeps/unix/sysv/linux/$(TARGET_ARCH)/bits/$(@F) $(top_builddir)$@
-$(top_builddir)include/bits/pthreadtypes.h: | include/bits
- $(do_ln) ../../$(PTDIR)/sysdeps/unix/sysv/linux/$(TARGET_ARCH)/bits/$(@F) $(top_builddir)$@
-$(top_builddir)include/bits/libc-lock.h: | include/bits
- $(do_ln) ../../$(PTDIR)/sysdeps/pthread/bits/$(@F) $(top_builddir)$@
-$(top_builddir)include/bits/stdio-lock.h: | include/bits
- $(do_ln) ../../$(PTDIR)/sysdeps/pthread/bits/$(@F) $(top_builddir)$@
-
-nptl_headers_bootstrap := $(top_builddir)include/pthread.h \
- $(top_builddir)include/semaphore.h \
- $(top_builddir)include/bits/semaphore.h \
- $(top_builddir)include/bits/pthreadtypes.h \
- $(top_builddir)include/bits/libc-lock.h \
- $(top_builddir)include/bits/stdio-lock.h
-
+LIBPTHREAD_H := $(addprefix $(top_builddir)include/,semaphore.h)
+LIBPTHREAD_INCLUDE_H := $(addprefix $(top_builddir)include/,pthread.h)
+LIBPTHREAD_INCLUDE_BITS_H := $(addprefix $(top_builddir)include/bits/,libc-lock.h stdio-lock.h)
+LIBPTHREAD_INCLUDE_STD_IMPL_OS_ARCH_BITS_H := $(addprefix $(top_builddir)include/bits/,pthreadtypes.h semaphore.h)
+
+$(LIBPTHREAD_INCLUDE_STD_IMPL_OS_ARCH_BITS_H): $(top_builddir)include/bits/%: | $(top_builddir)include/bits
+ $(do_ln) $(call rel_srcdir)$(PTDIR)/sysdeps/unix/sysv/linux/$(TARGET_ARCH)/bits/$(@F) $@
+$(LIBPTHREAD_INCLUDE_BITS_H): $(top_builddir)include/bits/%: | $(top_builddir)include/bits
+ $(do_ln) $(call rel_srcdir)$(PTDIR)/sysdeps/pthread/bits/$(@F) $@
+$(LIBPTHREAD_INCLUDE_H): $(top_builddir)include/%: | $(top_builddir)include
+ $(do_ln) $(call rel_srcdir)$(PTDIR)/sysdeps/pthread/$(@F) $@
+$(LIBPTHREAD_H): $(top_builddir)include/%: | $(top_builddir)include
+ $(do_ln) $(call rel_srcdir)$(PTDIR)/$(@F) $@
+
+nptl_headers_bootstrap = $(LIBPTHREAD_H) $(LIBPTHREAD_INCLUDE_H) $(LIBPTHREAD_INCLUDE_BITS_H) $(LIBPTHREAD_INCLUDE_STD_IMPL_OS_ARCH_BITS_H)
HEADERCLEAN_libpthread/nptl:
$(do_rm) $(nptl_headers_bootstrap) \
diff --git a/libpthread/nptl/sysdeps/unix/sysv/linux/Makefile.in b/libpthread/nptl/sysdeps/unix/sysv/linux/Makefile.in
index c2ade848e..b1a35c352 100644
--- a/libpthread/nptl/sysdeps/unix/sysv/linux/Makefile.in
+++ b/libpthread/nptl/sysdeps/unix/sysv/linux/Makefile.in
@@ -232,8 +232,8 @@ pregen-headers-$(UCLIBC_HAS_THREADS_NATIVE) += \
HEADERS_BITS_PTHREAD := $(notdir $(wildcard $(PTHREAD_LINUX_DIR)/bits/*.h))
ALL_HEADERS_BITS_PTHREAD := $(addprefix include/bits/,$(HEADERS_BITS_PTHREAD))
-$(ALL_HEADERS_BITS_PTHREAD):
- $(do_ln) ../../$(PTHREAD_LINUX_DIR)/bits/$(@F) $(top_builddir)$@
+$(ALL_HEADERS_BITS_PTHREAD): $(top_builddir)include/bits/%: | $(top_builddir)include/bits
+ $(do_ln) $(call rel_srcdir)$(PTHREAD_LINUX_DIR)/bits/$(@F) $@
HEADERCLEAN_libpthread/nptl/sysdeps/unix/sysv/linux:
$(do_rm) $(addprefix $(PTHREAD_LINUX_OUT)/gen_lowlevelbarrier., c s) \