devel/glib20: Add option for unit tests
Don't build tests by default, the reduces time spent on compiling
substantially (~450 objects vs ~1200)
Add dependency for unit tests
Some tests are disable due to circular dependency
Backport upstream commit 75c854b359b8bd8b78938e51e5a2c7a42e5847ae
to fix an issue calling getpwnam_r
Thanks to arrowd for troubleshooting and submitting bugfix upstream
References:
https://gitlab.gnome.org/GNOME/glib/-/issues/2488
https://gitlab.gnome.org/GNOME/glib/-/commit/75c854b359b8bd8b78938e51e5a2c7a42e5847ae
https://gitlab.gnome.org/GNOME/glib/-/merge_requests/2276 (backport)
PR: 257623
Approved by: arrowd (mentor)
Differential Revision: https://reviews.freebsd.org/D31702