Does devkitpro/libnx contain a proper implementation of the C standard library, or does it act as a replacement?

noneuclideanmotion

Member
OP
Newcomer
Joined
Nov 1, 2022
Messages
13
Trophies
0
Age
21
XP
52
Country
United Kingdom
By which what I mean will functions like fopen, syscall, etc work? I know libnx provides its own functions to do most things, but does it implement them inside the standard library too?

I was asking because I'm in the middle of implementing a switch helper library for c++ (mainly because as a c++ programmer the design and use libnx is semi-alien to me). Doing that would be much much easier with a c++ standard library implementation for the switch. Since the C++ std library builds from the C one then: if libnx implements it I can build my c++ std lib from that, if not I would make a cstdlib as well since it wouldn't take too much extra effort, and I imagine people would appreciate one.
 
  • Like
Reactions: binkinator

binkinator

Garfield’s Fitness Coach
Member
GBAtemp Patron
Joined
Mar 29, 2021
Messages
6,512
Trophies
2
XP
5,962
Country
United States
By which what I mean will functions like fopen, syscall, etc work? I know libnx provides its own functions to do most things, but does it implement them inside the standard library too?

I was asking because I'm in the middle of implementing a switch helper library for c++ (mainly because as a c++ programmer the design and use libnx is semi-alien to me). Doing that would be much much easier with a c++ standard library implementation for the switch. Since the C++ std library builds from the C one then: if libnx implements it I can build my c++ std lib from that, if not I would make a cstdlib as well since it wouldn't take too much extra effort, and I imagine people would appreciate one.
you would likely get more traction in talking directly to the Devs on Discord. It will be tough conversations for sure but you will get a ton more feedback.
 
  • Like
Reactions: impeeza

masagrator

The patches guy
Member
Joined
Oct 14, 2018
Messages
5,731
Trophies
3
XP
10,708
Country
Poland
By which what I mean will functions like fopen, syscall, etc work? I know libnx provides its own functions to do most things, but does it implement them inside the standard library too?

I was asking because I'm in the middle of implementing a switch helper library for c++ (mainly because as a c++ programmer the design and use libnx is semi-alien to me). Doing that would be much much easier with a c++ standard library implementation for the switch. Since the C++ std library builds from the C one then: if libnx implements it I can build my c++ std lib from that, if not I would make a cstdlib as well since it wouldn't take too much extra effort, and I imagine people would appreciate one.
libc is a part of devkitA64 from devkitpro which is used to compile homebrew for Switch.

libc functions are not a part of libnx and libnx is not a part of devkitA64. Answering second question here.
 
  • Like
Reactions: binkinator
General chit-chat
Help Users
  • No one is chatting at the moment.
  • Skelletonike @ Skelletonike:
    1H left, such a slow week.
  • Sonic Angel Knight @ Sonic Angel Knight:
    Okay, I had spaghetti :P
  • SylverReZ @ SylverReZ:
    Hope they made lots of spaget
  • K3N1 @ K3N1:
    Chill dog
  • SylverReZ @ SylverReZ:
    Chilli dog
  • Skelletonike @ Skelletonike:
    Damn, I'm loving the new zelda.
  • xtremegamer @ xtremegamer:
    loving the new zelda, i started a game, it was so fucking good, so i
    am waiting on my friend to get home so we can start a new one together
  • Skelletonike @ Skelletonike:
    I just dislike that they don't let me choose the voices before the game starts. Happened with botw as well, had to change to japanese and restart.
  • K3N1 @ K3N1:
    But the important question is can you choose gender
  • Skelletonike @ Skelletonike:
    Same way you can choose Gerald's gender.
  • Skelletonike @ Skelletonike:
    *Geralt, damn autocorrect.
  • Psionic Roshambo @ Psionic Roshambo:
    But can he be trans? Lol
  • K3N1 @ K3N1:
    Zelda transforms into link
  • Psionic Roshambo @ Psionic Roshambo:
    Link I'm not the princess your looking for.... *Pulls a crying game*
  • K3N1 @ K3N1:
    *skirt up* it's exactly what I always wanted
  • Skelletonike @ Skelletonike:
    Just scanned all my zelda amiibos, took a while but didn't get anything that cool, did get the lon lon ranch hylian fabrics though.
  • Skelletonike @ Skelletonike:
    It was pretty funny when I scanned wolf link and got a shit load of meat.
  • K3N1 @ K3N1:
    @Skelletonike, btw I ran that custom for mgs4 on the deck I'm amazed it got that far in game
  • K3N1 @ K3N1:
    Plug in*
  • K3N1 @ K3N1:
    Your favorite activity
  • BentlyMods @ BentlyMods:
    My fav actvity is:

    mario-dancing.gif
    BentlyMods @ BentlyMods: My fav actvity is: