Makefile 1.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849
  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. top_builddir=../
  8. -include $(top_builddir).config
  9. include Rules.mak
  10. ALL_SUBDIRS := \
  11. args assert crypt ctype pwd_grp signal silly stat stdlib string unistd \
  12. mmap misc
  13. DIRS := $(ALL_SUBDIRS)
  14. ifeq ($(HAVE_SHARED)$(UCLIBC_HAS_THREADS),yy)
  15. ifeq ($(findstring -static,$(LDFLAGS)),)
  16. DIRS += dlopen
  17. endif
  18. endif
  19. ifeq ($(UCLIBC_HAS_THREADS),y)
  20. DIRS += pthread
  21. endif
  22. ifeq ($(UCLIBC_HAS_FULL_RPC),y)
  23. DIRS += rpc
  24. endif
  25. ALL_SUBDIRS += dlopen pthread rpc
  26. ALL_SUBDIRS := $(sort $(ALL_SUBDIRS))
  27. DIRS := $(sort $(DIRS))
  28. test check all: subdirs
  29. tags:
  30. ctags -R
  31. clean: subdirs_clean
  32. subdirs: $(patsubst %, _dir_%, $(DIRS))
  33. subdirs_clean: $(patsubst %, _dirclean_%, $(ALL_SUBDIRS))
  34. $(patsubst %, _dir_%, $(DIRS)) : dummy
  35. $(Q)$(MAKE) -C $(patsubst _dir_%, %, $@)
  36. $(patsubst %, _dirclean_%, $(ALL_SUBDIRS)) : dummy
  37. $(Q)$(MAKE) -C $(patsubst _dirclean_%, %, $@) clean
  38. .PHONY: all check clean dummy subdirs subdirs_clean test