Makefile.in 1.2 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. subdirs += librt
  8. CFLAGS-librt := -DNOT_IN_libc -DIS_IN_librt $(SSP_ALL_CFLAGS)
  9. LDFLAGS-librt.so := $(LDFLAGS) $(call link.asneeded,-lc)
  10. LIBS-librt.so := $(LIBS)
  11. librt_FULL_NAME := librt-$(VERSION).so
  12. librt_DIR := $(top_srcdir)librt
  13. librt_OUT := $(top_builddir)librt
  14. ifeq ($(UCLIBC_HAS_REALTIME),y)
  15. librt_SRC := $(wildcard $(librt_DIR)/*.c)
  16. librt_OBJ := $(patsubst $(librt_DIR)/%.c,$(librt_OUT)/%.o,$(librt_SRC))
  17. ifeq ($(DOPIC),y)
  18. librt-a-y += $(librt_OBJ:.o=.os)
  19. else
  20. librt-a-y += $(librt_OBJ)
  21. endif
  22. librt-so-y += $(librt_OBJ:.o=.os)
  23. lib-a-y += $(top_builddir)lib/librt.a
  24. lib-so-y += $(top_builddir)lib/librt.so
  25. endif
  26. ifeq ($(DOPIC),y)
  27. $(top_builddir)lib/librt.so: $(top_builddir)lib/librt.a $(libc.depend)
  28. else
  29. $(top_builddir)lib/librt.so: $(librt_OUT)/librt_so.a $(libc.depend)
  30. endif
  31. $(call link.so,$(librt_FULL_NAME),$(MAJOR_VERSION))
  32. $(librt_OUT)/librt_so.a: $(librt-so-y)
  33. $(Q)$(RM) $@
  34. $(do_ar)
  35. $(top_builddir)lib/librt.a: $(librt-a-y)
  36. $(Q)$(INSTALL) -d $(dir $@)
  37. $(Q)$(RM) $@
  38. $(do_ar)
  39. objclean-y += librt_clean
  40. librt_clean:
  41. $(do_rm) $(addprefix $(librt_OUT)/*., o os oS a)