WASM_SPEC_TEST_TAR_PATH actually refers to a tarball that has already
been decompressed with gzip, so running `tar -xzf` on it fails.
I introduced this mistake in 66582a875f.
There is no need to keep an intermediary plain .tar file around, we can
pass the WASM_SPEC_TEST_GZ_PATH .tar.gz directly to `tar -xzf`.
While GNU tar automatically detects the used compression algorithm,
POSIX requires that we specify -z if the tarball is compressed with
gzip.
Fixes a build error on OpenBSD.
We have seen some cases where the build fails for folks, and they are
missing unzip/tar/gzip etc. We can catch some of these in CMake itself,
so lets make sure to handle that uniformly across the build system.
The REQUIRED flag to `find_program` was only added on in CMake 3.18 and
above, so we can't rely on that to actually halt the program execution.
This common strategy of having a serenity_option() macro defined in
either the Lagom or top level CMakeLists.txt allows us to do two things:
First, we can more clearly see which options are Serenity-specific,
Lagom-specific, or common between the target and host builds.
Second, it enables the upcoming SuperBuild changes to set() the options
in the SuperBuild's CMake cache and forward each target's options to the
corresponding ExternalProject.
By using SerenityOS_SOURCE_DIR we can make custom targets and commands
agnostic to the actual location of the root CMakeLists directory.
All we care about is the root of the SerenityOS project.