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 := $(patsubst %/Makefile,%,$(wildcard */Makefile))
  11. DIRS := $(ALL_SUBDIRS)
  12. ifneq ($(HAVE_SHARED)$(UCLIBC_HAS_THREADS),yy)
  13. DIRS := $(filter-out dlopen,$(DIRS))
  14. endif
  15. ifneq ($(findstring -static,$(LDFLAGS)),)
  16. DIRS := $(filter-out dlopen,$(DIRS))
  17. endif
  18. ifneq ($(UCLIBC_HAS_THREADS),y)
  19. DIRS := $(filter-out pthread,$(DIRS))
  20. endif
  21. ifneq ($(UCLIBC_HAS_FULL_RPC),y)
  22. DIRS := $(filter-out rpc,$(DIRS))
  23. endif
  24. ifneq ($(UCLIBC_HAS_REGEX),y)
  25. DIRS := $(filter-out regex,$(DIRS))
  26. endif
  27. DIRS := $(filter-out math,$(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