不确定如何分类。我正在尝试在MacOS 10.14下从头开始构建AOSP。
我构建了区分大小写的文件系统,并执行了以下命令:
repo init -u https://android.googlesource.com/platform/manifest
repo init -b android-9.0.0_r34
repo sync
source build/envsetup.sh
lunch aosp_arm-eng
make -j4
,还编辑了build / soong / cc / config / x86_darwin_host.go,以将10.14添加到darwinSupportedSdkVersions。
构建因以下错误而失败:
ld: warning: The i386 architecture is deprecated for macOS (remove from the Xcode build setting: ARCHS)
ld: warning: ignoring file /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/usr/lib/libpthread.tbd, missing required architecture i386 in file /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/usr/lib/libpthread.tbd
ld: warning: ignoring file /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/usr/lib/libdl.tbd, missing required architecture i386 in file /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/usr/lib/libdl.tbd
…
[ 5% 4372/76415] //external/expat:libexpat link libexpat-host.dylib [darwin x86]
FAILED: out/soong/.intermediates/external/expat/libexpat/darwin_x86_shared/libexpat-host.dylib
prebuilts/clang/host/darwin-x86/clang-4691093/bin/clang++ @out/soong/.intermediates/external/expat/libexpat/darwin_x86_shared/libexpat-host.dylib.rsp out/soong/.intermediates/external/compiler-rt/libcompiler_rt-extras/darwin_x86_static/libcompiler_rt-extras.a out/soong/.intermediates/external/libcxx/libc++/darwin_x86_shared/libc++.dylib -o out/soong/.intermediates/external/expat/libexpat/darwin_x86_shared/libexpat-host.dylib -dynamiclib -single_module -install_name @rpath/libexpat-host.dylib -read_only_relocs suppress -target i686-apple-darwin -B/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk -Wl,-syslibroot,/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk -mmacosx-version-min=10.8 -m32 -ldl -lpthread -lm -Wl,-rpath,@loader_path/../lib -Wl,-rpath,@loader_path/lib -nodefaultlibs -lc -lSystem
ld: warning: The i386 architecture is deprecated for macOS (remove from the Xcode build setting: ARCHS)
ld: warning: ignoring file /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/usr/lib/libdl.tbd, missing required architecture i386 in file /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/usr/lib/libdl.tbd
ld: warning: ignoring file /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/usr/lib/libpthread.tbd, missing required architecture i386 in file /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/usr/lib/libpthread.tbd
ld: warning: ignoring file /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/usr/lib/libm.tbd, missing required architecture i386 in file /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/usr/lib/libm.tbd
ld: warning: ignoring file /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/usr/lib/libc.tbd, missing required architecture i386 in file /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/usr/lib/libc.tbd
ld: warning: ignoring file /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/usr/lib/libSystem.tbd, missing required architecture i386 in file /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.14.sdk/usr/lib/libSystem.tbd
Undefined symbols for architecture i386:
"___bzero", referenced from:
_lookup in xmlparse.o
"___stack_chk_fail", referenced from:
_XML_ParserCreateNS in xmlparse.o
_XML_ExternalEntityParserCreate in xmlparse.o
_externalEntityInitProcessor in xmlparse.o
_externalParEntInitProcessor in xmlparse.o
_startParsing in xmlparse.o
_XML_DefaultCurrent in xmlparse.o
_prologInitProcessor in xmlparse.o
...
为奥利奥(Oreo)建设也失败了,但方式不同。
知道我在做什么错吗?
答案 0 :(得分:4)
请尝试安装Xcode 9.4或更早版本,然后重新构建。 希望对您有帮助。
参考:https://developer.apple.com/documentation/xcode_release_notes/xcode_10_release_notes
macOS 10.14 SDK不再包含对32位编译的支持 应用程序。如果开发人员需要针对i386,Xcode 9.4或 需要更早。 (39858111)
答案 1 :(得分:3)
我在Android Oreo
上成功编译了macOS 10.14
。
我没有安装Xcode,仅安装了CommandLineTools
(Command_Line_Tools_macOS_10.13_for_Xcode_9.3)。 Command_Line_Tools_macOS_10.13_for_Xcode_9.3
是可以安装在CommandLineTools
上的macOS 10.14
的最低版本。
点击此处获取更多信息:https://www.jianshu.com/p/1fba826c710e