Use a filename sorting method based on that used by dpkg for version nos.

We no longer treat colons as slashes.
We still translate backslashes to forward slashes, but only on Windows.
~ is now sorted before everything else.

See the following URL for the original code:
http://anonscm.debian.org/gitweb/?p=dpkg/dpkg.git;a=blob;f=lib/dpkg/version.c;hb=74946af470550a3295e00cf57eca1747215b9311