Makefile 1.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  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. DIRS := $(filter-out math,$(DIRS))
  25. test check all: subdirs
  26. tags:
  27. ctags -R
  28. clean: subdirs_clean
  29. subdirs: $(patsubst %, _dir_%, $(DIRS))
  30. subdirs_clean: $(patsubst %, _dirclean_%, $(ALL_SUBDIRS))
  31. $(patsubst %, _dir_%, $(DIRS)) : dummy
  32. $(Q)$(MAKE) -C $(patsubst _dir_%, %, $@)
  33. $(patsubst %, _dirclean_%, $(ALL_SUBDIRS)) : dummy
  34. $(Q)$(MAKE) -C $(patsubst _dirclean_%, %, $@) clean
  35. .PHONY: all check clean dummy subdirs subdirs_clean test