-
Notifications
You must be signed in to change notification settings - Fork 12
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Enable newlib iconv #33
Conversation
Hey, dudes, so I'm actually working on doing this as well for our toolchain build scripts in KallistiOS... But after struggling to make sense of the Newlib documentation for quite awhile, I am kind of left with the impression that this flag alone will simply allow you to use the API, but without specifying any actual encodings to pass to newlib via At least I think this is how it works? I need to do more testing, but I wanted to run this by you. |
According to the browser of my PSP(2000), these are the encodings listed:
I found the encoding by following the guide here: https://manuals.playstation.net/document/en/psp/current/network/browser/encode.html Is that the right encoding to use/support or idk if i'm correct? hopefully it can help |
Yes, those are what are supported, but are those what are enabled by default? The iconv library is built so that you can pick and choose which encodings get compiled into the binary, so that you aren't automatically including everything and are able to conserve space on embedded platforms. Notice there's also options for |
Thanks for the insight!, I think
you can set the from/to(is it src/dest equivalent?) of encodings, hopefully it can help you i'm currently testing this one too in my free time to merge it but it's much better to look by knowledgeable maintainer ❤️ and maybe this will add to libcglue too |
yes the to/from encodings configure option is the solution to conserve some space instead of just |
Okay, guys, I finally had the chance to enable this in the Dreamcast/KallistiOS toolchains, and I have some stuff to report...
For KallistiOS, we opted to give the user an (optional) list of encodings to enable which is populated with the most common ones that users will need by default (ascii, utf8, utf16, wchar). We basically have a configuration script which allows the user to set variables which then get translated into options and flags to pass to the toolchain... Here's the PR for the DC: KallistiOS/KallistiOS#532 edit: Btw, don't forget you can also enable multibyte strings in Newlib, which I'm assuming you'll probably want if you're going to go as far as to support |
Unfortunately, the MacOS build failing is expected. GitHub changed which MacOS achitecture is the default and we don't have full support for ARM on MacOS yet. |
There's a change in the workflow file, let me try to re-run it if it builds correctly now |
Btw, I noticed you guys went ahead and pulled in |
I think it's the default pre-utf-8 encoding for fat32/windows. |
What's missing here? @sajattack could you rebase it? as it has some CIs failing right now |
d025846
to
c0853d5
Compare
rebased |
We have the headers for this but our libc doesn't actually contain the definitions. This is related to utf-8 string conversions and is built into newlib but we're not taking advantage of it.