From 08647f7d5c6fa6240c666822dae93217df2a3297 Mon Sep 17 00:00:00 2001 From: mintsuki Date: Thu, 16 Mar 2023 01:23:11 +0100 Subject: [PATCH] decompressor: Move tinf directory to decompressor directory --- decompressor/GNUmakefile | 20 +++----------------- {tinf => decompressor/tinf}/tinf.h | 0 {tinf => decompressor/tinf}/tinfgzip.c | 0 {tinf => decompressor/tinf}/tinflate.c | 0 4 files changed, 3 insertions(+), 17 deletions(-) rename {tinf => decompressor/tinf}/tinf.h (100%) rename {tinf => decompressor/tinf}/tinfgzip.c (100%) rename {tinf => decompressor/tinf}/tinflate.c (100%) diff --git a/decompressor/GNUmakefile b/decompressor/GNUmakefile index fd23aad6..c1669c0d 100644 --- a/decompressor/GNUmakefile +++ b/decompressor/GNUmakefile @@ -35,7 +35,7 @@ override FREESTANDING_CFLAGS += \ override FREESTANDING_CPPFLAGS := \ -I../freestanding-headers \ - -I'$(call SHESCAPE,$(BUILDDIR))/tinf' \ + -I./tinf \ -I. \ $(FREESTANDING_CPPFLAGS) \ -MMD @@ -59,27 +59,13 @@ override HEADER_DEPS := $(addprefix $(call MKESCAPE,$(BUILDDIR))/, $(C_FILES:.c= .PHONY: all all: $(call MKESCAPE,$(BUILDDIR))/decompressor.bin -$(call MKESCAPE,$(BUILDDIR))/decompressor.bin: $(OBJ) ../libgcc-binaries/libgcc-i686.a $(call MKESCAPE,$(BUILDDIR))/tinf/tinfgzip.o $(call MKESCAPE,$(BUILDDIR))/tinf/tinflate.o +$(call MKESCAPE,$(BUILDDIR))/decompressor.bin: $(OBJ) ../libgcc-binaries/libgcc-i686.a $(FREESTANDING_LD) '$(call OBJESCAPE,$^)' $(FREESTANDING_LDFLAGS) -o '$(call SHESCAPE,$(BUILDDIR))/decompressor.elf' $(FREESTANDING_OBJCOPY) -O binary '$(call SHESCAPE,$(BUILDDIR))/decompressor.elf' '$(call SHESCAPE,$@)' -$(call MKESCAPE,$(BUILDDIR))/tinf-copied: ../tinf/* - rm -rf '$(call SHESCAPE,$(BUILDDIR))/tinf' - $(MKDIR_P) '$(call SHESCAPE,$(BUILDDIR))' - cp -r ../tinf '$(call SHESCAPE,$(BUILDDIR))/' - touch '$(call SHESCAPE,$(BUILDDIR))/tinf-copied' - -$(call MKESCAPE,$(BUILDDIR))/tinf/tinfgzip.o: $(call MKESCAPE,$(BUILDDIR))/tinf-copied - $(MKDIR_P) "$$(dirname '$(call SHESCAPE,$@)')" - $(FREESTANDING_CC) $(FREESTANDING_CFLAGS) $(FREESTANDING_CPPFLAGS) -c '$(call SHESCAPE,$(@:.o=.c))' -o '$(call SHESCAPE,$@)' - -$(call MKESCAPE,$(BUILDDIR))/tinf/tinflate.o: $(call MKESCAPE,$(BUILDDIR))/tinf-copied - $(MKDIR_P) "$$(dirname '$(call SHESCAPE,$@)')" - $(FREESTANDING_CC) $(FREESTANDING_CFLAGS) $(FREESTANDING_CPPFLAGS) -c '$(call SHESCAPE,$(@:.o=.c))' -o '$(call SHESCAPE,$@)' - -include $(HEADER_DEPS) -$(call MKESCAPE,$(BUILDDIR))/%.o: %.c $(call MKESCAPE,$(BUILDDIR))/tinf-copied +$(call MKESCAPE,$(BUILDDIR))/%.o: %.c $(MKDIR_P) "$$(dirname '$(call SHESCAPE,$@)')" $(FREESTANDING_CC) $(FREESTANDING_CFLAGS) $(FREESTANDING_CPPFLAGS) -c '$(call SHESCAPE,$<)' -o '$(call SHESCAPE,$@)' diff --git a/tinf/tinf.h b/decompressor/tinf/tinf.h similarity index 100% rename from tinf/tinf.h rename to decompressor/tinf/tinf.h diff --git a/tinf/tinfgzip.c b/decompressor/tinf/tinfgzip.c similarity index 100% rename from tinf/tinfgzip.c rename to decompressor/tinf/tinfgzip.c diff --git a/tinf/tinflate.c b/decompressor/tinf/tinflate.c similarity index 100% rename from tinf/tinflate.c rename to decompressor/tinf/tinflate.c