Relocate docs for Switch
This commit is contained in:
parent
14ebe3e4cf
commit
ed18079e8a
2 changed files with 25 additions and 10 deletions
12
changelog.md
12
changelog.md
|
|
@ -170,15 +170,7 @@
|
||||||
- ``experimental`` is now a pragma / command line switch that can enable specific
|
- ``experimental`` is now a pragma / command line switch that can enable specific
|
||||||
language extensions, it is not an all-or-nothing switch anymore.
|
language extensions, it is not an all-or-nothing switch anymore.
|
||||||
|
|
||||||
- Nintendo Switch was added as a new platform target. Simply add --os:nintendoswitch
|
- Nintendo Switch was added as a new platform target. See [the compiler user guide](https://nim-lang.org/docs/nimc.html)
|
||||||
to your usual ``nim c`` or ``nim cpp`` command. DevkitPro setup must be the same as
|
for more info.
|
||||||
what is the default with their new installer
|
|
||||||
[here for Mac/Linux](https://github.com/devkitPro/pacman/releases) or
|
|
||||||
[here for Windows](https://github.com/devkitPro/installer/releases).
|
|
||||||
Environment variables are ``DEVKITPRO`` for the devkitpro path, ``SWITCH_LIBS`` for any extra
|
|
||||||
libraries required by your application (``-lLIBNAME`` or ``-LLIBPATH``), and
|
|
||||||
``SWITCH_INCLUDES`` for any extra include files (``-IINCLUDE_PATH``).
|
|
||||||
There are some directories expected to exist in a specific structure for now until I figure out a better way to specify them. They are: ``DEVKITPRO/portlibs/switch/lib``, ``DEVKITPRO/libnx/lib``,
|
|
||||||
``DEVKITPRO/portlibs/switch/include``, and ``DEVKITPRO/libnx/include``
|
|
||||||
|
|
||||||
### Bugfixes
|
### Bugfixes
|
||||||
|
|
|
||||||
23
doc/nimc.rst
23
doc/nimc.rst
|
|
@ -228,6 +228,29 @@ configuration file should contain something like::
|
||||||
arm.linux.gcc.exe = "arm-linux-gcc"
|
arm.linux.gcc.exe = "arm-linux-gcc"
|
||||||
arm.linux.gcc.linkerexe = "arm-linux-gcc"
|
arm.linux.gcc.linkerexe = "arm-linux-gcc"
|
||||||
|
|
||||||
|
Cross compilation for Nintendo Switch
|
||||||
|
=====================================
|
||||||
|
|
||||||
|
Simply add --os:nintendoswitch
|
||||||
|
to your usual ``nim c`` or ``nim cpp`` command. DevkitPro setup must be the same as
|
||||||
|
what is the default with their new installer
|
||||||
|
[here for Mac/Linux](https://github.com/devkitPro/pacman/releases) or
|
||||||
|
[here for Windows](https://github.com/devkitPro/installer/releases).
|
||||||
|
|
||||||
|
For example::
|
||||||
|
|
||||||
|
nim c --os:nintendoswitch switchhomebrew.nim
|
||||||
|
|
||||||
|
This will generate a file called ``switchhomebrew.elf`` which can then be turned into
|
||||||
|
an nro file with the ``elf2nro`` tool in the DevkitPro release. Examples can be found at
|
||||||
|
[the nim-libnx github repo](https://github.com/jyapayne/nim-libnx.git).
|
||||||
|
|
||||||
|
Environment variables are ``DEVKITPRO`` for the devkitpro path, ``SWITCH_LIBS`` for any extra
|
||||||
|
libraries required by your application (``-lLIBNAME`` or ``-LLIBPATH``), and
|
||||||
|
``SWITCH_INCLUDES`` for any extra include files (``-IINCLUDE_PATH``).
|
||||||
|
|
||||||
|
There are some directories expected to exist in a specific structure for now until I figure out a better way to specify them. They are: ``DEVKITPRO/portlibs/switch/lib``, ``DEVKITPRO/libnx/lib``,
|
||||||
|
``DEVKITPRO/portlibs/switch/include``, and ``DEVKITPRO/libnx/include``.
|
||||||
|
|
||||||
DLL generation
|
DLL generation
|
||||||
==============
|
==============
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue