Previously, "-D__STDC_VERSION__=199901L" was used to request C99
functionality from the system headers, but this does not tell the
compiler to provide C99 language features, so for example the
"restrict" keyword is not available then. This mismatch breaks the
build when using musl libc.
Instead we use "-std=c99" to select C99, but this has the side effect
of disabling non-standard APIs. So we have to manually re-select those.
The simplest way of doing so is "-D_DEFAULT_SOURCE", but that is not
universally supported yet by libcs, so for now I opted for the more
portable "-D_POSIX_C_SOURCE=199309L" to get access to clock_gettime()
and maybe other functionality not in the C99 standard.
Signed-off-by: Maarten ter Huurne <maarten@treewalker.org>
Move the test apps to their own CMakeLists.txt and
add a standalone/CMakeLists.txt which allows building
the containers test application as a standalone app for PC
mmal: fix the standalone build
Fix the standalone build to allow building the test applications
on PC.