X-Git-Url: https://scm.lunaixsky.com/lunaix-os.git/blobdiff_plain/8efc0cf32160c68772a2ce1887e6a397852d3d96..6f6da1abb22dff69dbb710bd2fd9d95f083f2b43:/lunaix-os/usr/stat/makefile?ds=sidebyside diff --git a/lunaix-os/usr/stat/makefile b/lunaix-os/usr/stat/makefile new file mode 100644 index 0000000..33802bd --- /dev/null +++ b/lunaix-os/usr/stat/makefile @@ -0,0 +1,21 @@ +define src_files + main.c +endef + +obj_files := $(addsuffix .o,$(src_files)) +include_opt := $(addprefix -I,$(INCLUDES)) + +out := $(BUILD_DIR)/bin + +%.c.o: %.c + $(call status_,CC,$<) + @$(CC) $(CFLAGS) $(include_opt) -c $< -o $@ + +$(out)/$(BUILD_NAME): $(obj_files) + $(call status_,LD,$(@F)) + @$(CC) -T $(LD_SCRIPT) -o $@ $< $(LIBC) $(LDFLAGS) + +all: $(out)/$(BUILD_NAME) + +clean: + @rm -f $(obj_files) \ No newline at end of file