#
# Generated By: dol2asm
#

M330_TARGET := $(BUILD_DIR)/rel/d/a/npc/d_a_npc_ks.plf
M330_LDSCRIPT := $(BUILD_DIR)/rel/d/a/npc/d_a_npc_ks.lcf
M330_MAP := $(BUILD_DIR)/rel/d/a/npc/d_a_npc_ks.map

M330_CPP_FILES := \
	rel/executor.cpp \
	rel/global_destructor_chain.cpp \
	rel/d/a/npc/d_a_npc_ks/d_a_npc_ks.cpp \

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

M330_LIBS := \

M330_CFLAGS := \
	-sdata 0 \
	-sdata2 0 \

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

$(M330_TARGET): $(M330_O_FILES) $(M330_LIBS)
	@echo [330] creating $(M330_TARGET)
	@echo $(M330_LIBS) $(M330_O_FILES) > build/M330_ofiles
	@python3 tools/lcf.py rel 330 --output $(M330_LDSCRIPT)
	@$(LD) -opt_partial -strip_partial $(M330_LDFLAGS) -o $(M330_TARGET) @build/M330_ofiles

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


