Implement compatibility support for WRITE_SDCARD permission.

Now old applications will automatically be granted it.  Also renamed it from
SDCARD_WRITE to WRITE_SDCARD to be consistent with our other permissions,
and re-arranged how we do targetSdkVersion to actually be usuable for this
kind of stuff.

Note that right now this results in basically all apps being given the
WRITE_SDCARD permission, because their targetSdkVersion is not set.  I will
be dealing with that in a future change.
diff --git a/core/res/AndroidManifest.xml b/core/res/AndroidManifest.xml
index 05fbe64..d4b314a 100644
--- a/core/res/AndroidManifest.xml
+++ b/core/res/AndroidManifest.xml
@@ -389,11 +389,11 @@
         android:description="@string/permgroupdesc_storage" />
 
     <!-- Allows an application to write to the SD card -->
-    <permission android:name="android.permission.SDCARD_WRITE"
+    <permission android:name="android.permission.WRITE_SDCARD"
         android:permissionGroup="android.permission-group.STORAGE"
         android:label="@string/permlab_sdcardWrite"
         android:description="@string/permdesc_sdcardWrite"
-        android:protectionLevel="normal" />
+        android:protectionLevel="dangerous" />
 
     <!-- ============================================ -->
     <!-- Permissions for low-level system interaction -->