For CONFIG_BUILD_KERNEL using the sched/task/task_exithook implementation
will just not work. It calls user code with kernel privileges which is
a bit of a security issue.
Squashed commit of the following:
libs/libxx: Fix some confusing in naming. If the directory is called libxx, then the library must be libxx.a (unless perhaps LIBCXX is selected).
libs/: Fix paths in moved library directories.
libs: Brute force move of libc, libnx, and libxx to libs. Cannot yet build it in that configuration.