libnx

A port of libnx to Nim

Pure Nim score 15/100 · tests present · no docs generated

Summary

Latest Version Unknown
License Unlicense
CI Status Failing
Downloads 0
Last Indexed 2026-07-21 05:23

Installation

nimble install libnx
choosenim install libnx
git clone https://github.com/jyapayne/nim-libnx

OS Compatibility

Platform Linux macOS Windows FreeBSD OpenBSD NetBSD Android iOS WASM Embedded
libnx - - - - - - -

Source

Repository https://github.com/jyapayne/nim-libnx
Homepage https://github.com/jyapayne/nim-libnx
Registry Source nimble_official

README

nim-libnx

Libnx ported to the Nim programming language. You will need a Nim compiler with Nintendo switch support which can be found in the latest devel branch of the Nim compiler.

You also must have DevkitPro and switch (libnx) libraries for Mac and Linux or Windows installed.

From dkp-pacman, the switch libraries can be installed with:

dkp-pacman -Syu
dkp-pacman -S switch-dev
## When it asks for installation options, choose the default which will install everything

The DEVKITPRO environment variable must also exist and point to a directory with the following structure:

  • DEVKITPRO/libnx/lib
  • DEVKITPRO/libnx/include

OR you must specify a valid libnx path and/or devkitpro path to the switch_build utility:

switch_build --libnxPath:"C:\devkitPro\libnx" --author:"Joey" --version:"1.0.0" .\examples\accounts\account_ex.nim
# OR
switch_build --devkitProPath:"C:\devkitPro" --author:"Joey" --version:"1.0.0" .\examples\accounts\account_ex.nim

Install

Simply run

# Because of a bug in nimble right now, you must install this first!
nimble install nimgen@#head
nimble install

To compile examples:

nimble buildExamples

PRs are welcome for porting other examples or any other changes!