Even though in some cases setlocale() may require a country code in addition to the language code this does not mean that it is required for gettext.
If setlocale() is set to either es_ES or es_MX gettext() will still get the text from a po file in the 'es' folder.
It probably is not a good idea to go changing a systems alias file(s) just to avoid the verbosity of the ISO standard because:
a) you might break something
b) your code just lost it's portability
.