nitrofs with combined template
nitrofs with combined template
ok, so i'm using nitrofs for my game, and i decided to program with the combined template(with an arm9 & arm7 folder). everything compiles fine, but when i start the rom it cannot init nitrofs. how can you get nitrofs working with the combined template?
Re: nitrofs with combined template
why's melw's post deleted, wanted to try it
-
- Site Admin
- Posts: 1986
- Joined: Tue Aug 09, 2005 3:21 am
- Location: UK
- Contact:
Re: nitrofs with combined template
The information was wrong.
Try this instead :-
You'll need to add -lfilesystem -lfat to the LIBS in the arm9 Makefile before -lnds.
Please note: Use of the combined template is generally discouraged, future updates may break your code quite badly. Also: no support is provided for libraries not distributed by devkitPro.
Try this instead :-
Code: Select all
#---------------------------------------------------------------------------------
.SUFFIXES:
#---------------------------------------------------------------------------------
ifeq ($(strip $(DEVKITARM)),)
$(error "Please set DEVKITARM in your environment. export DEVKITARM=<path to>devkitARM")
endif
export TARGET := $(shell basename $(CURDIR))
export TOPDIR := $(CURDIR)
NITRODATA := nitrofiles
#---------------------------------------------------------------------------------
icons := $(wildcard *.bmp)
ifneq (,$(findstring $(TARGET).bmp,$(icons)))
export GAME_ICON := $(CURDIR)/$(TARGET).bmp
else
ifneq (,$(findstring icon.bmp,$(icons)))
export GAME_ICON := $(CURDIR)/icon.bmp
endif
endif
ifneq ($(strip $(NITRODATA)),)
export NITRO_FILES := $(CURDIR)/$(NITRODATA)
endif
include $(DEVKITARM)/ds_rules
.PHONY: $(TARGET).arm7 $(TARGET).arm9
#---------------------------------------------------------------------------------
# main targets
#---------------------------------------------------------------------------------
all: $(TARGET).nds
#---------------------------------------------------------------------------------
$(TARGET).nds : $(TARGET).arm7 $(TARGET).arm9
@ndstool -c $@ -7 $(TARGET).arm7 -9 $(TARGET).arm9 -b $(GAME_ICON) "$(GAME_TITLE);$(GAME_SUBTITLE1);$(GAME_SUBTITLE2)" $(_ADDFILES)
@echo built ... $(notdir $@)
#---------------------------------------------------------------------------------
$(TARGET).arm7 : arm7/$(TARGET).elf
$(TARGET).arm9 : arm9/$(TARGET).elf
#---------------------------------------------------------------------------------
arm7/$(TARGET).elf:
$(MAKE) -C arm7
#---------------------------------------------------------------------------------
arm9/$(TARGET).elf:
$(MAKE) -C arm9
#---------------------------------------------------------------------------------
clean:
$(MAKE) -C arm9 clean
$(MAKE) -C arm7 clean
rm -f $(TARGET).nds $(TARGET).arm7 $(TARGET).arm9
Please note: Use of the combined template is generally discouraged, future updates may break your code quite badly. Also: no support is provided for libraries not distributed by devkitPro.
Re: nitrofs with combined template
ok, i will use libfilesystem:) i used my own nitrofs because i didn't had the loader anymore and couldn't find it. and I need the combined template for nds rom booting. that can't be than on a other way or can it?
edit:
i get an error using this makefile: Makefile 39: ***missing separator
i'm definitely not good in makefiles and can't see what's wrong
edit:
i get an error using this makefile: Makefile 39: ***missing separator
i'm definitely not good in makefiles and can't see what's wrong
Re: nitrofs with combined template
Just use tabs instead of blank spaces in line 39
-
- Site Admin
- Posts: 1986
- Joined: Tue Aug 09, 2005 3:21 am
- Location: UK
- Contact:
Re: nitrofs with combined template
Sorry about that, just did a bit of phpbb hacking so the tabs aren't filtered in code boxes. Should work fine now.
FWIW, if you were planning on putting together a boot menu which loads assets from the nitro filesystem I'm not sure that's likely to be possible unless you have access to the card boot code in order to provide argv. It's probably better to keep assets in a root subdirectory to allow themes/user skinning anyway.
FWIW, if you were planning on putting together a boot menu which loads assets from the nitro filesystem I'm not sure that's likely to be possible unless you have access to the card boot code in order to provide argv. It's probably better to keep assets in a root subdirectory to allow themes/user skinning anyway.
Re: nitrofs with combined template
Ok, but it's a game and i put the game data in nitrofs, and the bootloader is for "soft-reset" so it doesn't load roms uot of nitrofs.
and what are the advantages of libfilesystem? i don't know the difference between nitrofs and libfilesystem
and what are the advantages of libfilesystem? i don't know the difference between nitrofs and libfilesystem
Re: nitrofs with combined template
As I understand it, libfilesystem is a slightly modified/cleaned up version of nitroFS. One of the main differences, is that the method the original nitroFS used to locate the .nds filename (you having to provide it in your code) was not implemented because the method is disliked and issue prone (renaming the rom or putting it anywhere but the root causes obvious problems).
libfilesystem requires a loader that can use the argv parameter, and most slot 1 cards loaders don't. Wintermute posted a loader that works on slot 1 cards, but I have not have any luck with it and my R4... (it's not a fake one...).
libfilesystem requires a loader that can use the argv parameter, and most slot 1 cards loaders don't. Wintermute posted a loader that works on slot 1 cards, but I have not have any luck with it and my R4... (it's not a fake one...).
Who is online
Users browsing this forum: ds-sloth and 1 guest