summaryrefslogtreecommitdiff
path: root/libpthread
diff options
context:
space:
mode:
authorJoakim Tjernlund <joakim.tjernlund@transmode.se>2005-05-28 21:18:22 +0000
committerJoakim Tjernlund <joakim.tjernlund@transmode.se>2005-05-28 21:18:22 +0000
commit75ca73f431add9f5b04591023318f4274744289d (patch)
treef81e4f5e1b727b25023488d46c90c8fbf9ece60d /libpthread
parenta07dafe8491978491ad174ff3cc472546bc921f7 (diff)
Add patch at bugs 274. From Peter Manzinger.
Diffstat (limited to 'libpthread')
-rw-r--r--libpthread/Makefile23
-rw-r--r--libpthread/linuxthreads/Makefile7
-rw-r--r--libpthread/linuxthreads_db/Makefile7
3 files changed, 6 insertions, 31 deletions
diff --git a/libpthread/Makefile b/libpthread/Makefile
index 81979feb9..12411e6df 100644
--- a/libpthread/Makefile
+++ b/libpthread/Makefile
@@ -19,8 +19,6 @@
TOPDIR=../
include $(TOPDIR)Rules.mak
-CFLAGS+=$(SSP_ALL_CFLAGS)
-
#Adjust the soname version to avoid namespace collisions with glibc's libpthread
LIBPTHREAD=libpthread.a
LIBPTHREAD_SHARED=libpthread.so
@@ -33,25 +31,8 @@ LIBTHREAD_DB_SHARED_FULLNAME=libthread_db-$(MAJOR_VERSION).$(MINOR_VERSION).$(SU
DIRS=
ifeq ($(strip $(UCLIBC_HAS_THREADS)),y)
DIRS+=linuxthreads
- LDFLAGS_THREAD:= $(CPU_LDFLAGS-y) -shared --warn-common --warn-once -z combreloc -z defs
-ifeq ($(UCLIBC_BUILD_RELRO),y)
- LDFLAGS_THREAD+=-z relro
-endif
-ifeq ($(UCLIBC_BUILD_NOW),y)
- LDFLAGS_THREAD+=-z now
-endif
ifeq ($(strip $(PTHREADS_DEBUG_SUPPORT)),y)
DIRS+=linuxthreads_db
- LDFLAGS_THREAD_DB:= $(CPU_LDFLAGS-y) -shared --warn-common --warn-once -z combreloc
-endif
-ifeq ($(DODEBUG),n)
- LDFLAGS_THREAD_DB+=-s
-ifeq ($(UCLIBC_BUILD_RELRO),y)
- LDFLAGS_THREAD_DB+=-z relro
-endif
-ifeq ($(UCLIBC_BUILD_NOW),y)
- LDFLAGS_THREAD_DB+=-z now
-endif
endif
endif
@@ -87,7 +68,7 @@ $(OBJ): Makefile
shared: all
ifeq ($(strip $(UCLIBC_HAS_THREADS)),y)
- $(LD) $(LDFLAGS_THREAD) -soname=$(LIBPTHREAD_SHARED).$(MAJOR_VERSION) \
+ $(LD) $(LDFLAGS_NOSTRIP) -soname=$(LIBPTHREAD_SHARED).$(MAJOR_VERSION) \
-o $(LIBPTHREAD_SHARED_FULLNAME) $(SHARED_START_FILES) --whole-archive $(LIBPTHREAD) \
--no-whole-archive $(TOPDIR)libc/misc/internals/interp.o \
-L$(TOPDIR)lib -lc $(LDADD_LIBFLOAT) $(LIBGCC) \
@@ -102,7 +83,7 @@ ifeq ($(strip $(UCLIBC_HAS_THREADS)),y)
$(TOPDIR)lib/$(LIBPTHREAD_SHARED).$(MAJOR_VERSION)
endif
ifeq ($(strip $(PTHREADS_DEBUG_SUPPORT)),y)
- $(LD) $(LDFLAGS_THREAD_DB) -soname=$(LIBTHREAD_DB_SHARED).1 \
+ $(LD) $(LDFLAGS) --warn-unresolved-symbols -soname=$(LIBTHREAD_DB_SHARED).1 \
-o $(LIBTHREAD_DB_SHARED_FULLNAME) --whole-archive $(LIBTHREAD_DB) \
--no-whole-archive $(TOPDIR)libc/misc/internals/interp.o \
-L$(TOPDIR)lib -lc $(LDADD_LIBFLOAT) $(LIBGCC)
diff --git a/libpthread/linuxthreads/Makefile b/libpthread/linuxthreads/Makefile
index 50fc20cdf..cca65d51c 100644
--- a/libpthread/linuxthreads/Makefile
+++ b/libpthread/linuxthreads/Makefile
@@ -33,18 +33,15 @@ SYSDEPS_DIR:=$(TARGET_ARCH)/sparc32
else
SYSDEPS_DIR:=$(TARGET_ARCH)
endif
+CFLAGS += $(SSP_ALL_CFLAGS)
#This stuff will not compile without at least -O1
CFLAGS :=$(CFLAGS:-O0=-O1)
# set up system dependencies include dirs (NOTE: order matters!)
PTDIR = $(TOPDIR)libpthread/linuxthreads/
-SYSDEPINC = -I$(PTDIR)sysdeps/unix/sysv/linux \
- -I$(PTDIR)sysdeps/pthread \
- -I$(PTDIR)sysdeps/unix/sysv \
- -I$(PTDIR)sysdeps/unix/unix \
+SYSDEPINC = -I$(PTDIR)sysdeps/pthread \
-I$(PTDIR)sysdeps/$(TARGET_ARCH) \
- -I$(PTDIR)sysdeps \
-I$(TOPDIR)libc/sysdeps/linux/$(TARGET_ARCH)
CFLAGS += $(SYSDEPINC)
diff --git a/libpthread/linuxthreads_db/Makefile b/libpthread/linuxthreads_db/Makefile
index 656275fa9..66015be12 100644
--- a/libpthread/linuxthreads_db/Makefile
+++ b/libpthread/linuxthreads_db/Makefile
@@ -30,13 +30,10 @@ endif
# set up system dependencies include dirs (NOTE: order matters!)
PTDIR = $(TOPDIR)libpthread/linuxthreads/
-SYSDEPINC = -I$(PTDIR)sysdeps/unix/sysv/linux \
- -I$(PTDIR)sysdeps/pthread \
- -I$(PTDIR)sysdeps/unix/sysv \
- -I$(PTDIR)sysdeps/unix/unix \
+SYSDEPINC = -I$(PTDIR)sysdeps/pthread \
-I$(PTDIR)sysdeps/$(TARGET_ARCH) \
- -I$(PTDIR)sysdeps \
-I$(TOPDIR)libc/sysdeps/linux/$(TARGET_ARCH)
+#CFLAGS += $(SSP_ALL_CFLAGS)
CFLAGS += $(SYSDEPINC) -DLIBPTHREAD_SO="\"libpthread.so.$(MAJOR_VERSION)\""
CSRC= td_init.c td_log.c td_ta_delete.c td_ta_get_nthreads.c \