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

[SR-1321] Swift Android libicuuc link step fails on Ubuntu 14.04 #43929

Closed
modocache mannequin opened this issue Apr 26, 2016 · 5 comments
Closed

[SR-1321] Swift Android libicuuc link step fails on Ubuntu 14.04 #43929

modocache mannequin opened this issue Apr 26, 2016 · 5 comments

Comments

@modocache
Copy link
Mannequin

modocache mannequin commented Apr 26, 2016

Previous ID SR-1321
Radar None
Original Reporter @modocache
Type Bug
Status Closed
Resolution Done
Additional Detail from JIRA
Votes 2
Component/s Project Infrastructure
Labels Bug, Android
Assignee None
Priority Medium

md5: 247b52d62689a7e64516ee64bce2f123

Issue Description:

Originally reported in https://bugs.swift.org/browse/SR-1264, apparently the instructions in docs/Android.md only work on Ubuntu 15.10, not Ubuntu 14.04.

Here's the log from a failure on Ubuntu 14.04: https://bugs.swift.org/secure/attachment/10727/10727_swift-build-1461233286.log

@modocache
Copy link
Mannequin Author

modocache mannequin commented Apr 26, 2016

I set up an Ubuntu 14.04 environment. I was able to build Swift, but building the stdlib for Android failed, producing the exact same errors as in the log above.

What could be the difference between 14.04 and 15.10 that's causing this error...? And is the problem in Swift itself, or in our libicu dependency? I'll need to investigate further.

@swift-ci
Copy link
Collaborator

swift-ci commented May 4, 2016

Comment by Adrian Blakij (JIRA)

I have the same issue on a last openSUSE Tumbleweed.

/Applications/Android/SDK/ndk-bundle/toolchains/arm-linux-androideabi-4.9/prebuilt/linux-x86_64/arm-linux-androideabi/bin/ld: error: cannot find -licuuc
/Applications/Android/SDK/ndk-bundle/toolchains/arm-linux-androideabi-4.9/prebuilt/linux-x86_64/arm-linux-androideabi/bin/ld: error: cannot find -licui18n

@gonzalolarralde
Copy link
Contributor

gonzalolarralde commented Dec 31, 2016

This is the call to the build script in the logs associated to this ticket:

./swift/utils/build-script \
-R \
--android \
--android-ndk /vagrant/android-sdk-linux/ndk-bundle \
--android-api-level 21 \
--android-icu-uc /vagrant/libiconv-libicu-android/armeabi-v7a/libicuuc.so \
--android-icu-uc-include /vagrant/libiconv-libicu-android/armeabi-v7a/icu/source/common \
--android-icu-i18n /vagrant/libiconv-libicu-android/armeabi-v7a/libicui18n.so \
--android-icu-i18n-include /vagrant/libiconv-libicu-android/armeabi-v7a/icu/source/i18n/ \
--android-ndk-gcc-version 4.9

for both icu-uc and icu-i18n the path to the so file instead of the directory location is being passed. That is causing this two library search paths being added to the compilation call:

-L/vagrant/libiconv-libicu-android/armeabi-v7a/libicuuc.so -L/vagrant/libiconv-libicu-android/armeabi-v7a/libicui18n.so

Replacing the path of the file for the directory containing the files should fix this issue. Could you please confirm?

Thanks!

@buttaface
Copy link
Contributor

buttaface commented Jan 8, 2021

@drodriguez, this can be closed now?

@drodriguez
Copy link
Collaborator

drodriguez commented Jan 8, 2021

Yes, at some point maybe --android-icu-uc was used as a search path incorrectly, but this days it seems to correctly be used as a full path, or extracting the directory path to use as a library search path.

If anyone is still experiencing this, please reopen or create a new bug with updated reproduction steps and logs.

@swift-ci swift-ci transferred this issue from apple/swift-issues Apr 25, 2022
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants