Skip to content
Jannik Vogel edited this page Mar 17, 2020 · 2 revisions

To generate an ISO file that can be burned to a disc, or passed to the XQEMU emulator via the -drive index=1,media=cdrom,file=/path/to/your.iso parameter, define the GEN_XISO variable with the name of the ISO to be created in your project Makefile. For example:

GEN_XISO=$(XBE_TITLE).iso

You can include additional files in the ISO (they must reside in the output directory) like this:

...
ISO_DEPS = $(OUTPUT_DIR)/example.txt
GEN_XISO = $(XBE_TITLE).iso

include $(NXDK_DIR)/Makefile

$(GEN_XISO): $(ISO_DEPS)
$(OUTPUT_DIR)/example.txt:
echo "Hello" > $@

clean: clean_iso_deps
.PHONY: clean_iso_deps
clean_iso_deps:
rm -f $(ISO_DEPS)

For easy ISO generation, you can also just define it when you run make:

make -C samples/hello GEN_XISO=hello.iso