Conversation
Well, effectively I know this is happening because I set __ANDROID_SDK__=21 manually and it said nuh uh, __ANDROID_SDK__ is already 26
1
It should be fine if it's actually set to the same value that you end up having for minSdkVersion at runtime.
If it's 26 for the native code and 23 at runtime, it'll break. If you set minSdkVersion to 26 so it matched it wouldn't break, since it'd match what it's using to build.
1
Still must have a mismatch between build time __ANDROID_API__ and runtime minSdkVersion if you're getting the sendto error.
1
1
wait, what does "runtime minSdkVersion" mean exactly?
1
Like, do you mean "the minsdkversion at runtime" or "the minsdkversion of the runtime?"
1
Hey so, I really appreciate your help on this and I'm sorry about all these minor questions… I do have one more question.
Is _chk something that would appear on all functions, or only socket functions such as sendto?
2
For example, if I'm trying to figure out why the problem is occurring on libpd but not any other library— is it possible that libpd happens to be the only binary calling sendto or any other sys/socket function, and therefore the only one TRYING to load a _chk?
1
Replying to
sendto fortify support was added in API 26, so if you build with minimum API set to 26, it uses that, but then at runtime the OS is treating the app as minSdkVersion 23 and is hiding all native symbols (to the extent possible) introduced in API levels above 23 for compat.
1
1
It's not the only thing that will break if the min API level is set higher than the intended one.

