Some other changes I make, except the patches, which I posted about before. Hopefully useful for others too:
Deletion list
The quoted names follow the Edify format for easy inclusion in your updater-script but all of it can also be deleted manually:
Code:
delete("/system/recovery-from-boot.p");
delete("/system/etc/install-recovery.sh");
If you are using custom recovery, this script will replace it with the stock one. Removing it might also make the device boot slightly faster. The other file is a binary patch to bring back the stock recovery.
Even if you use the stock recovery, there's no harm in getting rid of this script. The worst that can happen is you'll need to re-flash the recovery on your own (
adb reboot bootloader, fastboot flash recovery ...).
Code:
delete_recursive("/system/etc/jeejen/");
In their images, Xiaomi bundles a separate, simplified user interface originally intended for elderly people. I think it's not really that bad but it's removed in Xiaomi.eu's ROMs, probably because it's not translated. This directory is just a leftover that serves no purpose, all the other stuff was already removed anyway.
Code:
delete("/data/miui/apps/vanward_applist");
Leftover file, list of apps to be provisioned for some customer profile. Incidentally, Vanward
appears to be a water-boiler manufacturer in Canton, China.
Code:
delete("/data/app/com.google.android.googlequicksearchbox-1.apk");
This is the Google Now app that is actually bundled by Xiaomi.eu. Some people perhaps find it very useful, others feel exactly the opposite about it; I belong to the latter group. If you change your mind, you can always
get it from the Play Store. I really wish this were not included with the Xiaomi.eu image, as it adds nearly 40 MiB to the download (unless you're getting some revenue from it, then I understand).
Code:
delete("/data/miui/mms/understand.zip");
This appears to be a collection of pattern-recognition algorithms for parsing text messages so that some parts can be tapped on for more options. The idea is very good, unfortunately it all appears to be specific to China and a few other countries (you might want to give it a try if you're in Russia).
Code:
delete("/system/etc/spn-conf.xml");
This file provides a mapping of mobile network identification numbers to their names. There are some defaults for this somewhere else, and the preferred name for your network is stored on most modern SIM cards, so I don't really see the purpose of it, unless it's to address some specific, per-user issues. In any case, this file seems to be
seriously out of date.
Replace /system/etc/install_app_filter.xml with a nearly-empty file
This file is used to decide which apps should be provisioned in different usage scenarios (e.g. don't install China Mobile app for China Unicom customers, etc.). In other words, it's basically useless but removing it completely might trigger some error, so I created the minimum permissible version, which is attached to this post. This is mostly for cosmetic reasons but it probably gets parsed sometimes, so keeping it as empty as possible might reduce some overhead.
Replace /system/etc/init.qcom.post_boot.sh with the stock Xiaomi version
The Xiaomi.eu version of this file is customized with some "tweaks" at the end. For example:
(1)
Hard-coded resolver settings override
Code:
setprop net.rmnet0.dns1 8.8.8.8
setprop net.rmnet0.dns2 8.8.4.4
setprop net.ppp0.dns1 8.8.8.8
setprop net.ppp0.dns2 8.8.4.4
This changes the DNS settings from those obtained with DHCP to
Google's Public DNS servers. While it might be an excellent idea for some broken networks where the ISP's DNS is slower despite being topologically closer, hard-coding it in an obscure place without giving the user an opt-out (or in fact informing them at all that this is going on) is the best way to create difficult-to-isolate issues for many people. It's because of "tweaks" like this that people are cluttering support forums with complaints such as "can't open any website when using data" or "why is my phone using Google DNS that I never set up?"
Even if you want to have the DNS resolvers changed manually, I think it's a much better idea to do so with a user-space app as this way (i) you'll remember you're doing it, (ii) it can be easily disabled if (when) it stops working. The app will need superuser access but that's not a problem in MIUI. There's at least
one app called SetDNS that seems to do just that (disclaimer: never used it).
(2)
Setting magical properties and hoping for the best
Code:
setprop profiler.force_disable_err_rpt 1
setprop profiler.force_disable_ulog 1
This is simply
cargo cult. These properties only ever applied to some legacy HTC devices, and even then any benefit from changing them was dubious.
At this point I think a reasonably informed guess can be attempted about all the remaining "tweaks." I don't have the patience to go through all of them but if you're a tweaks guy, reading the
Comprehensive guide to Android tweaks by Jeff Mixon is highly recommended, and there's also
the second part. If after reading that you still want to do the "tweaks," or other configuration changes, there are proper places to put them in and this shell script is not such a place. Seriously guys, you can do better than that: this part is the low point of the whole Xiaomi.eu ROM. By the way, the most obvious tweak would be getting rid of Whetstone.
TL;DR: Revert to stock
/system/etc/init.qcom.post_boot.sh without the "tweaks" (attached below, version as of 5.3.20 but it didn't change since 2008, so it's unlikely it'll be changing soon).
To wrap it up and give it some perspective this is
everything I've found so far, and it's not a lot at all. It needs to be said here that the quality of the Xiaomi.eu ROM is really excellent, and for that the developers deserve a
BIG. THANK. YOU.