Fix "language" typo.
Add cache table for team totals for efficiently computing team rank. This is not used anywhere yet.
Use smart rank computation for displaying team row. This can highly improve efficiency in contests with many teams, but the behavior is not completely unchanged. There are two changes:

* The first correct submission per problem is not computed, so the dark-green cells in the table for first-correct per problem are not shown on the team page.
* When a problem for which there are correct submissions is disabled during a contest, the cache is out-of-sync and should be rebuild.
Do not try to install no-more-existent lib/ext/ dir.

Leaving the configure variable libextdir for now, since we may want
to reintroduce such a dir in the future.

Thanks Francisco Justo for reporting.