#
# Generated By: dol2asm
#

M147_TARGET := $(BUILD_DIR)/rel/d/a/b/d_a_b_gos.plf
M147_LDSCRIPT := $(BUILD_DIR)/rel/d/a/b/d_a_b_gos.lcf
M147_MAP := $(BUILD_DIR)/rel/d/a/b/d_a_b_gos.map

M147_CPP_FILES := \
	rel/executor.cpp \
	rel/global_destructor_chain.cpp \
	rel/d/a/b/d_a_b_gos/d_a_b_gos.cpp \

M147_O_FILES := \
	$(BUILD_DIR)/rel/executor.o \
	$(BUILD_DIR)/rel/global_destructor_chain.o \
	$(BUILD_DIR)/rel/d/a/b/d_a_b_gos/d_a_b_gos.o \

M147_LIBS := \

M147_CFLAGS := \
	-sdata 0 \
	-sdata2 0 \

M147_LDFLAGS := \
	-nodefaults \
	-fp hard \
	-proc gekko \
	-linkmode moreram \
	-sdata 0 \
	-sdata2 0 \
	-m _prolog \
	-lcf $(M147_LDSCRIPT) \
	-unused -map $(M147_MAP) \
	-w off \

$(M147_TARGET): $(M147_O_FILES) $(M147_LIBS)
	@echo [147] creating $(M147_TARGET)
	@echo $(M147_LIBS) $(M147_O_FILES) > build/M147_ofiles
	@python3 tools/lcf.py rel 147 --output $(M147_LDSCRIPT)
	@$(LD) -opt_partial -strip_partial $(M147_LDFLAGS) -o $(M147_TARGET) @build/M147_ofiles

$(BUILD_DIR)/rel/d/a/b/d_a_b_gos/%.o: rel/d/a/b/d_a_b_gos/%.cpp $(BUILD_DIR)/rel/d/a/b/d_a_b_gos/%.d
	@echo [147] building $@
	@mkdir -p $(@D)
	@$(ICONV) -f UTF-8 -t CP932 < $< > $(basename $@).cpp
	@$(CC) $(CFLAGS) $(M147_CFLAGS) $(DEPFLAGS) -c -o $(dir $@) $(basename $@).cpp
	@if [ -z '$(DISABLE_DEPS)' ]; then tools/transform-dep.py '$(basename $@).d' '$(basename $@).d'; touch -c $@; fi

ifndef DISABLE_DEPS
M147_D_FILES := $(M147_O_FILES:.o=.d)
$(M147_D_FILES):
include $(wildcard $(M147_D_FILES))
endif


