-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
fyne package -os android needs NDK 16/19c #3066
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
Comments
What is the output of "fyne --version"? |
@andydotxyz , I've just upgraded fyne from 2.1.4 to 2.2.1. It does not work with 24.0.8215888, complaining i686-linux-android16-clang not found. But I followed steps below and it works. Please close this. Thanks.
|
Can you please confirm this? |
@andydotxyz , yes. Now it passes with |
Excellent, it sounds like you did not have the bug fix that we recently released (#2920 I think), I am glad this is resolved. |
Hi @andydotxyz |
Not really resolved yet it seems |
Thank you for reply. I'm looking forward for any news and ready to test and cooperate to solve this issue! |
Hi @andydotxyz |
You actually need to pull the binary from that PR. I am not to sure if there is a best way, but I think you have to checkout that PR, then build and install manually the fyne binary with go build/install from the cmd/fyne subdirectory. |
Not to sure how to debug this one. On linux you can trace what command is being executed by using Otherwise which version of the NDK is installed? And is your application otherwise pure go? |
NDK is r24 from this repo. Yes, for now main.go contains fyne example with hello world:
|
Oh my - |
@Sanichka just out of interest, why are you using unsupported downloads repo? |
I've tried NDK from Android Studio at start, but then switched to unofficial source to test it since some mobile dev related YT videos were using it with go. Should I try version from android studio for testing purposes? |
Oh, that could be an explanation. It should error, but maybe it doesn't. |
Oh, what kind of NDK are you using? |
Confirmed, it silently returns "" as the command if we don't find a matching compiler... https://github.com/fyne-io/fyne/blob/develop/cmd/fyne/internal/mobile/env.go#L384 - I think we need to put in more error handling @Bluebugs. @Sanichka can you help by looking in your ANDROID_NDK_HOME and seeing if the following file exists? If not, what is the closest match:
|
@Sanichka can you give us the full path of one of those files? |
C:\Users\Alex\AppData\Local\Android\Sdk\ndk\25.0.8775105\toolchains\llvm\prebuilt\windows-x86_64\bin\x86_64-linux-android21-clang |
I got the same problem: |
@moluopro I am correct into assuming you tried it with the develop branch of fyne? If so, I wonder if the issue is not with my code and windows as I tested it on Linux. Maybe something I overlooked, I will check if I see anything. |
I've just tested develop branch and I've got same error: |
Would you mind trying with the latest develop branch out should include a fix for this. I haven't tried it on windows, so maybe there is still some improvement to be made there. |
They must go to the directory where the binary is missing in my case /lib/android-ndk/android-ndk-r25b/toolchains/llvm/prebuilt/linux-x86_64/bin/armv7a-linux-androideabi16-clang++
I copied the binary "armv7a-linux-androideabi19-clang++" into a new file which is the one that does not exist "armv7a-linux-androideabi16-clang++" repeated in process with the other missing binaries
|
@Bluebugs does this data help? |
I should try to setup a windows machine to see as the informations here are not really shining a light on the problem. |
same "exec: no command" on win10, fyne 2.4.2, ndk 25 |
Can you confirm why you edited this to remove "develop branch actually works" and your steps to replicate @observerss ? |
Hello there, |
@Bluebugs can we get to the bottom of this before v2.3.0? I'm not sure how well fixed this problem is... |
Indeed, I am planning to investigate this week. |
Cool thanks |
Maybe this could be solve it.I worked on the Windows. I got the same issue with this And I found the reson is the program try to extract the params from ndk dir but failed within filename The relating code is located at %GOPATH%\src\fyne.io\fyne\v2\cmd\fyne\internal\mobile\build_androidapp.go -> goAndroidBuild() line 94 : (ver 2.2.4) Wish these can help someone to fix this prob. |
Thanks, I will try to have a PR going today for this. |
I did it slightly differently, just in case, to be a bit more future proof. Have a look. |
This should be fixed in develop now. Please confirm and we can hopefully close this issue. |
Got it! thank you very much! |
Excellent, sounds fixed :) |
I just experienced this issue trying to switch from
As seen up thread, I made copies of these files from other existing versions (in my case, 21, and I had to do that for both armv7a and i686). Doing so I was able to move on. But no I've gotten to the point where I'm missing another file
Looks like this is #2498 and I'm not sure where to go from here. I'm not familiar enough with andorid's build environment but it seems like perhaps there should be a way for me to specify an API level that fyne should use that exists on my system? Or maybe I'm just missing some package, but if so it's hard to find. |
It should just work @hkparker - please make sure you have the latest |
Oh I'm a dummy, updating the fyne dep in my project didn't magically update the version of the tool of course. Installed the latest and we're all good here :). Thanks. |
Describe the bug:
#2922 & #2919 related but both closed. How to build android app now?
I have downloaded NDK 16, 19 & 24 in Android Studio. However armv7a-linux-androideabi16-clang still does not exist. armv7a-linux-androideabi19-clang exists.
To Reproduce:
Steps to reproduce the behaviour:
fyne package -os android
Screenshots:
no compiler for arm was found in the NDK (tried D:\SDK\ndk\24.0.8215888\toolchains\llvm\prebuilt\windows-x86_64\bin\armv7a-linux-androideabi16-clang). Make sure your NDK version is >= r19c. Use sdkmanager --update to update it
Example code:
Device (please complete the following information):
The text was updated successfully, but these errors were encountered: