Makefile.in 1.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  1. # Makefile for uClibc
  2. #
  3. # Copyright (C) 2000-2008 Erik Andersen <andersen@uclibc.org>
  4. #
  5. # Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
  6. #
  7. CFLAGS-libresolv := -DNOT_IN_libc -DIS_IN_libresolv $(SSP_ALL_CFLAGS)
  8. LDFLAGS-libresolv.so := $(LDFLAGS)
  9. ifdef ASNEEDED
  10. ifeq ($(UCLIBC_HAS_SSP),y)
  11. LDFLAGS-libresolv.so += -Wl,--no-as-needed -lc -Wl,--as-needed
  12. endif
  13. endif
  14. LIBS-libresolv.so := $(LIBS)
  15. libresolv_FULL_NAME := libresolv-$(VERSION).so
  16. libresolv_DIR := $(top_srcdir)libresolv
  17. libresolv_OUT := $(top_builddir)libresolv
  18. libresolv_SRC := $(libresolv_DIR)/resolv.c
  19. libresolv_OBJ := $(patsubst $(libresolv_DIR)/%.c,$(libresolv_OUT)/%.o,$(libresolv_SRC))
  20. ifeq ($(DOPIC),y)
  21. libresolv-a-y := $(libresolv_OBJ:.o=.os)
  22. else
  23. libresolv-a-y := $(libresolv_OBJ)
  24. endif
  25. libresolv-so-y := $(libresolv_OBJ:.o=.os)
  26. lib-a-y += $(top_builddir)lib/libresolv.a
  27. lib-so-y += $(top_builddir)lib/libresolv.so
  28. objclean-y += libresolv_clean
  29. ifeq ($(DOPIC),y)
  30. $(top_builddir)lib/libresolv.so: $(top_builddir)lib/libresolv.a $(libc.depend)
  31. else
  32. $(top_builddir)lib/libresolv.so: $(libresolv_OUT)/libresolv_so.a $(libc.depend)
  33. endif
  34. $(call link.so,$(libresolv_FULL_NAME),$(MAJOR_VERSION))
  35. $(libresolv_OUT)/libresolv_so.a: $(libresolv-so-y)
  36. $(Q)$(RM) $@
  37. $(do_ar)
  38. $(top_builddir)lib/libresolv.a: $(libresolv-a-y)
  39. $(Q)$(INSTALL) -d $(dir $@)
  40. $(Q)$(RM) $@
  41. $(do_ar)
  42. libresolv_clean:
  43. $(do_rm) $(addprefix $(libresolv_OUT)/*., o os a)