openorbis / musl Goto Github PK
View Code? Open in Web Editor NEWA PS4 port of musl for the OpenOrbis PS4 Toolchain.
License: Other
A PS4 port of musl for the OpenOrbis PS4 Toolchain.
License: Other
Do you think it will be possible to run https://openjdk.java.net/projects/portola on the PS4?
Originally reported by LM in the discord:
Apparently sleep()
does not function properly, calling it is effectively a no-op.
In file included from src/fcntl/open.c:2:
src/fcntl/open.c: In function 'open':
src/fcntl/open.c:16:21: warning: 'mode_t' {aka 'short unsigned int'} is promoted to 'int' when passed through '...'
16 | mode = va_arg(ap, mode_t);
./include/stdarg.h:14:44: note: in definition of macro 'va_arg'
14 | #define va_arg(v,l) __builtin_va_arg(v,l)
| ^
src/fcntl/open.c:16:21: note: (so you should pass 'int' not 'mode_t' {aka 'short unsigned int'} to 'va_arg')
16 | mode = va_arg(ap, mode_t);
./include/stdarg.h:14:44: note: in definition of macro 'va_arg'
14 | #define va_arg(v,l) __builtin_va_arg(v,l)
| ^
src/fcntl/open.c:16:21: note: if this code is reached, the program will abort
16 | mode = va_arg(ap, mode_t);
./include/stdarg.h:14:44: note: in definition of macro 'va_arg'
14 | #define va_arg(v,l) __builtin_va_arg(v,l)
| ^
XXX: is this actually an upstream issue?
Got this while trying to compile JamVM:
ld.lld: error: undefined symbol: _pthread_cleanup_push
>>> referenced by res_msend.c
>>> res_msend.lo:(__res_msend_rc) in archive /home/sergey/openorbis//lib/libc.a
ld.lld: error: undefined symbol: _pthread_cleanup_pop
>>> referenced by res_msend.c
>>> res_msend.lo:(__res_msend_rc) in archive /home/sergey/openorbis//lib/libc.a
Musl is internally using some pthread functions (pthread_cleanup_push
and pthread_cleanup_pop
in this case) that are not implemented in the "fallback" implementation.
In Linux, musl is received as a light libc variant, and alternative to glibc. Over the years/decades, glibc has gathered bulk due to backwards compatibility support, which musl shaves off, and generally developers of musl libc make choices to keep the code size small (it's almost 1/3rd of the size of glibc).
Given the above, I have few questions:
This is not a bugreport, just a possible enhancement.
Arguments:
For syscalls that the PS4 doesn't have available, we currently punt by always returning -1. There seems to be two broad categories for how we can usually do this better, though:
fanotify_init
, should set errno
to ENOSYS
, so that the caller will have a clue about why it actually failed, instead of getting a random unrelated error.pipe2
, should do that instead of failing entirely. In fact, in that case it looks like the code to do that is already there; we just #ifdef
'ed out a bit too much.The socket options for Linux and BSD use different values for, e.g., SO_REUSEADDR, which in turn cause setsockopt to behave incorrectly.
musl: #define SO_REUSEADDR 2
freebsd: #define SO_REUSEADDR 0x0004
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.