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

Fix boinc platform strings for Android #3740

Merged
merged 3 commits into from
Jun 22, 2020
Merged

Conversation

truboxl
Copy link
Contributor

@truboxl truboxl commented May 19, 2020

Description of the Change
Some compiled clients may appear as $ARCH-unknown-linux-android instead of
$ARCH-android-linux-gnu to project servers
This is because of Android NDK specifies $ARCH-linux-android triplets and
users forget to specify --with-boinc-platform

Fix this in boinc_platform.m4 so that Android boinc platform strings changes are not needed across all projects

boinc_alt_platform is excluded to prepare for 64bit only Android devices
Users can add back requesting 32bit tasks with --with-boinc-alt-platform during compile or <alt_platform> during runtime

Alternate Designs
Feedbacks are welcome.

Release Notes
N/A

@codecov
Copy link

codecov bot commented May 19, 2020

Codecov Report

Merging #3740 into master will increase coverage by 0.82%.
The diff coverage is n/a.

@@            Coverage Diff             @@
##           master    #3740      +/-   ##
==========================================
+ Coverage   15.66%   16.49%   +0.82%     
==========================================
  Files         136      133       -3     
  Lines       13873    13171     -702     
  Branches     1770     1630     -140     
==========================================
- Hits         2173     2172       -1     
+ Misses      11568    10867     -701     
  Partials      132      132              
Impacted Files Coverage Δ
lib/url.cpp 92.90% <0.00%> (-7.10%) ⬇️
...c/main/java/edu/berkeley/boinc/utils/BOINCUtils.kt 23.80% <0.00%> (-0.52%) ⬇️
...rc/main/java/edu/berkeley/boinc/rpc/RpcClient.java 29.38% <0.00%> (-0.11%) ⬇️
lib/util.cpp 0.00% <0.00%> (ø)
lib/mfile.cpp 0.00% <0.00%> (ø)
lib/parse.cpp 11.29% <0.00%> (ø)
lib/coproc.cpp 0.00% <0.00%> (ø)
lib/filesys.cpp 0.00% <0.00%> (ø)
lib/miofile.cpp 0.00% <0.00%> (ø)
lib/md5_file.cpp 0.00% <0.00%> (ø)
... and 39 more

@AenBleidd
Copy link
Member

I'm not sure whether these lines are correct or not.
@davidpanderson, could you please take a look at it?
Thanks in advance

@davidpanderson
Copy link
Contributor

The official list of platform names is here:
https://boinc.berkeley.edu/trac/wiki/BoincPlatforms
These are all consistent with that.

@AenBleidd
Copy link
Member

@truboxl, could you please add similar logic to define boinc_alt_platform?

@truboxl
Copy link
Contributor Author

truboxl commented Jun 19, 2020

I think the intention is not to add them to prepare for 64bit only systems. If the devs think it should be included then ok I guess I will add them, Once these added I think can remove --with-boinc-platform and etc from build scripts...

@AenBleidd
Copy link
Member

You still need them in build scripts when cross-compiling for different platforms but if you build it for your native platform - then yes, no need to specify this parameter in build script

@truboxl
Copy link
Contributor Author

truboxl commented Jun 20, 2020

Ah yes you are right
I totally forgot needing to pass --host=$ARCH-linux-android
using that will automatically picks up the respective platform strings without needing overrides --with-boinc-platform and etc

This is inline with https://developer.android.com/ndk/guides/standalone_toolchain#projects_using_autoconf and https://github.com/curl/curl/blob/master/docs/INSTALL.md#android

Some compiled clients may appear as "$ARCH-unknown-linux-android" instead of "$ARCH-android-linux-gnu" to project servers
This is because of Android NDK specifies "$ARCH-linux-android" triplets and users forget to specify "--with-boinc-platform"
Fix this in "boinc_platform.m4" so that Android boinc platform strings changes are not needed across all projects
boinc_alt_platform is excluded to prepare for 64bit only Android devices
Users can add back requesting 32bit tasks with "--with-boinc-alt-platform" during compile or "<alt_platform>" during runtime
...triple (see NDK clang -print-target-triple)
@AenBleidd AenBleidd added this to the Client/Manager 8.0 milestone Jun 22, 2020
@AenBleidd AenBleidd merged commit 4573d5f into BOINC:master Jun 22, 2020
@truboxl truboxl deleted the patch-3 branch June 24, 2020 03:28
@AenBleidd AenBleidd modified the milestones: Client/Manager 8.0, Client Release 7.16.8 Jul 10, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants