libpurple: make perl support optional

Closes #18312.

Signed-off-by: Adam Vandenberg <flangy@gmail.com>