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-1409] Cannot find ICU headers for Android build #44018
Comments
Sorry for the slow response! It looks like the problem is that libicuuc.so isn't being found--specifically, it can't find the headers. Does the project exist at the path you're passing into the build script, |
Yes, I even compiled the project, and replaced the "~" with the full path "/home/coleman". I will move things to another folder and try again. Thanks for looking into this. |
Hmm, weird. It's not as if the import was introduced recently, so I wonder why it's failing for you. I'm currently pulling down the latest changes and attempting the build myself (CI can't come soon enough!). In the meantime, just a sanity check: you do have a file at path $ wc -l ~/libicu-android/armeabi-v7a/icu/source/common/unicode/ustring.h |
I renamed the folder and changed the build command. Still doesnt work. I am cloning and compiling again from scratch, just to be safe. New Build command:
Sanity check:
|
I tried pulling down the latest changes from master and running a clean build of the Android stdlib, and everything worked on my end. My current theory is that there's something wrong with your libicu build, but I haven't figured out what yet. Still investigating... |
Right now I am compiling with the prebuilt libICU. But I did compile it myself too and that did not work either. I am currently compiling it again and haven't run into any issues, but its a Macbook Pro 2009 so it might take a while. |
Errored again. Building the standard library for: swift-test-stdlib-linux-x86_64 swift-test-stdlib-android-armv7 cmark: using standard linker
++ cmake_config_opt cmark
++ product=cmark
++ [[ Ninja == \X\c\o\d\e ]]
+ /usr/bin/cmake --build /home/coleman/build/Ninja-ReleaseAssert/cmark-linux-x86_64 -- -j2 all
ninja: no work to do.
llvm: using standard linker
++ cmake_config_opt llvm
++ product=llvm
++ [[ Ninja == \X\c\o\d\e ]]
+ /usr/bin/cmake --build /home/coleman/build/Ninja-ReleaseAssert/llvm-linux-x86_64 -- -j2 all
ninja: no work to do.
++ uname -s
+ [[ Linux == \D\a\r\w\i\n ]]
+ HOST_CXX_HEADERS_DIR=/usr/include/c++
+ BUILT_CXX_INCLUDE_DIR=/home/coleman/build/Ninja-ReleaseAssert/llvm-linux-x86_64/include
+ echo 'symlinking the system headers (/usr/include/c++) into the local clang build directory (/home/coleman/build/Ninja-ReleaseAssert/llvm-linux-x86_64/include).'
symlinking the system headers (/usr/include/c++) into the local clang build directory (/home/coleman/build/Ninja-ReleaseAssert/llvm-linux-x86_64/include).
+ ln -s -f /usr/include/c++ /home/coleman/build/Ninja-ReleaseAssert/llvm-linux-x86_64/include
swift: using standard linker
++ cmake_config_opt swift
++ product=swift
++ [[ Ninja == \X\c\o\d\e ]]
+ /usr/bin/cmake --build /home/coleman/build/Ninja-ReleaseAssert/swift-linux-x86_64 -- -j2 all swift-test-stdlib-linux-x86_64 swift-test-stdlib-android-armv7
[1/1] Re-running CMake...
-- Found LLVM_CONFIG as /home/coleman/build/Ninja-ReleaseAssert/llvm-linux-x86_64/bin/llvm-config
-- Building with -fPIC
-- Linux SDK:
-- Path: /
-- Version: don't use
-- Build number: don't use
-- Deployment version: don't use
-- Library subdir: linux
-- Version min name:
-- Triple name: linux
-- Architectures: x86_64
-- Triple for x86_64 is x86_64-unknown-linux-gnu
--
-- Android SDK:
-- Path: /
-- Version: don't use
-- Build number: don't use
-- Deployment version: don't use
-- Library subdir: android
-- Version min name:
-- Triple name: android
-- Architectures: armv7
-- Triple for armv7 is armv7-none-linux-androideabi
--
-- Building host Swift tools for LINUX x86_64
-- Build type: Release
-- Assertions: TRUE
-- LTO: FALSE
--
-- Building Swift standard library and SDK overlays for SDKs: LINUX;ANDROID
-- Build type: Release
-- Assertions: TRUE
--
-- Building Swift runtime with:
-- Leak Detection Checker Entrypoints: FALSE
--
-- Swift version: 3.0
-- Swift vendor:
-- Swift compiler version:
-- Embedded clang compiler version:
CMake Warning at stdlib/CMakeLists.txt:5 (message):
Building the swift runtime using the host compiler, and not the just-built
clang.
CMake Warning at docs/CMakeLists.txt:24 (message):
Unable to find sphinx-build program. Not building docs
CMake Warning at docs/CMakeLists.txt:130 (message):
LitRe not found; code examples won't be tested.
-- Configuring done
CMake Warning (dev) at cmake/modules/AddSwift.cmake:1569 (add_dependencies):
Policy CMP0046 is not set: Error on non-existent dependency in
add_dependencies. Run "cmake --help-policy CMP0046" for policy details.
Use the cmake_policy command to set the policy and suppress this warning.
The dependency target "/usr/lib/x86_64-linux-gnu/libicui18n.so-linux" of
target "swiftStdlibStubs-linux-x86_64" does not exist.
Call Stack (most recent call first):
stdlib/public/stubs/CMakeLists.txt:22 (add_swift_library)
This warning is for project developers. Use -Wno-dev to suppress it.
CMake Warning (dev) at cmake/modules/AddSwift.cmake:1569 (add_dependencies):
Policy CMP0046 is not set: Error on non-existent dependency in
add_dependencies. Run "cmake --help-policy CMP0046" for policy details.
Use the cmake_policy command to set the policy and suppress this warning.
The dependency target "/usr/lib/x86_64-linux-gnu/libicuuc.so-linux" of
target "swiftStdlibStubs-linux-x86_64" does not exist.
Call Stack (most recent call first):
stdlib/public/stubs/CMakeLists.txt:22 (add_swift_library)
This warning is for project developers. Use -Wno-dev to suppress it.
CMake Warning (dev) at cmake/modules/AddSwift.cmake:1569 (add_dependencies):
Policy CMP0046 is not set: Error on non-existent dependency in
add_dependencies. Run "cmake --help-policy CMP0046" for policy details.
Use the cmake_policy command to set the policy and suppress this warning.
The dependency target "/usr/lib/x86_64-linux-gnu/libicui18n.so-android" of
target "swiftStdlibStubs-android-armv7" does not exist.
Call Stack (most recent call first):
stdlib/public/stubs/CMakeLists.txt:22 (add_swift_library)
This warning is for project developers. Use -Wno-dev to suppress it.
CMake Warning (dev) at cmake/modules/AddSwift.cmake:1569 (add_dependencies):
Policy CMP0046 is not set: Error on non-existent dependency in
add_dependencies. Run "cmake --help-policy CMP0046" for policy details.
Use the cmake_policy command to set the policy and suppress this warning.
The dependency target "/usr/lib/x86_64-linux-gnu/libicuuc.so-android" of
target "swiftStdlibStubs-android-armv7" does not exist.
Call Stack (most recent call first):
stdlib/public/stubs/CMakeLists.txt:22 (add_swift_library)
This warning is for project developers. Use -Wno-dev to suppress it.
-- Generating done
-- Build files have been written to: /home/coleman/build/Ninja-ReleaseAssert/swift-linux-x86_64
[405/684] Building CXX object lib/SILO.../Transforms/DeadStoreElimination.cpp.o
/home/coleman/swift/lib/SILOptimizer/Transforms/DeadStoreElimination.cpp:324:19: warning: private field 'EA' is not used [-Wunused-private-field]
EscapeAnalysis *EA;
^
1 warning generated.
[470/684] Building CXX object stdlib/p...ntime-android-armv7.dir/Metadata.cpp.o
/home/coleman/swift/stdlib/public/runtime/Metadata.cpp:315:49: warning: declaration requires a global constructor [-Wglobal-constructors]
static Lazy<MetadataCache<ObjCClassCacheEntry>> ObjCClassWrappers;
^~~~~~~~~~~~~~~~~
/home/coleman/swift/stdlib/public/runtime/Metadata.cpp:381:48: warning: declaration requires a global constructor [-Wglobal-constructors]
static Lazy<MetadataCache<FunctionCacheEntry>> FunctionTypes;
^~~~~~~~~~~~~
/home/coleman/swift/stdlib/public/runtime/Metadata.cpp:532:45: warning: declaration requires a global constructor [-Wglobal-constructors]
static Lazy<MetadataCache<TupleCacheEntry>> TupleTypes;
^~~~~~~~~~
/home/coleman/swift/stdlib/public/runtime/Metadata.cpp:1804:48: warning: declaration requires a global constructor [-Wglobal-constructors]
static Lazy<MetadataCache<MetatypeCacheEntry>> MetatypeTypes;
^~~~~~~~~~~~~
/home/coleman/swift/stdlib/public/runtime/Metadata.cpp:1871:39: warning: declaration requires a global constructor [-Wglobal-constructors]
static Lazy<ExistentialMetatypeState> ExistentialMetatypes;
^~~~~~~~~~~~~~~~~~~~
/home/coleman/swift/stdlib/public/runtime/Metadata.cpp:1996:35: warning: declaration requires a global constructor [-Wglobal-constructors]
static Lazy<ExistentialTypeState> Existentials;
^~~~~~~~~~~~
/home/coleman/swift/stdlib/public/runtime/Metadata.cpp:2410:31: warning: declaration requires a global constructor [-Wglobal-constructors]
static Lazy<ForeignTypeState> ForeignTypes;
^~~~~~~~~~~~
7 warnings generated.
[471/684] Building CXX object stdlib/p...ime-android-armv7.dir/HeapObject.cpp.o
/home/coleman/swift/stdlib/public/runtime/HeapObject.cpp:228:43: warning: declaration requires a global constructor [-Wglobal-constructors]
static Lazy<MetadataCache<BoxCacheEntry>> Boxes;
^~~~~
1 warning generated.
[473/684] Building CXX object stdlib/p...android-armv7.dir/MetadataLookup.cpp.o
/home/coleman/swift/stdlib/public/runtime/MetadataLookup.cpp:125:32: warning: declaration requires a global constructor [-Wglobal-constructors]
static Lazy<TypeMetadataState> TypeMetadataRecords;
^~~~~~~~~~~~~~~~~~~
1 warning generated.
[478/684] Building CXX object stdlib/p...id-armv7.dir/ProtocolConformance.cpp.o
/home/coleman/swift/stdlib/public/runtime/ProtocolConformance.cpp:287:31: warning: declaration requires a global constructor [-Wglobal-constructors]
static Lazy<ConformanceState> Conformances;
^~~~~~~~~~~~
1 warning generated.
[489/684] Building CXX object stdlib/p...time-linux-x86_64.dir/HeapObject.cpp.o
/home/coleman/swift/stdlib/public/runtime/HeapObject.cpp:228:43: warning: declaration requires a global constructor [-Wglobal-constructors]
static Lazy<MetadataCache<BoxCacheEntry>> Boxes;
^~~~~
1 warning generated.
[491/684] Building CXX object stdlib/p...-linux-x86_64.dir/MetadataLookup.cpp.o
/home/coleman/swift/stdlib/public/runtime/MetadataLookup.cpp:125:32: warning: declaration requires a global constructor [-Wglobal-constructors]
static Lazy<TypeMetadataState> TypeMetadataRecords;
^~~~~~~~~~~~~~~~~~~
1 warning generated.
[495/684] Building CXX object stdlib/p...untime-linux-x86_64.dir/Metadata.cpp.o
/home/coleman/swift/stdlib/public/runtime/Metadata.cpp:315:49: warning: declaration requires a global constructor [-Wglobal-constructors]
static Lazy<MetadataCache<ObjCClassCacheEntry>> ObjCClassWrappers;
^~~~~~~~~~~~~~~~~
/home/coleman/swift/stdlib/public/runtime/Metadata.cpp:381:48: warning: declaration requires a global constructor [-Wglobal-constructors]
static Lazy<MetadataCache<FunctionCacheEntry>> FunctionTypes;
^~~~~~~~~~~~~
/home/coleman/swift/stdlib/public/runtime/Metadata.cpp:532:45: warning: declaration requires a global constructor [-Wglobal-constructors]
static Lazy<MetadataCache<TupleCacheEntry>> TupleTypes;
^~~~~~~~~~
/home/coleman/swift/stdlib/public/runtime/Metadata.cpp:1804:48: warning: declaration requires a global constructor [-Wglobal-constructors]
static Lazy<MetadataCache<MetatypeCacheEntry>> MetatypeTypes;
^~~~~~~~~~~~~
/home/coleman/swift/stdlib/public/runtime/Metadata.cpp:1871:39: warning: declaration requires a global constructor [-Wglobal-constructors]
static Lazy<ExistentialMetatypeState> ExistentialMetatypes;
^~~~~~~~~~~~~~~~~~~~
/home/coleman/swift/stdlib/public/runtime/Metadata.cpp:1996:35: warning: declaration requires a global constructor [-Wglobal-constructors]
static Lazy<ExistentialTypeState> Existentials;
^~~~~~~~~~~~
/home/coleman/swift/stdlib/public/runtime/Metadata.cpp:2410:31: warning: declaration requires a global constructor [-Wglobal-constructors]
static Lazy<ForeignTypeState> ForeignTypes;
^~~~~~~~~~~~
7 warnings generated.
[496/684] Building CXX object stdlib/p...x-x86_64.dir/ProtocolConformance.cpp.o
/home/coleman/swift/stdlib/public/runtime/ProtocolConformance.cpp:287:31: warning: declaration requires a global constructor [-Wglobal-constructors]
static Lazy<ConformanceState> Conformances;
^~~~~~~~~~~~
1 warning generated.
[517/684] Building CXX object stdlib/p...d-armv7.dir/UnicodeNormalization.cpp.o
FAILED: /usr/bin/clang++ -DGTEST_HAS_RTTI=0 -D_DEBUG -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D__STDC_LIMIT_MACROS -fno-stack-protector -fPIC -fvisibility-inlines-hidden -Wall -W -Wno-unused-parameter -Wwrite-strings -Wcast-qual -Wmissing-field-initializers -Wcovered-switch-default -Wnon-virtual-dtor -Wdelete-non-virtual-dtor -Werror=date-time -std=c++11 -fcolor-diagnostics -ffunction-sections -fdata-sections -Wdocumentation -Wimplicit-fallthrough -Wunreachable-code -Woverloaded-virtual -O3 -Istdlib/public/stubs -I/home/coleman/swift/stdlib/public/stubs -I/home/coleman/swift/include -Iinclude -I/home/coleman/build/Ninja-ReleaseAssert/llvm-linux-x86_64/include -I/home/coleman/llvm/include -I/home/coleman/build/Ninja-ReleaseAssert/llvm-linux-x86_64/tools/clang/include -I/home/coleman/llvm/tools/clang/include -I/home/coleman/cmark/src -I/home/coleman/build/Ninja-ReleaseAssert/cmark-linux-x86_64/src -I/home/coleman/libicu-android/armeabi-v7a/icu/source/common -I/home/coleman/libicu-android/armeabi-v7a/icu/source/i18n -UNDEBUG -fno-exceptions -fno-rtti -Wglobal-constructors -Wexit-time-destructors -fvisibility=hidden -target armv7-none-linux-androideabi -isysroot /home/coleman/android-ndk-r11c/platforms/android-21/arch-arm --sysroot=/home/coleman/android-ndk-r11c/platforms/android-21/arch-arm -B /home/coleman/android-ndk-r11c/toolchains/arm-linux-androideabi-4.9/prebuilt/linux-x86_64/arm-linux-androideabi/bin/ -O2 -g0 -UNDEBUG -I/home/coleman/android-ndk-r11c/sources/cxx-stl/llvm-libc++/libcxx/include -I/home/coleman/android-ndk-r11c/sources/cxx-stl/llvm-libc++abi/libcxxabi/include -I/home/coleman/android-ndk-r11c/sources/android/support/include -MMD -MT stdlib/public/stubs/CMakeFiles/swiftStdlibStubs-android-armv7.dir/UnicodeNormalization.cpp.o -MF stdlib/public/stubs/CMakeFiles/swiftStdlibStubs-android-armv7.dir/UnicodeNormalization.cpp.o.d -o stdlib/public/stubs/CMakeFiles/swiftStdlibStubs-android-armv7.dir/UnicodeNormalization.cpp.o -c /home/coleman/swift/stdlib/public/stubs/UnicodeNormalization.cpp
/home/coleman/swift/stdlib/public/stubs/UnicodeNormalization.cpp:24:10: fatal error: 'unicode/ustring.h' file not found
#include <unicode/ustring.h>
^
1 error generated.
[517/684] Building CXX object stdlib/p...s-linux-x86_64.dir/GlobalObjects.cpp.o
ninja: build stopped: subcommand failed.
./utils/build-script: command terminated with a non-zero exit status 1, aborting |
> its a Macbook Pro 2009 so it might take a while. Yes, I was wondering--based on the build output, it seems like you're only using 2 cores. You're capable of building Swift normally, yes? As in, simply |
Yes, no errors there. I already built it for Ubuntu 15.10 x86_64. |
Looking at the compilation command that is failing, I can clearly see that you're passing First off, try invoking the build script again, but this time blowing away any cached CMake values you might have by using $ utils/build-script -R --android --android-ndk ~/android-ndk-r11c --android-api-level 21 --android-icu-uc ~/libicu-android/armeabi-v7a --android-icu-uc-include ~/libicu-android/armeabi-v7a/icu/source/common --android-icu-i18n ~/libicu-android/armeabi-v7a --android-icu-i18n-include ~/libicu-android/armeabi-v7a/icu/source/i18n -- --reconfigure Make sure to change the paths to libicu in the invocation above to where they are on your machine. Double-check that they exist at the paths specified. Second off, when posting build logs, please either upload a text file or surround the output in {code} {code} tags. That ensures JIRA formats it properly. Third, if you encounter a build error again, even after using /usr/bin/clang++ -DGTEST_HAS_RTTI=0 -D_DEBUG -D_STDC_CONSTANT_MACROS -DSTDC_FORMAT_MACROS -D_STDC_LIMIT_MACROS -fno-stack-protector -fPIC -fvisibility-inlines-hidden -Wall -W -Wno-unused-parameter -Wwrite-strings -Wcast-qual -Wmissing-field-initializers -Wcovered-switch-default -Wnon-virtual-dtor -Wdelete-non-virtual-dtor -Werror=date-time -std=c+11 -fcolor-diagnostics -ffunction-sections -fdata-sections -Wdocumentation -Wimplicit-fallthrough -Wunreachable-code -Woverloaded-virtual -O3 -Istdlib/public/stubs -I/home/coleman/swift/stdlib/public/stubs -I/home/coleman/swift/include -Iinclude -I/home/coleman/build/Ninja-ReleaseAssert/llvm-linux-x86_64/include -I/home/coleman/llvm/include -I/home/coleman/build/Ninja-ReleaseAssert/llvm-linux-x86_64/tools/clang/include -I/home/coleman/llvm/tools/clang/include -I/home/coleman/cmark/src -I/home/coleman/build/Ninja-ReleaseAssert/cmark-linux-x86_64/src -I/home/coleman/libicu-android/armeabi-v7a/icu/source/common -I/home/coleman/libicu-android/armeabi-v7a/icu/source/i18n -UNDEBUG -fno-exceptions -fno-rtti -Wglobal-constructors -Wexit-time-destructors -fvisibility=hidden -target armv7-none-linux-androideabi -isysroot /home/coleman/android-ndk-r11c/platforms/android-21/arch-arm --sysroot=/home/coleman/android-ndk-r11c/platforms/android-21/arch-arm -B /home/coleman/android-ndk-r11c/toolchains/arm-linux-androideabi-4.9/prebuilt/linux-x86_64/arm-linux-androideabi/bin/ -O2 -g0 -UNDEBUG -I/home/coleman/android-ndk-r11c/sources/cxx-stl/llvm-libc/libcxx/include -I/home/coleman/android-ndk-r11c/sources/cxx-stl/llvm-libc+abi/libcxxabi/include -I/home/coleman/android-ndk-r11c/sources/android/support/include -MMD -MT stdlib/public/stubs/CMakeFiles/swiftStdlibStubs-android-armv7.dir/UnicodeNormalization.cpp.o -MF stdlib/public/stubs/CMakeFiles/swiftStdlibStubs-android-armv7.dir/UnicodeNormalization.cpp.o.d -o stdlib/public/stubs/CMakeFiles/swiftStdlibStubs-android-armv7.dir/UnicodeNormalization.cpp.o -c /home/coleman/swift/stdlib/public/stubs/UnicodeNormalization.cpp If you encounter a build error, try copy-pasting the failed command and re-running it yourself. |
@modocache I created a Virtual Box instance of Ubuntu 15.10 and tried everything again, from scratch, and now I get this error.
The long version: coleman@coleman-ubuntu-VirtualBox:~/swiftandroid/swift$ ./utils/build-script -R --android --android-ndk ~/swiftandroid/android-ndk-r11c --android-api-level 21 --android-icu-uc ~/swiftandroid/libiconv-libicu-android/armeabi-v7a --android-icu-uc-include ~/swiftandroid/libiconv-libicu-android/armeabi-v7a/icu/source/common --android-icu-i18n ~/swiftandroid/libiconv-libicu-android/armeabi-v7a --android-icu-i18n-include ~/swiftandroid/libiconv-libicu-android/armeabi-v7a/icu/source/i18n --reconfigure
Building the standard library for: swift-test-stdlib-linux-x86_64 swift-test-stdlib-android-armv7
cmark: using standard linker
+ mkdir -p /home/coleman/swiftandroid/build/Ninja-ReleaseAssert/cmark-linux-x86_64
+ cd /home/coleman/swiftandroid/build/Ninja-ReleaseAssert/cmark-linux-x86_64
+ /usr/bin/cmake -G Ninja -DCMAKE_C_COMPILER:PATH=/usr/bin/clang -DCMAKE_CXX_COMPILER:PATH=/usr/bin/clang++ -DCMAKE_BUILD_TYPE:STRING=Release /home/coleman/swiftandroid/cmark
-- Configuring done
-- Generating done
-- Build files have been written to: /home/coleman/swiftandroid/build/Ninja-ReleaseAssert/cmark-linux-x86_64
++ cmake_config_opt cmark
++ product=cmark
++ [[ Ninja == \X\c\o\d\e ]]
+ /usr/bin/cmake --build /home/coleman/swiftandroid/build/Ninja-ReleaseAssert/cmark-linux-x86_64 -- -j1 all
ninja: no work to do.
llvm: using standard linker
+ mkdir -p /home/coleman/swiftandroid/build/Ninja-ReleaseAssert/llvm-linux-x86_64
+ cd /home/coleman/swiftandroid/build/Ninja-ReleaseAssert/llvm-linux-x86_64
+ /usr/bin/cmake -G Ninja -DCMAKE_C_COMPILER:PATH=/usr/bin/clang -DCMAKE_CXX_COMPILER:PATH=/usr/bin/clang++ '-DCMAKE_C_FLAGS= -fno-stack-protector -gline-tables-only' '-DCMAKE_CXX_FLAGS= -fno-stack-protector -gline-tables-only' -DCMAKE_BUILD_TYPE:STRING=Release -DLLVM_ENABLE_ASSERTIONS:BOOL=TRUE -DLLVM_TOOL_SWIFT_BUILD:BOOL=NO '-DLLVM_TARGETS_TO_BUILD=X86;ARM;AArch64;PowerPC' -DLLVM_INCLUDE_TESTS:BOOL=TRUE -DLLVM_INCLUDE_DOCS:BOOL=TRUE -DLLVM_ENABLE_LTO=FALSE -DCMAKE_INSTALL_PREFIX:PATH=/usr -DINTERNAL_INSTALL_PREFIX=local /home/coleman/swiftandroid/llvm
-- Target triple: x86_64-unknown-linux-gnu
-- Native target architecture is X86
-- Threads enabled.
-- Doxygen disabled.
-- Sphinx disabled.
-- Go bindings disabled.
-- Could NOT find OCaml (missing: OCAMLFIND OCAML_VERSION OCAML_STDLIB_PATH)
-- Could NOT find OCaml (missing: OCAMLFIND OCAML_VERSION OCAML_STDLIB_PATH)
-- OCaml bindings disabled.
-- Building with -fPIC
-- Constructing LLVMBuild project information
-- Targeting X86
-- Targeting ARM
-- Targeting AArch64
-- Targeting PowerPC
-- Compiler-RT supported architectures: x86_64
-- Clang version: 3.9.0
-- Configuring done
-- Generating done
-- Build files have been written to: /home/coleman/swiftandroid/build/Ninja-ReleaseAssert/llvm-linux-x86_64
++ cmake_config_opt llvm
++ product=llvm
++ [[ Ninja == \X\c\o\d\e ]]
+ /usr/bin/cmake --build /home/coleman/swiftandroid/build/Ninja-ReleaseAssert/llvm-linux-x86_64 -- -j1 all
[2/2] Linking CXX shared library lib/c...0/lib/linux/libclang_rt.asan-x86_64.so
++ uname -s
+ [[ Linux == \D\a\r\w\i\n ]]
+ HOST_CXX_HEADERS_DIR=/usr/include/c++
+ BUILT_CXX_INCLUDE_DIR=/home/coleman/swiftandroid/build/Ninja-ReleaseAssert/llvm-linux-x86_64/include
+ echo 'symlinking the system headers (/usr/include/c++) into the local clang build directory (/home/coleman/swiftandroid/build/Ninja-ReleaseAssert/llvm-linux-x86_64/include).'
symlinking the system headers (/usr/include/c++) into the local clang build directory (/home/coleman/swiftandroid/build/Ninja-ReleaseAssert/llvm-linux-x86_64/include).
+ ln -s -f /usr/include/c++ /home/coleman/swiftandroid/build/Ninja-ReleaseAssert/llvm-linux-x86_64/include
swift: using standard linker
+ mkdir -p /home/coleman/swiftandroid/build/Ninja-ReleaseAssert/swift-linux-x86_64
+ cd /home/coleman/swiftandroid/build/Ninja-ReleaseAssert/swift-linux-x86_64
+ /usr/bin/cmake -G Ninja -DCMAKE_C_COMPILER:PATH=/usr/bin/clang -DCMAKE_CXX_COMPILER:PATH=/usr/bin/clang++ -DSWIFT_ANDROID_NDK_PATH:STRING=/home/coleman/swiftandroid/android-ndk-r11c -DSWIFT_ANDROID_NDK_GCC_VERSION:STRING=4.9 -DSWIFT_ANDROID_SDK_PATH:STRING=/home/coleman/swiftandroid/android-ndk-r11c/platforms/android-21/arch-arm -DSWIFT_ANDROID_ICU_UC:STRING=/home/coleman/swiftandroid/libiconv-libicu-android/armeabi-v7a -DSWIFT_ANDROID_ICU_UC_INCLUDE:STRING=/home/coleman/swiftandroid/libiconv-libicu-android/armeabi-v7a/icu/source/common -DSWIFT_ANDROID_ICU_I18N:STRING=/home/coleman/swiftandroid/libiconv-libicu-android/armeabi-v7a -DSWIFT_ANDROID_ICU_I18N_INCLUDE:STRING=/home/coleman/swiftandroid/libiconv-libicu-android/armeabi-v7a/icu/source/i18n '-DCMAKE_C_FLAGS= -fno-stack-protector' '-DCMAKE_CXX_FLAGS= -fno-stack-protector' -DCMAKE_BUILD_TYPE:STRING=Release -DLLVM_ENABLE_ASSERTIONS:BOOL=TRUE -DLLVM_ENABLE_LTO=FALSE -DSWIFT_ANALYZE_CODE_COVERAGE:STRING=FALSE -DSWIFT_STDLIB_BUILD_TYPE:STRING=Release -DSWIFT_STDLIB_ASSERTIONS:BOOL=TRUE -DSWIFT_STDLIB_ENABLE_REFLECTION_METADATA:BOOL=TRUE -DSWIFT_STDLIB_ENABLE_REFLECTION_NAMES:BOOL=FALSE -DSWIFT_STDLIB_ENABLE_RESILIENCE:BOOL=FALSE -DSWIFT_STDLIB_SIL_SERIALIZE_ALL:BOOL=TRUE -DSWIFT_NATIVE_LLVM_TOOLS_PATH:STRING= -DSWIFT_NATIVE_CLANG_TOOLS_PATH:STRING= -DSWIFT_NATIVE_SWIFT_TOOLS_PATH:STRING= -DSWIFT_BUILD_TOOLS:BOOL=TRUE -DSWIFT_BUILD_STDLIB:BOOL=TRUE -DSWIFT_SERIALIZE_STDLIB_UNITTEST:BOOL=FALSE -DSWIFT_STDLIB_SIL_DEBUGGING:BOOL=FALSE -DSWIFT_BUILD_SDK_OVERLAY:BOOL=TRUE -DSWIFT_BUILD_STATIC_STDLIB:BOOL=FALSE -DSWIFT_BUILD_PERF_TESTSUITE:BOOL=TRUE -DSWIFT_BUILD_EXAMPLES:BOOL=TRUE -DSWIFT_INCLUDE_TESTS:BOOL=TRUE -DSWIFT_INSTALL_COMPONENTS:STRING= -DSWIFT_EMBED_BITCODE_SECTION:BOOL=FALSE -DSWIFT_ENABLE_LTO:BOOL=FALSE -DSWIFT_BUILD_RUNTIME_WITH_HOST_COMPILER:BOOL=TRUE -DSWIFT_DARWIN_XCRUN_TOOLCHAIN:STRING=default -DSWIFT_AST_VERIFIER:BOOL=TRUE -DSWIFT_SIL_VERIFY_ALL:BOOL=FALSE -DSWIFT_RUNTIME_ENABLE_LEAK_CHECKER:BOOL=FALSE -DCMAKE_INSTALL_PREFIX:PATH=/usr -DLLVM_CONFIG:PATH=/home/coleman/swiftandroid/build/Ninja-ReleaseAssert/llvm-linux-x86_64/bin/llvm-config -DSWIFT_PATH_TO_CLANG_SOURCE:PATH=/home/coleman/swiftandroid/llvm/tools/clang -DSWIFT_PATH_TO_CLANG_BUILD:PATH=/home/coleman/swiftandroid/build/Ninja-ReleaseAssert/llvm-linux-x86_64 -DSWIFT_PATH_TO_LLVM_SOURCE:PATH=/home/coleman/swiftandroid/llvm -DSWIFT_PATH_TO_LLVM_BUILD:PATH=/home/coleman/swiftandroid/build/Ninja-ReleaseAssert/llvm-linux-x86_64 -DSWIFT_PATH_TO_CMARK_SOURCE:PATH=/home/coleman/swiftandroid/cmark -DSWIFT_PATH_TO_CMARK_BUILD:PATH=/home/coleman/swiftandroid/build/Ninja-ReleaseAssert/cmark-linux-x86_64 -DSWIFT_CMARK_LIBRARY_DIR:PATH=/home/coleman/swiftandroid/build/Ninja-ReleaseAssert/cmark-linux-x86_64/src -DSWIFT_EXEC:STRING=/home/coleman/swiftandroid/build/Ninja-ReleaseAssert/swift-macosx-x86_64/bin/swiftc /home/coleman/swiftandroid/swift
-- Found LLVM_CONFIG as /home/coleman/swiftandroid/build/Ninja-ReleaseAssert/llvm-linux-x86_64/bin/llvm-config
-- Building with -fPIC
-- Linux SDK:
-- Path: /
-- Version: don't use
-- Build number: don't use
-- Deployment version: don't use
-- Library subdir: linux
-- Version min name:
-- Triple name: linux
-- Architectures: x86_64
-- Triple for x86_64 is x86_64-unknown-linux-gnu
--
-- Android SDK:
-- Path: /
-- Version: don't use
-- Build number: don't use
-- Deployment version: don't use
-- Library subdir: android
-- Version min name:
-- Triple name: android
-- Architectures: armv7
-- Triple for armv7 is armv7-none-linux-androideabi
--
-- Building host Swift tools for LINUX x86_64
-- Build type: Release
-- Assertions: TRUE
-- LTO: FALSE
--
-- Building Swift standard library and SDK overlays for SDKs: LINUX;ANDROID
-- Build type: Release
-- Assertions: TRUE
--
-- Building Swift runtime with:
-- Leak Detection Checker Entrypoints: FALSE
--
-- Swift version: 3.0
-- Swift vendor:
-- Swift compiler version:
-- Embedded clang compiler version:
CMake Warning at stdlib/CMakeLists.txt:5 (message):
Building the swift runtime using the host compiler, and not the just-built
clang.
CMake Warning at docs/CMakeLists.txt:24 (message):
Unable to find sphinx-build program. Not building docs
CMake Warning at docs/CMakeLists.txt:130 (message):
LitRe not found; code examples won't be tested.
-- Configuring done
CMake Warning (dev) at cmake/modules/AddSwift.cmake:1174 (add_dependencies):
Policy CMP0046 is not set: Error on non-existent dependency in
add_dependencies. Run "cmake --help-policy CMP0046" for policy details.
Use the cmake_policy command to set the policy and suppress this warning.
The dependency target "/usr/lib/x86_64-linux-gnu/libicui18n.so-linux" of
target "swiftStdlibStubs-linux-x86_64" does not exist.
Call Stack (most recent call first):
stdlib/public/stubs/CMakeLists.txt:22 (add_swift_library)
This warning is for project developers. Use -Wno-dev to suppress it.
CMake Warning (dev) at cmake/modules/AddSwift.cmake:1174 (add_dependencies):
Policy CMP0046 is not set: Error on non-existent dependency in
add_dependencies. Run "cmake --help-policy CMP0046" for policy details.
Use the cmake_policy command to set the policy and suppress this warning.
The dependency target "/usr/lib/x86_64-linux-gnu/libicuuc.so-linux" of
target "swiftStdlibStubs-linux-x86_64" does not exist.
Call Stack (most recent call first):
stdlib/public/stubs/CMakeLists.txt:22 (add_swift_library)
This warning is for project developers. Use -Wno-dev to suppress it.
CMake Warning (dev) at cmake/modules/AddSwift.cmake:1174 (add_dependencies):
Policy CMP0046 is not set: Error on non-existent dependency in
add_dependencies. Run "cmake --help-policy CMP0046" for policy details.
Use the cmake_policy command to set the policy and suppress this warning.
The dependency target "/usr/lib/x86_64-linux-gnu/libicui18n.so-android" of
target "swiftStdlibStubs-android-armv7" does not exist.
Call Stack (most recent call first):
stdlib/public/stubs/CMakeLists.txt:22 (add_swift_library)
This warning is for project developers. Use -Wno-dev to suppress it.
CMake Warning (dev) at cmake/modules/AddSwift.cmake:1174 (add_dependencies):
Policy CMP0046 is not set: Error on non-existent dependency in
add_dependencies. Run "cmake --help-policy CMP0046" for policy details.
Use the cmake_policy command to set the policy and suppress this warning.
The dependency target "/usr/lib/x86_64-linux-gnu/libicuuc.so-android" of
target "swiftStdlibStubs-android-armv7" does not exist.
Call Stack (most recent call first):
stdlib/public/stubs/CMakeLists.txt:22 (add_swift_library)
This warning is for project developers. Use -Wno-dev to suppress it.
-- Generating done
-- Build files have been written to: /home/coleman/swiftandroid/build/Ninja-ReleaseAssert/swift-linux-x86_64
++ cmake_config_opt swift
++ product=swift
++ [[ Ninja == \X\c\o\d\e ]]
+ /usr/bin/cmake --build /home/coleman/swiftandroid/build/Ninja-ReleaseAssert/swift-linux-x86_64 -- -j1 all swift-test-stdlib-linux-x86_64 swift-test-stdlib-android-armv7
[2/59] Compiling /home/coleman/swiftan...b/public/Platform/linux/x86_64/Glibc.o
FAILED: cd /home/coleman/swiftandroid/build/Ninja-ReleaseAssert/swift-linux-x86_64/stdlib/public/Platform && /usr/bin/cmake -E make_directory /home/coleman/swiftandroid/build/Ninja-ReleaseAssert/swift-linux-x86_64/stdlib/public/Platform/linux/x86_64 && /usr/bin/cmake -E make_directory /home/coleman/swiftandroid/build/Ninja-ReleaseAssert/swift-linux-x86_64/./lib/swift/linux/x86_64 && /home/coleman/swiftandroid/swift/utils/line-directive /home/coleman/swiftandroid/swift/stdlib/public/Platform/Glibc.swift /home/coleman/swiftandroid/swift/stdlib/public/Platform/Platform.swift /home/coleman/swiftandroid/build/Ninja-ReleaseAssert/swift-linux-x86_64/stdlib/public/Platform/8/tgmath.swift -- /home/coleman/swiftandroid/build/Ninja-ReleaseAssert/swift-linux-x86_64/./bin/swiftc -c -sdk / -target x86_64-unknown-linux-gnu -O -D INTERNAL_CHECKS_ENABLED -I /home/coleman/swiftandroid/build/Ninja-ReleaseAssert/swift-linux-x86_64/./lib/swift/linux/x86_64 -module-cache-path /home/coleman/swiftandroid/build/Ninja-ReleaseAssert/swift-linux-x86_64/./module-cache -no-link-objc-runtime -Xfrontend -enable-reflection-metadata -autolink-force-load -module-link-name swiftGlibc -force-single-frontend-invocation -parse-as-library -emit-module -emit-module-path /home/coleman/swiftandroid/build/Ninja-ReleaseAssert/swift-linux-x86_64/./lib/swift/linux/x86_64/Glibc.swiftmodule -o /home/coleman/swiftandroid/build/Ninja-ReleaseAssert/swift-linux-x86_64/stdlib/public/Platform/linux/x86_64/Glibc.o /home/coleman/swiftandroid/swift/stdlib/public/Platform/Glibc.swift /home/coleman/swiftandroid/swift/stdlib/public/Platform/Platform.swift /home/coleman/swiftandroid/build/Ninja-ReleaseAssert/swift-linux-x86_64/stdlib/public/Platform/8/tgmath.swift
/home/coleman/swiftandroid/swift/stdlib/public/Platform/Glibc.swift:13:19: error: no such module 'SwiftGlibc'
@_exported import SwiftGlibc // Clang module
^
ninja: build stopped: subcommand failed.
./utils/build-script: command terminated with a non-zero exit status 1, aborting |
The libicu dependency for the stdlib was just dropped, so not a problem anymore? |
Environment
Ubuntu 15.10 x86_64, Macbook Pro 5,5 (Not VM)
Additional Detail from JIRA
md5: f46de962380b729a1479852bbb931adb
Issue Description:
I get
fatal error: 'unicode/ustring.h' file not found
when compiling for Android. I have downloaded the prebuilt ICU binaries, as well as compiled them myself, and it makes no difference. As you can see from the build command below, I put all my dependencies in my home folder to make the compilation simple.The text was updated successfully, but these errors were encountered: