Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions cmake/Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
SUBDIRS:= `ls | egrep -v '^(CVS)$$'`
all:
@for i in $(SUBDIRS); do if test -e $$i/CMakeLists.txt ; then (arm-none-eabi-cmake -B $$i/build -S $$i && cmake --build $$i/build) || { exit 1;} fi; done;
clean:
@for i in $(SUBDIRS); do rm -rf $$i/build; done;
5 changes: 5 additions & 0 deletions cmake/arm9/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
cmake_minimum_required(VERSION 3.7)
project(cmake-example LANGUAGES C)

add_executable(cmake-example source/main.c)
nds_create_rom(cmake-example)
20 changes: 20 additions & 0 deletions cmake/arm9/source/main.c
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
/*---------------------------------------------------------------------------------

Basic template code for starting a DS app

---------------------------------------------------------------------------------*/
#include <nds.h>
#include <stdio.h>
//---------------------------------------------------------------------------------
int main(void) {
//---------------------------------------------------------------------------------
consoleDemoInit();
iprintf("Hello World!");
while(1) {
swiWaitForVBlank();
scanKeys();
int pressed = keysDown();
if(pressed & KEY_START) break;
}

}