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

Cannot compile to Android due to Clang errors #279

Open
emanrdesu opened this issue Feb 23, 2020 · 10 comments
Open

Cannot compile to Android due to Clang errors #279

emanrdesu opened this issue Feb 23, 2020 · 10 comments
Labels

Comments

@emanrdesu
Copy link

emanrdesu commented Feb 23, 2020

I ran
./configure Calculator android verbose
make clean
make

and it says Clang cannot create executables
is there any way I can make it use gcc if Clang keeps not working?

Related, but how can I make it compile with android 9 - api 28, it says it switches to api 24 as a warning

@mgorges
Copy link
Contributor

mgorges commented Feb 24, 2020

We switched from GCC to Clang due GCC being phased out for Android development - see #266. It is interesting to note that you have issues with it though as we check for the tool to be present. Can you post the actual error message here or as a gist? Also what platform are you on and what version of Clang are you using?

For the unrelated question, I'd like to ask you to file a separate issue. Not all APIs are complete [can't tell if 28 is on top of my head] and thus tools have to be found by going to earlier versions - see android/host_linux#L42 or the macOS equivalent.

@emanrdesu
Copy link
Author

here's output of make: https://pastebin.com/M4qpcgS2
here's config.log: https://pastebin.com/YC551JCN
here's output of clang -v: https://pastebin.com/ujY2UxUU

I'm using Arch Linux.

@mgorges
Copy link
Contributor

mgorges commented Feb 25, 2020

The /home/gabriel/.cache/lambdanative/android-api28/android-ndk-r13b-arm-24-toolchain/bin/clang38: error while loading shared libraries: libncurses.so.5: cannot open shared object file: No such file or directory piece looks suspicious to me - is your compiler broken or not linked correctly?

@mgorges
Copy link
Contributor

mgorges commented Feb 25, 2020

Also can you build the app on your native platform?

@emanrdesu
Copy link
Author

I can build the app in linux mode yes.

@mgorges
Copy link
Contributor

mgorges commented Feb 25, 2020

Okay, but that is likely done with GCC, so something in clang is broken (as it doesn't seem linked completely according to the error reported above). - If libncurses is not installed then install it and try again?

@emanrdesu
Copy link
Author

I tried reinstalling ncurses and clang, but neither works

@mgorges
Copy link
Contributor

mgorges commented Feb 25, 2020

Not ncurses program but the library libncurses5. The other problem could be a 32bit/64bit mismatch somewhere in your system.

@emanrdesu
Copy link
Author

It seems that for Arch, libncurses comes with the ncurses
I'm installing compiling clang version 5 right now maybe will work

@mgorges
Copy link
Contributor

mgorges commented Aug 13, 2020

Your solution might be discussed here: android/ndk#574, which refers to an issue with clang assuming ncurses 5 being available, while Arch Linux only has version 6; maybe try adding ncurses5-compat-libs first?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants