19 lines
370 B
Makefile
19 lines
370 B
Makefile
define GRABSRC
|
|
$(foreach item, $(1), $(wildcard $(item)/*.c) $(wildcard $(item)/*.S) $(wildcard $(item)/*.s))
|
|
endef
|
|
|
|
define GET_CFILES
|
|
$(filter %.c,$(1))
|
|
endef
|
|
|
|
define GET_ASFILES
|
|
$(filter %.S,$(1)) $(filter %.s,$(1))
|
|
endef
|
|
|
|
define GET_OBJ
|
|
$(patsubst %.c,%.o,$(filter %.c,$(1))) \
|
|
$(patsubst %.S,%.o,$(filter %.S,$(1))) \
|
|
$(patsubst %.s,%.o,$(filter %.s,$(1)))
|
|
endef
|
|
|