#
# Generated By: dol2asm
#

M581_TARGET := $(BUILD_DIR)/rel/d/a/obj/d_a_obj_nan.plf
M581_LDSCRIPT := $(BUILD_DIR)/rel/d/a/obj/d_a_obj_nan.lcf
M581_MAP := $(BUILD_DIR)/rel/d/a/obj/d_a_obj_nan.map

M581_CPP_FILES := \
	rel/executor.cpp \
	rel/global_destructor_chain.cpp \
	rel/d/a/obj/d_a_obj_nan/d_a_obj_nan.cpp \

M581_O_FILES := \
	$(BUILD_DIR)/rel/executor.o \
	$(BUILD_DIR)/rel/global_destructor_chain.o \
	$(BUILD_DIR)/rel/d/a/obj/d_a_obj_nan/d_a_obj_nan.o \

M581_LIBS := \

M581_CFLAGS := \
	-sdata 0 \
	-sdata2 0 \

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

$(M581_TARGET): $(M581_O_FILES) $(M581_LIBS)
	@echo [581] creating $(M581_TARGET)
	@echo $(M581_LIBS) $(M581_O_FILES) > build/M581_ofiles
	@python3 tools/lcf.py rel 581 --output $(M581_LDSCRIPT)
	@$(LD) -opt_partial -strip_partial $(M581_LDFLAGS) -o $(M581_TARGET) @build/M581_ofiles

$(BUILD_DIR)/rel/d/a/obj/d_a_obj_nan/%.o: rel/d/a/obj/d_a_obj_nan/%.cpp $(BUILD_DIR)/rel/d/a/obj/d_a_obj_nan/%.d
	@echo [581] building $@
	@mkdir -p $(@D)
	@$(ICONV) -f UTF-8 -t CP932 < $< > $(basename $@).cpp
	@$(CC) $(CFLAGS) $(M581_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
M581_D_FILES := $(M581_O_FILES:.o=.d)
$(M581_D_FILES):
include $(wildcard $(M581_D_FILES))
endif


