All of these are tools that are only meant to be used when testing swift. Thus
it doesn't make sense to include them in the catch all 'tools' install component
that distributions use to build all the tools.
I verified that all of the mac/linux presets in tree that have tools also has
testsuite-tools so this should be NFC. On Windows, I needed to add
testsuite-tools to build-windows.bat so should be NFC there as well.
We don't actually need the range for layout nodes, so just store it
for token nodes. This will also make deferred node handling easier
later on, because we don't need to keep track of layout node ranges.
Previously, the passed in source file was implicitly terminated by the
first null character. The source file might, however, contain a null
character in the middle and we shouldn't stop parsing at it.
Adjust the build rules to add a build RPATH into the executable to
ensure that `lib_InternalSwiftSyntaxParser.so` is properly found when
running the tests. This also should ensure that we always use the
correct version, irrespective of the setting of `LD_LIBRARY_PATH`. This
RPATH is marked as a `BUILD_RPATH` and will be stripped if the tool is
installed.
Adjust the dependencies to be clearer using generator expressions and
use the `target_compile_options` rather than the more fragile
`set_target_properties` to add `-fblocks` to the compilation. This is
now possible as we are ensured that we are using CMake 3.15+.
Restore the previous commit which somehow passed the buildbot given a
missing condition on the sub-configure for libdispatch. This makes it
more explicit as to what the desire is; the variable was being used to
serve as a proxy for whether the build is not on a Darwin target.
This flag was being used as an alias for whether or not the host is
non-Darwin. Rather than adding custom checks for this, use the explicit
check that CMake supports. This simplifies the logic and avoids the
proliferation of custom variables which can become confusing for others
who are not familiar with the custom build infrastructure.
When building in a unified build and building the host tools with a
non-clang compiler, we switch compilers. In such a case, we need to
actually add an explicit dependency on the new compiler.
Add a shared library with a C API that provides access to the syntactic parser with callbacks for the inference of raw syntax nodes.
This is primarily intended to be used by SwiftSyntax to speed-up source code parsing for it.