Makefile.in 1.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. # Makefile for uClibc
  2. #
  3. # Copyright (C) 2000-2006 Erik Andersen <andersen@uclibc.org>
  4. #
  5. # Licensed under the LGPL v2.1, see the file COPYING.LIB in this tarball.
  6. #
  7. COMMON_DIR := $(top_srcdir)libc/sysdeps/linux/common
  8. COMMON_OUT := $(top_builddir)libc/sysdeps/linux/common
  9. CSRC := $(notdir $(wildcard $(COMMON_DIR)/*.c))
  10. ifeq ($(EXCLUDE_BRK),y)
  11. CSRC := $(filter-out sbrk.c,$(CSRC))
  12. endif
  13. ifneq ($(UCLIBC_HAS_LFS),y)
  14. CSRC_LFS := $(notdir $(wildcard $(COMMON_DIR)/*64.c))
  15. CSRC := $(filter-out llseek.c $(CSRC_LFS),$(CSRC))
  16. endif
  17. CSRC := $(filter-out ssp-local.c,$(CSRC))
  18. ifneq ($(UCLIBC_HAS_SSP),y)
  19. CSRC := $(filter-out ssp.c,$(CSRC))
  20. endif
  21. # fails for some reason
  22. ifneq ($(strip $(ARCH_OBJS)),)
  23. CSRC := $(filter-out $(notdir $(ARCH_OBJS:.o=.c)),$(CSRC))
  24. endif
  25. CFLAGS-ssp.c := $(SSP_DISABLE_FLAGS)
  26. CFLAGS-ssp-local.c := $(SSP_DISABLE_FLAGS)
  27. COMMON_SRC := $(patsubst %.c,$(COMMON_DIR)/%.c,$(CSRC))
  28. COMMON_OBJ := $(patsubst %.c,$(COMMON_OUT)/%.o,$(CSRC))
  29. libc-y += $(COMMON_OBJ)
  30. libc-static-$(UCLIBC_HAS_SSP) += $(COMMON_OUT)/ssp-local.o
  31. libc-nonshared-$(UCLIBC_HAS_SSP) += $(COMMON_OUT)/ssp-local.os
  32. libc-nomulti-y += $(COMMON_OUT)/__syscall_rt_sigaction.o $(COMMON_OUT)/__syscall_sigaction.o
  33. libc-nomulti-$(UCLIBC_HAS_SSP) += $(COMMON_OUT)/ssp.o
  34. objclean-y += common_objclean
  35. common_objclean:
  36. $(RM) $(COMMON_OUT)/*.{o,os,oS}