When a project is consuming unity as as subproject, unity headers,
static library and pkg config files are installed by `meson install`.
This can be fixed by using `meson install --skip-subprojects`, but this
must be repeated in all the distros packaging a project.
Fixed by disabling install when building as a subproject.
Fixes: #661
1. Call the version extraction script directly instead
of through a Python returned from `find_program()`.
2. We don't need to use `meson.project_source_root()` as
`find_program()` will search relative to the current meson.build
script.
3. Lower the required version back to `>= 0.37.0`, and modify
some things to get rid of warnings with this version selected.
The use of `summary()`, `dict`, and positional arguments in
`pkgconfig.generate()` generate warnings with this version so
remove `summary()` and dict()`, also pass keyword arguments to
`pkgconfig.generate()`.
The following features from the CMake build have been implemented:
* Library version retrieved from unity.h.
* Extension support.
* Library, header, and package configuration file installation.
This commit is entirely based on existing work by Owen Torres.
1. Use cross-platform `/` operator for path construction.
2. Use `meson.project_source_root()` for correct path resolution of
generate_test_runner.rb path when used as a subproject.
3. Bump the minimum required Meson version to '0.56.0' as this is
needed for the above changes.
If the range is <start, end, step> instead of [start, end, step], the
end value will not be included in the range.
This can be useful if you have a define that defines e.g. the size of
something and you want to use this define as the end value. As the
pre-processor doesn't evalutate expressions (unless you do some macro
magic) you can't specify the range as [0, MY_SIZE - 1, 1]. With this
change you can then instead give the range <0, MY_SIZE, 1>.
This change helps Unity parse and print correctly in cases where a long
or long long type is passed to TEST_PRINTF.
Example situations:
```C
// With %u:
TEST_PRINTF("%u %d\n", ((1ULL << 63) - 1), 5); // --> prints 11982546 -1 (both arguments incorrect because only 4 of the 8 bytes were read out of the va_list)
// With %llu, UNITY_SUPPORT_64=0
TEST_PRINTF("%llu %d\n", ((1ULL << 63) - 1), 5); // --> prints 4294967295 5 (first argument wrapped, second argument intact)
// With %llu, UNITY_SUPPORT_64=1
TEST_PRINTF("%llu %d\n", ((1ULL << 63) - 1), 5); // --> prints 9223372036854775807 5 (both arguments correct)
```