Makefile: Add rules for building kselftests

Linux kselftests are userspace programs (with optional kernel modules)
built from the Linux codebase. Add rules for building these.

Building these is a bit cumbersome because:
  * cross-compiling with Clang is not supported, and
  * building out-of-tree still clobbers the source directory.

Because of these, we use rsync to make a copy of the source directory
and build the tests in-tree. Tests are rebuilt only if some files were
overwritten by rsync (and a stamp file touched).

When the kernel (and modules) are built with Clang, the userspace
programs are built with GCC. The config file for Clang is copied over
and updated for GCC with `make olddefconfig`. This should preserve the
same configuration options.

Bug: 193407077
Test: make kselftest
Change-Id: I8e7fb0b39139f806c06b3847ce581389b2f1266c
1 file changed