Use 'cvs rls' to check repository existance rather than checking CVSROOT/modules.

The CVSROOT/modules file is not available on every CVS server, which makes it
impossible to add some repositories. This change fixes check_repository to use
'cvs rls' instead. If this command succeeds, we know that there's an accessible
cvs server at the given cvsroot.

Testing done: Added the cvs cvs to my local server.

Fixes bug 1986.

Reviewed at https://reviews.reviewboard.org/r/5392/
Backport python-ldap unicode fixes to release-1.7.x, add to LDAPBackend.

We had made a fix on master to encode username/password/etc before passing them
into python-ldap for the ADBackend, but never made a similar fix for the
LDAPBackend. This fix also was done on master, rather than release-1.7.x.

Fixes bug 3256.

Reviewed at https://reviews.reviewboard.org/r/5513/
Handle LDAP users who don't have email addresses configured.

When a given field isn't defined for a user, the result from ldap searches will
not include that key at all. This means that in the case of users who don't
have an email address set, they won't be able to log in to Review Board.

This change handles KeyError in get_or_create_user when using a special email
attribute and logs the error instead of failing.

Fixes bug 3257.

Reviewed at https://reviews.reviewboard.org/r/5512/
Merge branch 'release-1.7.x' into release-2.0.x
Add a Sphinx extension to copy over Retina images.

Sphinx only actually copies over images that are used in documents. This
means that while we can dump @2x copies of images into _static, they
won't be used.

This extension hooks into the environment generation and html page
collection events, looking for @2x equivalents for all images that are
in use. It then adds them to the list of images set to be copied into
_images.