#
# Generated By: dol2asm
#

M335_TARGET := $(BUILD_DIR)/rel/d/a/npc/d_a_npc_midp.plf
M335_LDSCRIPT := $(BUILD_DIR)/rel/d/a/npc/d_a_npc_midp.lcf
M335_MAP := $(BUILD_DIR)/rel/d/a/npc/d_a_npc_midp.map

M335_CPP_FILES := \
	rel/executor.cpp \
	rel/global_destructor_chain.cpp \
	rel/d/a/npc/d_a_npc_midp/d_a_npc_midp.cpp \

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

M335_LIBS := \

M335_CFLAGS := \
	-sdata 0 \
	-sdata2 0 \

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

$(M335_TARGET): $(M335_O_FILES) $(M335_LIBS)
	@echo [335] creating $(M335_TARGET)
	@echo $(M335_LIBS) $(M335_O_FILES) > build/M335_ofiles
	@python3 tools/lcf.py rel 335 --output $(M335_LDSCRIPT)
	@$(LD) -opt_partial -strip_partial $(M335_LDFLAGS) -o $(M335_TARGET) @build/M335_ofiles

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


