summaryrefslogtreecommitdiff
path: root/libpthread/linuxthreads
diff options
context:
space:
mode:
authorPeter S. Mazinger <ps.m@gmx.net>2005-10-25 22:17:39 +0000
committerPeter S. Mazinger <ps.m@gmx.net>2005-10-25 22:17:39 +0000
commita80fc77b658a7883df95ac41ad83ac9ff7c8ff07 (patch)
tree3edbcb812b876e0ba1424b229d50e9c04a2b0d4a /libpthread/linuxthreads
parent7ce8f67d27885ea6b1cba2c43e5edc9f1dc17f0f (diff)
All Makefile.in's. Only arm/i386/mips/powerpc/x86_64 are done, the other archs lack proper crt1. The Makefiles in extra/scripts are intended to be linked into each dir, where it is necessary to build locally.
Diffstat (limited to 'libpthread/linuxthreads')
-rw-r--r--libpthread/linuxthreads/Makefile.in59
-rw-r--r--libpthread/linuxthreads/sysdeps/sh64/Makefile.in33
2 files changed, 50 insertions, 42 deletions
diff --git a/libpthread/linuxthreads/Makefile.in b/libpthread/linuxthreads/Makefile.in
index ed24d3f5c..026fd1452 100644
--- a/libpthread/linuxthreads/Makefile.in
+++ b/libpthread/linuxthreads/Makefile.in
@@ -1,55 +1,56 @@
-# Makefile.in for uClibc
+# Makefile for uClibc's pthread library
#
-# Licensed under LGPL v2.1, see the file COPYING.LIB in this tarball for details.
+# Copyright (C) 2003 Paul Mundt <lethal@linux-sh.org>
+# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
+#
+# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
#
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
+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
+DOMULTI=n
+
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
+libpthread_DIR:=$(top_srcdir)libpthread/linuxthreads
+libpthread_OUT:=$(top_builddir)libpthread/linuxthreads
-ARCH_DIR:=sysdeps/$(TARGET_ARCH)
--include $(srcdir)/$(ARCH_DIR)/Makefile.in
+ARCH_CFLAGS:=$(CFLAGS)
+-include $(libpthread_DIR)/sysdeps/$(TARGET_ARCH)/Makefile.in
+CFLAGS:=$(ARCH_CFLAGS)
-$(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))
+libpthread_SRC:=$(wildcard $(libpthread_DIR)/*.c)
+ifneq ($(UCLIBC_HAS_XLOCALE),y)
+libpthread_SRC:=$(filter-out $(libpthread_DIR)/locale.c,$(libpthread_SRC))
+endif
# 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)
+ifneq ($(strip $(libpthread_ARCH_SRC)),)
+libpthread_SRC:=$(filter-out $(patsubst %.c,$(libpthread_DIR)/%.c,$(notdir $(libpthread_ARCH_SRC))),$(libpthread_SRC))
+endif
+
+libpthread_OBJ:=$(patsubst $(libpthread_DIR)/%.c,$(libpthread_OUT)/%.o,$(libpthread_SRC))
-$(LIB_NAME)_arch_clean:
- $(RM) $($(LIB_NAME)_DIR)/sysdeps/*/*.{o,os}
+libpthread-a-$(UCLIBC_HAS_THREADS)+=$(libpthread_OBJ)
+libpthread-a-pic-$(UCLIBC_HAS_THREADS)+=$(libpthread_OBJ:.o=.os)
+libpthread-so-$(UCLIBC_HAS_THREADS)+=$(libpthread_OBJ:.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
+libpthread-multi-$(UCLIBC_HAS_THREADS)+=$(libpthread_SRC)
-include $(top_srcdir)Makefile.libs
+lib-a-$(UCLIBC_HAS_THREADS)+=$(top_builddir)lib/libpthread.a
+lib-a-pic-$(UCLIBC_HAS_THREADS)+=$(top_builddir)lib/libpthread.a
+lib-so-$(UCLIBC_HAS_THREADS)+=$(top_builddir)lib/libpthread.so
diff --git a/libpthread/linuxthreads/sysdeps/sh64/Makefile.in b/libpthread/linuxthreads/sysdeps/sh64/Makefile.in
index fed7a83b7..5aa54a64f 100644
--- a/libpthread/linuxthreads/sysdeps/sh64/Makefile.in
+++ b/libpthread/linuxthreads/sysdeps/sh64/Makefile.in
@@ -1,20 +1,27 @@
# Makefile for uClibc's sh64 pthread backend
#
# Copyright (C) 2003 Paul Mundt <lethal@linux-sh.org>
+# Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
#
-# This program is free software; you can redistribute it and/or modify it under
-# the terms of the GNU Library General Public License as published by the Free
-# Software Foundation; either version 2 of the License, or (at your option) any
-# later version.
+# Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
#
-# This program is distributed in the hope that it will be useful, but WITHOUT
-# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
-# FOR A PARTICULAR PURPOSE. See the GNU Library General Public License for more
-# details.
-#
-# You should have received a copy of the GNU Library General Public License
-# along with this program; if not, write to the Free Software Foundation, Inc.,
-# 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
# We need to build as SHcompact for tas..
-ARCH_CFLAGS := $(subst 32media,compact,$(ARCH_CFLAGS))
+ARCH_CFLAGS:=$(subst 32media,compact,$(ARCH_CFLAGS))
+
+libpthread_ARCH_DIR:=$(top_srcdir)libpthread/linuxthreads/sysdeps/sh64
+libpthread_ARCH_OUT:=$(top_builddir)libpthread/linuxthreads/sysdeps/sh64
+
+libpthread_ARCH_SRC:=$(wildcard $(libpthread_ARCH_DIR)/*.c)
+libpthread_ARCH_OBJ:=$(patsubst $(libpthread_ARCH_DIR)/%.c,$(libpthread_ARCH_OUT)/%.o,$(libpthread_ARCH_SRC))
+
+libpthread-a-$(UCLIBC_HAS_THREADS)+=$(libpthread_ARCH_OBJ)
+libpthread-a-pic-$(UCLIBC_HAS_THREADS)+=$(libpthread_ARCH_OBJ:.o=.os)
+libpthread-so-$(UCLIBC_HAS_THREADS)+=$(libpthread_ARCH_OBJ:.o=.os)
+
+libpthread-multi-$(UCLIBC_HAS_THREADS)+=$(libpthread_ARCH_SRC)
+
+objclean-y+=libpthread_arch_objclean
+
+libpthread_arch_objclean:
+ $(RM) $(libpthread_ARCH_OUT)/*.{o,os}