Skip to content

Commit

Permalink
Build 3DS binary with type Release (#20)
Browse files Browse the repository at this point in the history
  • Loading branch information
kremi151 committed Aug 16, 2020
1 parent 4b71396 commit 678c6e2
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 2 deletions.
7 changes: 7 additions & 0 deletions platform-3ds/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,13 @@ set(CMAKE_CXX_STANDARD 17)
set(CMAKE_CXX_STANDARD_REQUIRED ON)
set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${CMAKE_SOURCE_DIR}/../cmake-common)

if(NOT CMAKE_BUILD_TYPE)
message("Setting CMAKE_BUILD_TYPE to Release")
set(CMAKE_BUILD_TYPE "Release" CACHE STRING "Choose the type of build (Release is recommended for best performance)" FORCE)
elseif(NOT "${CMAKE_BUILD_TYPE}" STREQUAL "Release")
message(WARNING "Using CMAKE_BUILD_TYPE=${CMAKE_BUILD_TYPE}, but Release is recommended for best performance during runtime")
endif()

set(SOURCES
source/main.cpp
source/controllers/display_3ds.cpp
Expand Down
7 changes: 5 additions & 2 deletions platform-3ds/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@

This is the implementation of FunkyBoy for the Nintendo 3DS.

This is more like a proof of concept of the porability of FunkyBoy. \
The emulation is currently extremely slow (about ~10 FPS), mainly due to the fact that the code is not optimized enough for the 3DS' limited resources. \
This is more like a proof of concept of the portability of FunkyBoy. \
The emulation is currently quite slow (about ~30 instead of 60 FPS). \
At a later stage of development, I might consider actively working on improving the emulator's performance on the 3DS.

## Build
Expand All @@ -21,6 +21,9 @@ mkdir -p cmake-build && cd cmake-build
cmake .. && make
```

The `CMakeLists.txt` file is configured to compile by default a `Release` binary for best performance during runtime.
Please do not select a manual `CMAKE_BUILD_TYPE` of type `Debug` as that one will slow down emulation even more!

## How to use

This is a very bare bone port of FunkyBoy, there is so far no GUI that allows you to pick ROMs. \
Expand Down

0 comments on commit 678c6e2

Please sign in to comment.