Was possible when translation service was adding a base64 encoded string with a length less than 1536 characters.
Introduced in commit c20b01e9e1472625e338b1c3a7e657e6ff20213c.
The pthread wrapper uses semaphores to simulate condition variables,
but it is easy to hit the 3DS' limit of available semaphores. libctru
2.0 supplies a lightweight condition variable API. We will use that
when it exists, and backport it when it doesn't.
libretro-common/audio/audio_mixer.c:195:32: error: unknown type name ‘rwav_t’
static bool wav_to_float(const rwav_t* wav, float** pcm, size_t samples_out)
^~~~~~
plus about 500 errors when trying to use that struct
Older devkitARM toolchains incorrectly prevent _pthreadtypes.h from being included. Newer versions include it.
In order to make a version of ctr_pthread.h that works under both old and new toolchains, the typedefs are guarded by a define in _pthreadtypes.h that is only active if the other types are defined.
I've also added casts in order to make sure this compiles correctly with the standard pthread.h type definitions.
Set USE_CTRULIB_2=1 to build with libctru 2.0. When unset, this code
is compatible with the older toolchain.
Some 2.0 changes addressed rare problems in earlier versions:
- Save / restore stack pointer for init / exit
Otherwise, it could be outside of the range we deallocate.
- Run aptMainLoop in the audio driver to react correctly to sleep events
Other changes for 2.0:
- Remove ninjhax1 -- requires outdated APIs that have been removed
- Switch from __sync_arbiter to syncArbitrateAddress
- Use implicit gxCmdBuf
- Use gpuPresentBuffer for double buffering