rootbeer icon indicating copy to clipboard operation
rootbeer copied to clipboard

Flavor without native checks

Open ligi opened this issue 7 years ago • 11 comments

I am using rootbeer in @walleth - there it is not so important that all kinds of root are detected as it is just displayed as a security information to the user (like this: https://twitter.com/wallethapp/status/993808674895343616 ) - it is more important to me that the file is not so big and all devices are able to update (this is now broken with a recent rootbeer update as the amount of included Native platforms was reduced) - unfortunately I just noticed when releasing on play and got the warning. It would be great if there is a flavor in rootbeer that does not contain the native checks - what do you think? The other option I see is to fork the project and remove these checks - but I would prefer to not fork.

ligi avatar Aug 01 '18 09:08 ligi

Thanks for the question, to confirm I understand you want a no-native check flavour because the file size of the native libraries adds too much to your .apk? Unless I'm missing something the output .aar is only 25K.

We support armeabi-v7a arm64-v8a x86 x86_64 the others (armeabi and MIPS) are deprecated AFAIK. Maybe you could post the warning you're seeing in the Playstore?

That said if you'd still like at Non-Native flavour then please do fork the repo and send us a pull request.

scottyab avatar Aug 01 '18 09:08 scottyab

Thanks for answering so fast. Yea the size is not that important as it is quite small - still a little bit of an argument for me as I want to target android go devices and so I need to keep things really small.

My main problem is that I now have 2 active apks (one old and I rather not want to have it active anymore) caused by this. Unfortunately I did not make a screenshot of the warning I got when uploading the new version to the playstore and now I cannot get back to the warning. But it was basically stating that the new version supports less devices than the old one and therefore the old apk will stay active.

ligi avatar Aug 01 '18 09:08 ligi

hmmm, I wonder if it's due to us dropped support for armeabi? and I wonder if you'll have the same issue if you release a new version without native libs.

@stealthcopter thoughts?

scottyab avatar Aug 01 '18 09:08 scottyab

and I wonder if you'll have the same issue if you release a new version without native libs.

I do not think so as this version will then support all devices again

ligi avatar Aug 01 '18 09:08 ligi

I'm wondering how google play performs the check. Our native libraries are 'nice to haves' and not essential for operation so it would be good if we could flag this so that it is compatible with all devices regardless of architecture.

stealthcopter avatar Aug 01 '18 09:08 stealthcopter

Seems kinda shitty but I think the way to achieve it is to create dummy libraries for the deprecated archtectuires. Not feeling great about this, any thoughts? http://grokbase.com/t/gg/android-ndk/125v31e6wy/play-store-market-filtering-of-ndk-libs

stealthcopter avatar Aug 01 '18 09:08 stealthcopter

Thanks so much for looking into this! Yea the solution is shitty but would work for me. The other solution mentioned there is much nicer - but also a bit more work. For now I just do a hotfix and remove the native stuff and consume it via jitpack - while doing so I saw this:

https://github.com/scottyab/rootbeer/blob/master/rootbeerlib/src/test/java/com/scottyab/rootbeer/RootBeerTest.java#L69

looks wrong to me - but don't want to open a separate issue for this - just sharing what I noticed ;-)

ligi avatar Aug 01 '18 10:08 ligi

Just got a nice hint from @cketti - maybe https://github.com/KeepSafe/ReLinker can help to make the cleaner way easier to do

ligi avatar Aug 01 '18 12:08 ligi

Hi,

I'm using RootBeer (v0.0.8) and faced the same issue. After I uploaded new app bundle, it showed '4 native platforms: arm64-v8a, armeabi-v7a, x86, x86_64' and warning about device limitations etc. for the ones using 'previous' version of the app.

How can I fix this ?

elvinakhundzada avatar Aug 11 '20 12:08 elvinakhundzada

I am using this fork:

implementation 'com.github.ligi:rootbeer:remove_native_workaround'

you can get via @jitpack

ligi avatar Aug 11 '20 12:08 ligi

Thank you for your quick reply, @ligi !

I just tried the way you suggested, but the result is still the same. But interestingly, for the current live version of the app and the one that I just uploaded, I have the same "Supported Android devices" count. Only difference is Native platforms. For the current live version it shows all native platforms and 4 native platforms: arm64-v8a, armeabi-v7a, x86, x86_64 for the newer one.

elvinakhundzada avatar Aug 11 '20 12:08 elvinakhundzada