Makefile.in 1.9 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364
  1. # Makefile for uClibc
  2. #
  3. # Copyright (C) 2000-2005 Erik Andersen <andersen@uclibc.org>
  4. #
  5. # Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
  6. #
  7. # Get the thread include dependencies and shared object name
  8. CFLAGS-linuxthreads.old_db := -DLIBPTHREAD_SO="\"libpthread.so.$(MAJOR_VERSION)\""
  9. LDFLAGS-libthread_db.so := $(LDFLAGS_NOSTRIP) -s --warn-unresolved-symbols
  10. LIBS-libthread_db.so := $(LIBS)
  11. libthread_db_FULL_NAME := libthread_db-$(MAJOR_VERSION).$(MINOR_VERSION).$(SUBLEVEL).so
  12. libthread_db_DIR := $(top_srcdir)libpthread/linuxthreads.old_db
  13. libthread_db_OUT := $(top_builddir)libpthread/linuxthreads.old_db
  14. libthread_db_SRC := $(wildcard $(libthread_db_DIR)/*.c)
  15. libthread_db_OBJ := $(patsubst $(libthread_db_DIR)/%.c,$(libthread_db_OUT)/%.o,$(libthread_db_SRC))
  16. ifeq ($(DOPIC),y)
  17. libthread_db-a-y := $(libthread_db_OBJ:.o=.os)
  18. else
  19. libthread_db-a-y := $(libthread_db_OBJ)
  20. endif
  21. libthread_db-so-y := $(libthread_db_OBJ:.o=.os)
  22. libthread_db-multi-y := $(libthread_db_SRC)
  23. lib-a-$(PTHREADS_DEBUG_SUPPORT) += $(top_builddir)lib/libthread_db.a
  24. lib-so-$(PTHREADS_DEBUG_SUPPORT) += $(top_builddir)lib/libthread_db.so
  25. objclean-y += libthread_db_clean
  26. headers-$(PTHREADS_DEBUG_SUPPORT) += linuxthreads_db_headers
  27. headers_clean-y += linuxthreads_db_headers_clean
  28. ifeq ($(DOPIC),y)
  29. $(top_builddir)lib/libthread_db.so: $(top_builddir)lib/libthread_db.a $(libc)
  30. else
  31. $(top_builddir)lib/libthread_db.so: $(libthread_db_OUT)/libthread_db_so.a $(libc)
  32. endif
  33. $(call link.so,$(libthread_db_FULL_NAME),1)
  34. $(libthread_db_OUT)/libthread_db_so.a: $(libthread_db-so-y)
  35. $(Q)$(RM) $@
  36. $(do_strip)
  37. $(do_ar)
  38. $(top_builddir)lib/libthread_db.a: $(libthread_db-a-y)
  39. $(Q)$(INSTALL) -d $(dir $@)
  40. $(Q)$(RM) $@
  41. $(do_strip)
  42. $(do_ar)
  43. linuxthreads_db_headers:
  44. $(LN) -sf ../$(PTDIR)_db/thread_db.h $(top_builddir)include/
  45. linuxthreads_db_headers_clean:
  46. $(RM) $(top_builddir)include/thread_db.h
  47. libthread_db_clean:
  48. $(RM) $(libthread_db_OUT)/*.{o,os,a}