php8: workaround libgd capability detection (refs #23846)
This is an alternative approach to #24209. Instead of switching
to bundled/internal libgd, workaround the capability detection
by giving the information to the build system directly.
PHP's original approach does not work when cross-compiling,
but since it is known which features are enabled in OpenWrt's
build, we can directly enable these features here, too.
This is not that future prove, but should do the job for the
moment until a proper solution was discussed with upstream.
Signed-off-by: Michael Heimpold <mhei@heimpold.de>