thermatk / FakeGApps

A better approach for microg
GNU General Public License v3.0
227 stars 48 forks source link

Make it possible to exclude certain apps #6

Closed haffenloher closed 9 years ago

haffenloher commented 9 years ago

...namely F-Droid, which does not want to update microg software packages unless it sees the correct package signature.

Unfortunately, I had to create a service just for resolving UIDs to package names (apparently, one needs some kind of context to do that).

bonanza123 commented 9 years ago

Cool, I will try this out on Monday evening and report :-)

thermatk commented 9 years ago

How is it going? Can't test right now, so need reports. And what's the point? I mean, I was always using self-built microg packages, are those on F-Droid already with gms and vending capabilities? Or is it for the future?

haffenloher commented 9 years ago

what's the point?

I was setting up my own F-Droid repo for GmsCore, Blankstore, FakeGapps etc. (see here) and encountered this problem on the way. At first I actually thought I was hitting some strange F-Droid bug before the signature faking finally came to mind ;)

PS: Here's the diff without whitespace changes, to make it a little easier to read: https://github.com/thermatk/FakeGApps/pull/6/files?w=1

bonanza123 commented 9 years ago

I built it and I'm having a lot of xposed exceptions (running latest omnirom nightly for nexus5): https://gist.github.com/bonanza123/2adb8fcd77d9dabd3000

haffenloher commented 9 years ago

java.lang.ClassNotFoundException: com.android.server.am.ActivityManagerService

That's funny, how is that even possible? I only tested it on Android 4.2 (shame on me...) but it's not like this class has been removed with Android 5 or something.

..ok, I just found some info that this may be related to a problem with Xposed for Lollipop that was fixed / mitigated with XposedBridge v65. I'll look into it (have to get Xposed running in the emulator first...)

haffenloher commented 9 years ago

@bonanza123: Thanks for your log! I think I got it now, could you test it once again?

bonanza123 commented 9 years ago

Here is a new log: https://gist.github.com/bonanza123/18ca76c5df96e60ba0b0 which gives a lot of java.lang.NullPointerException: Attempt to invoke virtual method 'android.content.pm.PackageManager android.content.Context.getPackageManager()' on a null object reference errors

haffenloher commented 9 years ago

Thanks again! I was finally able to set everything up in an emulator to reproduce your problem. Everything works fine for me now both on Android 4.2 and 5.1.

bonanza123 commented 9 years ago

I can confirm that's it's working on my device. Thanks!

@thermatk if you are fine with that, I could merge it and upload a new apk.