libcore: Better Enum fix for JDK 7

 * Jerome Pilliet suggests using a cast in the compareTo method instead of
   changing the field visibility. This is a much better fix.

Change-Id: I334105e0922225512a4d0a2d4b6c9c6ec71b9c51
Remove support for duplicate file entries

Bug: 8219321
Change-Id: Ibc56bea753917c38e1bb20df48aa45fdff39d364