#
# Generated By: dol2asm
#

M291_TARGET := $(BUILD_DIR)/rel/d/a/npc/d_a_npc_chat.plf
M291_LDSCRIPT := $(BUILD_DIR)/rel/d/a/npc/d_a_npc_chat.lcf
M291_MAP := $(BUILD_DIR)/rel/d/a/npc/d_a_npc_chat.map

M291_CPP_FILES := \
	rel/executor.cpp \
	rel/global_destructor_chain.cpp \
	rel/d/a/npc/d_a_npc_chat/d_a_npc_chat.cpp \

M291_O_FILES := \
	$(BUILD_DIR)/rel/executor.o \
	$(BUILD_DIR)/rel/global_destructor_chain.o \
	$(BUILD_DIR)/rel/d/a/npc/d_a_npc_chat/d_a_npc_chat.o \

M291_LIBS := \

M291_CFLAGS := \
	-sdata 0 \
	-sdata2 0 \

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

$(M291_TARGET): $(M291_O_FILES) $(M291_LIBS)
	@echo [291] creating $(M291_TARGET)
	@echo $(M291_LIBS) $(M291_O_FILES) > build/M291_ofiles
	@python3 tools/lcf.py rel 291 --output $(M291_LDSCRIPT)
	@$(LD) -opt_partial -strip_partial $(M291_LDFLAGS) -o $(M291_TARGET) @build/M291_ofiles

$(BUILD_DIR)/rel/d/a/npc/d_a_npc_chat/%.o: rel/d/a/npc/d_a_npc_chat/%.cpp $(BUILD_DIR)/rel/d/a/npc/d_a_npc_chat/%.d
	@echo [291] building $@
	@mkdir -p $(@D)
	@$(ICONV) -f UTF-8 -t CP932 < $< > $(basename $@).cpp
	@$(CC) $(CFLAGS) $(M291_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
M291_D_FILES := $(M291_O_FILES:.o=.d)
$(M291_D_FILES):
include $(wildcard $(M291_D_FILES))
endif


