pkg-utils: introduce a make-based LOWERCASE function
Until now, our UPPERCASE function was implemented purely in make for
performance reasons, but our LOWERCASE function was implemented by
calling "tr", which was reasonable due to the fact that LOWERCASE was
rarely used, but future changes might make a more heavy usage of the
LOWERCASE macro.
We want this LOWERCASE function to turn a "_" into a "-" and not a
".", so we slightly adjust the existing FROM and TO lists to make this
possible. This doesn't change the behavior of the UPPERCASE macro
because both "-" and "." are converted into "_" by this function.
This change takes advantage of suggestions made by Arnout
Vandecappelle, who said they further improve the performance of
UPPERCASE and LOWERCASE by 30%/40%.
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>