summaryrefslogtreecommitdiff
path: root/libpthread/linuxthreads/Makefile.in
diff options
context:
space:
mode:
authorPeter S. Mazinger <ps.m@gmx.net>2005-10-19 21:26:55 +0000
committerPeter S. Mazinger <ps.m@gmx.net>2005-10-19 21:26:55 +0000
commitaae5316cbd05d8b04815d79fd532a6334c61582e (patch)
treefa5b2321393d39daf6ca38bc76503ddd67950537 /libpthread/linuxthreads/Makefile.in
parent5e48b8b628e885ffd0772c991a6efa5a74946b9e (diff)
Add the linuxthreads Makefiles too
Diffstat (limited to 'libpthread/linuxthreads/Makefile.in')
-rw-r--r--libpthread/linuxthreads/Makefile.in55
1 files changed, 55 insertions, 0 deletions
diff --git a/libpthread/linuxthreads/Makefile.in b/libpthread/linuxthreads/Makefile.in
new file mode 100644
index 000000000..ed24d3f5c
--- /dev/null
+++ b/libpthread/linuxthreads/Makefile.in
@@ -0,0 +1,55 @@
+# Makefile.in for uClibc
+#
+# Licensed under LGPL v2.1, see the file COPYING.LIB in this tarball for details.
+#
+
+CFLAGS+=$(SSP_ALL_CFLAGS)
+
+# Get the thread include dependencies
+CFLAGS+=$(PTINC)
+
+# This stuff will not compile without at least -O1
+CFLAGS:=$(CFLAGS:-O0=-O1)
+
+ARCH_CFLAGS:=$(CFLAGS)
+
+LDFLAGS:=$(LDFLAGS_NOSTRIP)
+
+ifeq ($(UCLIBC_CTOR_DTOR),y)
+SHARED_START_FILES=$(top_builddir)lib/crti.o $(LIBGCC_DIR)crtbeginS.o
+SHARED_END_FILES = $(LIBGCC_DIR)crtendS.o $(top_builddir)lib/crtn.o
+endif
+
+ifeq ($(PTHREADS_DEBUG_SUPPORT),y)
+STRIP_FLAGS:=-X --strip-debug -R .note -R .comment
+endif
+
+LIB_NAME:=libpthread
+srcdir=$(top_srcdir)$(LIB_NAME)/linuxthreads
+$(LIB_NAME)_DIR:=$(top_builddir)$(LIB_NAME)/linuxthreads
+
+$(LIB_NAME)_SRC:=$(wildcard $(srcdir)/*.c)
+ifneq ($(UCLIBC_HAS_XLOCALE),y)
+$(LIB_NAME)_SRC:=$(filter-out $(srcdir)/locale.c,$($(LIB_NAME)_SRC))
+endif
+
+ARCH_DIR:=sysdeps/$(TARGET_ARCH)
+-include $(srcdir)/$(ARCH_DIR)/Makefile.in
+
+$(LIB_NAME)_ARCH_SRC:=$(wildcard $(srcdir)/$(ARCH_DIR)/*.c)
+$(LIB_NAME)_ARCH_OBJ:=$(patsubst $(srcdir)/$(ARCH_DIR)/%.c,$($(LIB_NAME)_DIR)/$(ARCH_DIR)/%.o,$($(LIB_NAME)_ARCH_SRC))
+
+# remove generic sources, if arch specific version is present
+$(LIB_NAME)_NO_SRC:=$(patsubst $(srcdir)/$(ARCH_DIR)/%.c,$(srcdir)/%.c,$($(LIB_NAME)_ARCH_SRC))
+$(LIB_NAME)_SRC:=$(filter-out $($(LIB_NAME)_NO_SRC),$($(LIB_NAME)_SRC))
+# add arch specific sources (assumed that these are not multi-sources)
+$(LIB_NAME)_SRC+=$($(LIB_NAME)_ARCH_SRC)
+
+$(LIB_NAME)_arch_clean:
+ $(RM) $($(LIB_NAME)_DIR)/sysdeps/*/*.{o,os}
+
+libso-$(UCLIBC_HAS_THREADS)+=$(top_builddir)lib/$(LIB_NAME).so
+liba-$(UCLIBC_HAS_THREADS)+=$(top_builddir)lib/$(LIB_NAME).a
+libclean-y+=$(LIB_NAME)_clean $(LIB_NAME)_arch_clean
+
+include $(top_srcdir)Makefile.libs