Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Android N support #279

Closed
risingsun03 opened this issue Mar 11, 2016 · 23 comments
Closed

Android N support #279

risingsun03 opened this issue Mar 11, 2016 · 23 comments

Comments

@risingsun03
Copy link

I'v read the document of Android N. It says

Android N includes namespace changes to prevent loading of non-public APIs. If you use the NDK, you should only be using public APIs from the Android platform. Using non-public APIs in the next official release of Android can cause your app to crash.

http://developer.android.com/intl/zh-cn/preview/behavior-changes.html#ndk

So, can STF still work on Android N ?

thx.

@sorccu
Copy link
Member

sorccu commented Mar 11, 2016

It sounds like they've just renamed some symbols. Anyway the part of STF that needs the private APIs isn't actually an app, it's a simple binary. Some changes may be required but I don't think it'll be a problem.

If I uprade my Nexus 9 to N, I won't have any 6.0 devices left. If someone donates an N-compatible device we can take a look at it faster.

@risingsun03
Copy link
Author

Thanks, man. I'll update my Nexus 9 to N, and have a try. I'll let you know the result.

@sorccu
Copy link
Member

sorccu commented Mar 11, 2016

I mean, STF won't work right now because we don't have a precompiled shared library for N yet. I'm just saying that it should be possible.

@risingsun03
Copy link
Author

When will you release a library for N? Any plan?

@sorccu
Copy link
Member

sorccu commented Mar 11, 2016

Hopefully soon. I've added a contribution link to the README, please feel free to pledge your support if you'd like to get N support faster :)

@juliusspencer
Copy link

Keen for N support, just donated. I have a Nexus 9.

@sorccu
Copy link
Member

sorccu commented Apr 12, 2016

Thanks to a few generous donations from @juliusspencer and others, we should be able to purchase a Nexus 5X for Android N development with the donations we've received so far! I will keep you updated.

@sorccu
Copy link
Member

sorccu commented Apr 12, 2016

I've scheduled a withdrawal from Bountysource and ordered a Nexus 5X from a reasonably priced seller. It should arrive this weekend (or perhaps a little later). I'll get working on N once it arrives.

@juliusspencer
Copy link

That's great @sorccu :)

I have a few other devices that are not showing up or have a grey screen. If I were to capture logs etc for you that would be useful, what would you like or where would I get them from?

I hope this isn't taking the thread too far off topic, I could make an issue for each and post it here. I

I'm also not sure whether the version I am using is correct. I installed using the README.md:

brew install rethinkdb graphicsmagick zeromq protobuf yasm pkg-config

and

npm install -g stf

@sorccu
Copy link
Member

sorccu commented Apr 12, 2016

Yes that would be a separate issue, but some devices indeed do not work. It's difficult to say if that's the case here, as there can be many different causes. Anyway please create an issue per device that doesn't work, and include as much information as possible. Unfortunately most of the time the issues are difficult or borderline impossible to solve without having physical access to the device, so what we can do is quite limited. We could perhaps try to buy second hand devices, but sadly even having access to a device doesn't guarantee success, and even if it works out it can take several days of developer time.

@sorccu
Copy link
Member

sorccu commented Apr 14, 2016

Ok, I've received and flashed the 5X. It seems that the current N version works without any changes to STF. It still introduces itself as SDK 23, which is likely to change over time, but at the very least there seem to be no breaking API changes so far.

So, the status as of Android N Preview 1 is that it works as-is. I will keep monitoring the preview updates.

@sorccu sorccu changed the title Can STF support Android N? Android N support Apr 14, 2016
@sorccu
Copy link
Member

sorccu commented Apr 14, 2016

It turns out that Developer Preview 2 was just released, and that's what I actually tested even though the site wasn't fully updated yet. Android N Preview 1 will therefore go untested.

So, to correct my previous statement, it's Android N Preview 2 that has been tested and works fine.

@juliusspencer
Copy link

Hey, it is now working on our Nexus 9. Sweet!

@hong3e
Copy link

hong3e commented Jun 28, 2016

Hello, I want to use Android N Preview 4. Could you plz check STF working?

sorccu added a commit that referenced this issue Jun 28, 2016
@sorccu
Copy link
Member

sorccu commented Jun 28, 2016

Should work now if you build from master.

@X-Kent
Copy link

X-Kent commented Jul 7, 2016

You may want to test your app with SDK set to 24. The behaviour may change:
http://android-developers.blogspot.co.il/2016/06/improving-stability-with-private-cc.html

@sorccu
Copy link
Member

sorccu commented Jul 7, 2016

Our "app" that requires private API access is not an app. It's a stand-alone binary run inside the device as the shell user. Therefore the same rules don't apply.

@sorccu
Copy link
Member

sorccu commented Jul 7, 2016

And for what it's worth, it works fine on a Nexus 5X running Preview 4 (which runs SDK 24) without any notifications.

@X-Kent
Copy link

X-Kent commented Jul 7, 2016

Just read your comment that in your verification you used target SDK=23 and there are different rules for 23 and 24 so thought I would let you know.
Never used stf myself so no idea what's that.

@sorccu
Copy link
Member

sorccu commented Jul 21, 2016

I've now verified that current master still works great on Android N Developer Preview 5, which is near-final (even branding has been changed to Android 7.0 already).

@ilanbenb
Copy link

ilanbenb commented Sep 6, 2016

Hello,
I have connected a nexus 5x with android 7.0(nougat) and the device was in preparing status and then it became disconnected.
Does it works for somebody?
My rom version is nrd90m.

------------------------- Update --------------

The problem was that my node.js was not new enough on my ubuntu 14.04 machine.
Thanks to @sorccu for the help!

@sorccu
Copy link
Member

sorccu commented Sep 6, 2016

I just tried on NRD90S and it works fine. Haven't checked NRD90M but it should also work just fine.

@sorccu
Copy link
Member

sorccu commented Sep 6, 2017

Not sure why this issue is still open. Android N has been supported for a long long time.

@sorccu sorccu closed this as completed Sep 6, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants