2020-06-15 14:18:57 +00:00
|
|
|
#-*-mode:makefile-gmake;indent-tabs-mode:t;tab-width:8;coding:utf-8-*-┐
|
|
|
|
#───vi: set et ft=make ts=8 tw=8 fenc=utf-8 :vi───────────────────────┘
|
|
|
|
|
|
|
|
PKGS += TOOL_BUILD_LIB
|
|
|
|
|
|
|
|
TOOL_BUILD_LIB_ARTIFACTS += TOOL_BUILD_LIB_A
|
|
|
|
TOOL_BUILD_LIB = $(TOOL_BUILD_LIB_A_DEPS) $(TOOL_BUILD_LIB_A)
|
|
|
|
TOOL_BUILD_LIB_A = o/$(MODE)/tool/build/lib/buildlib.a
|
|
|
|
TOOL_BUILD_LIB_A_FILES := $(wildcard tool/build/lib/*)
|
|
|
|
TOOL_BUILD_LIB_A_HDRS = $(filter %.h,$(TOOL_BUILD_LIB_A_FILES))
|
|
|
|
TOOL_BUILD_LIB_A_SRCS_S = $(filter %.S,$(TOOL_BUILD_LIB_A_FILES))
|
|
|
|
TOOL_BUILD_LIB_A_SRCS_C = $(filter %.c,$(TOOL_BUILD_LIB_A_FILES))
|
2020-08-25 11:23:25 +00:00
|
|
|
|
|
|
|
TOOL_BUILD_LIB_A_CHECKS = \
|
|
|
|
$(TOOL_BUILD_LIB_A_HDRS:%=o/$(MODE)/%.ok) \
|
|
|
|
$(TOOL_BUILD_LIB_A).pkg
|
2020-06-15 14:18:57 +00:00
|
|
|
|
|
|
|
TOOL_BUILD_LIB_A_SRCS = \
|
|
|
|
$(TOOL_BUILD_LIB_A_SRCS_S) \
|
|
|
|
$(TOOL_BUILD_LIB_A_SRCS_C)
|
|
|
|
|
|
|
|
TOOL_BUILD_LIB_A_OBJS = \
|
|
|
|
$(TOOL_BUILD_LIB_A_SRCS:%=o/$(MODE)/%.zip.o) \
|
|
|
|
$(TOOL_BUILD_LIB_A_SRCS_S:%.S=o/$(MODE)/%.o) \
|
|
|
|
$(TOOL_BUILD_LIB_A_SRCS_C:%.c=o/$(MODE)/%.o)
|
|
|
|
|
|
|
|
TOOL_BUILD_LIB_A_DIRECTDEPS = \
|
2020-08-27 06:08:08 +00:00
|
|
|
DSP_TTY \
|
2020-08-25 11:23:25 +00:00
|
|
|
LIBC_ALG \
|
|
|
|
LIBC_BITS \
|
|
|
|
LIBC_CONV \
|
2020-06-15 14:18:57 +00:00
|
|
|
LIBC_CALLS \
|
|
|
|
LIBC_CALLS_HEFTY \
|
2020-08-25 11:23:25 +00:00
|
|
|
LIBC_ELF \
|
2020-06-15 14:18:57 +00:00
|
|
|
LIBC_FMT \
|
|
|
|
LIBC_MEM \
|
|
|
|
LIBC_NEXGEN32E \
|
|
|
|
LIBC_RUNTIME \
|
|
|
|
LIBC_STUBS \
|
2020-08-25 11:23:25 +00:00
|
|
|
LIBC_INTRIN \
|
2020-06-15 14:18:57 +00:00
|
|
|
LIBC_SYSV \
|
|
|
|
LIBC_SYSV_CALLS \
|
2020-08-25 11:23:25 +00:00
|
|
|
LIBC_TIME \
|
2020-06-15 14:18:57 +00:00
|
|
|
LIBC_LOG \
|
2020-08-25 11:23:25 +00:00
|
|
|
LIBC_STR \
|
|
|
|
LIBC_SOCK \
|
|
|
|
LIBC_UNICODE \
|
|
|
|
LIBC_STDIO \
|
|
|
|
LIBC_X \
|
|
|
|
LIBC_TINYMATH \
|
|
|
|
THIRD_PARTY_COMPILER_RT \
|
|
|
|
THIRD_PARTY_XED
|
2020-06-15 14:18:57 +00:00
|
|
|
|
|
|
|
TOOL_BUILD_LIB_A_DEPS := \
|
|
|
|
$(call uniq,$(foreach x,$(TOOL_BUILD_LIB_A_DIRECTDEPS),$($(x))))
|
|
|
|
|
|
|
|
$(TOOL_BUILD_LIB_A): \
|
|
|
|
tool/build/lib/ \
|
|
|
|
$(TOOL_BUILD_LIB_A).pkg \
|
|
|
|
$(TOOL_BUILD_LIB_A_OBJS)
|
|
|
|
|
|
|
|
$(TOOL_BUILD_LIB_A).pkg: \
|
|
|
|
$(TOOL_BUILD_LIB_A_OBJS) \
|
|
|
|
$(foreach x,$(TOOL_BUILD_LIB_A_DIRECTDEPS),$($(x)_A).pkg)
|
|
|
|
|
2020-08-31 12:17:31 +00:00
|
|
|
o/$(MODE)/tool/build/lib/fpu.o: OVERRIDE_CFLAGS += -ffast-math
|
|
|
|
|
2020-06-15 14:18:57 +00:00
|
|
|
TOOL_BUILD_LIB_LIBS = $(foreach x,$(TOOL_BUILD_LIB_ARTIFACTS),$($(x)))
|
|
|
|
TOOL_BUILD_LIB_SRCS = $(foreach x,$(TOOL_BUILD_LIB_ARTIFACTS),$($(x)_SRCS))
|
|
|
|
TOOL_BUILD_LIB_HDRS = $(foreach x,$(TOOL_BUILD_LIB_ARTIFACTS),$($(x)_HDRS))
|
|
|
|
TOOL_BUILD_LIB_BINS = $(foreach x,$(TOOL_BUILD_LIB_ARTIFACTS),$($(x)_BINS))
|
|
|
|
TOOL_BUILD_LIB_CHECKS = $(foreach x,$(TOOL_BUILD_LIB_ARTIFACTS),$($(x)_CHECKS))
|
|
|
|
TOOL_BUILD_LIB_OBJS = $(foreach x,$(TOOL_BUILD_LIB_ARTIFACTS),$($(x)_OBJS))
|
|
|
|
TOOL_BUILD_LIB_TESTS = $(foreach x,$(TOOL_BUILD_LIB_ARTIFACTS),$($(x)_TESTS))
|
|
|
|
|
|
|
|
.PHONY: o/$(MODE)/tool/build/lib
|
|
|
|
o/$(MODE)/tool/build/lib: $(TOOL_BUILD_LIB_CHECKS)
|