This topic created in 2897 days ago, the information mentioned may be changed or developed.
如题,我们用 Pods 管理第三方库,经测试,高德的 AMap2DMap 和 AMap3DMap 都有此问题。高德接下来应该很快会=有解决方案,在此之前,我们可以手动修改 Pods-project.debug.xcconfig 文件,将“-l"stdc++.6.0.9"”删除。
Apple 多年前就把系统中的 libstdc++替换成为 LLVM 优化过的 libc++了,之前 MacOS 和 iOS 为了兼容性一直还是保留了 libstdc++可以给第三方 app 用,WatchOS 和 TvOS 都直接移除了。目前看来从 iOS 12 开始很可能也完全移除了对 libstdc++的支持,App 的代码需要在编译时链接到 libc++上
1 replies • 2018-06-08 20:03:03 +08:00
 |
|
1
6du Jun 8, 2018 1
来自高德开放平台的答复 2018/06/08 您好, 非常抱歉,我们已经注意到这个问题,这个问题因为 xcode10 去掉了 stdC++库导致,但因为 cocoapods 不允许修改已经发出的 podspec,所以目前只有临时去解决这个问题,您可以在您的 Podfile 文件中增加下面的代码,以便去掉 stdc++.6.0.9 的引用: post_install do |installer| installer.pods_project.targets.each do |target| target.build_configurations.each do |config| puts config.build_settings xcconfig_path = config.base_configuration_reference.real_path build_settings = Hash[*File.read(xcconfig_path).lines.map{|x| x.split(/\s*=\s*/, 2)}.flatten] build_settings['OTHER_LDFLAGS'][' -l"stdc++.6.0.9"'] = '' File.open(xcconfig_path, "w") do |file| build_settings.each do |key,value| file.puts "#{key} = #{value}" end end end end end 感谢您的致信,欢迎持续关注高德开放平台!
|