MeetYouDevs / cocoapods-imy-bin

1.05k stars 245 forks source link

组件spec push失败 . #81

Closed miroda closed 3 years ago

miroda commented 3 years ago

[!] ====== cocoapods-imy-bin 0.3.0.11 版本 ========

[!] ====== dev 环境 ========

[!] Your project does not explicitly specify the CocoaPods master specs repo. Since CDN is now used as the default, you may safely remove it from your repos directory via pod repo remove master. To suppress this warning please add warn_for_unused_master_specs_repo => false to your Podfile.

[!] 【CCBin | 1】组件spec push失败 .

miroda commented 3 years ago

Building static Library CCBin (1) Building ios libraries with archs ["arm64", "armv7"] lipo -create -output ios/CCBin.framework/Versions/A/CCBin build-arm64/libCCBin.a build-armv7/libCCBin.a build-x86_64/libCCBin.a fatal error: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/lipo: can't open input file: build-arm64/libCCBin.a (No such file or directory)

dabing1022 commented 3 years ago

个人的理解:基于官方Cocoapods模版创建的项目目录结构目前并不适合使用imy-bin。 按照imy-bin的打包思路,更倾向于首先将CCBin源码推到私有源里面。 然后按照demo的思路,一个目录下使用podspec中指明 s.dependency 'CCBin', '0.1.0' 类似,带上Podfile,执行pod bin auto --all-make。壳工程一般情况下会加入到编译二进制的白名单中。

miroda commented 3 years ago

企业微信20210112-101318

miroda commented 3 years ago

temp中ccbin,主工程编译出来只有fmdb的静态库,这是什么情况

dabing1022 commented 3 years ago

可以发下你的podspec、podfile、podfile_local的内容,问题应该出在那里

miroda commented 3 years ago

`# MARK: converted automatically by spec.py. @hgy

Pod::Spec.new do |s| s.name = 'CCBin' s.version = '1' s.description = '我只是一个测试的,主要是想要 s.dependency' s.license = 'MIT' s.summary = 'Seeyou' s.homepage = 'https://github.com/meiyoudev/IMYPublic' s.authors = { 'suliangjin' => 'suliangjin@xiaoyouzi.com' } s.source = { :git => 'http://gitlab.ops.aixuexi.com/hupengfei/ccbin.git', :branch => 'master' } s.requires_arc = true

s.ios.deployment_target = '9.0'

    # s.source_files = 'Source/**/*.{h,m,c}'
    # s.public_header_files = 'Source/**/*.h'

    # s.dependency 'YYModel'
    # s.dependency 'YYCache'
    s.dependency 'FMDB'
    # s.dependency 'LKDBHelper'

end `

miroda commented 3 years ago

target 'CCBin' do pod 'FMDB' end

miroda commented 3 years ago

plugin 'cocoapods-imy-bin' use_binaries!

需要替换Podfile里面的组件才写到这里

target 'CCBin' do pod 'FMDB', :path => '../FMDB' end

dabing1022 commented 3 years ago

从podfile、podfile_local中,当前打包依赖的库只有FMDB,编译出来不就一个么?你的预期是?

miroda commented 3 years ago

那么为何推送会失败呢

miroda commented 3 years ago

[!] ====== cocoapods-imy-bin 0.3.0.11 版本 ========

[!] ====== dev 环境 ========

[!] ====== archive-white-pod-list = ["CCBin", "FMDB"]

[!] ====== ignore_git_list = ["git@gitlab.xxx.com:Github-iOS"]

[!] Your project does not explicitly specify the CocoaPods master specs repo. Since CDN is now used as the default, you may safely remove it from your repos directory via pod repo remove master. To suppress this warning please add warn_for_unused_master_specs_repo => false to your Podfile.

[!] 【CCBin | 1】组件spec push失败 .

dabing1022 commented 3 years ago

====== archive-white-pod-list = ["CCBin", "FMDB"]

FMDB被加入了archive白名单了,不会被架构合成、zip压缩上传等

miroda commented 3 years ago

好的,我去掉看看

miroda commented 3 years ago

去掉了也是一样的,现在白名单啥都没有还是这样

dabing1022 commented 3 years ago

检查你的node服务是否正常?

miroda commented 3 years ago

没问题啊

企业微信20210112-103136@2x
dabing1022 commented 3 years ago

看下你的bin-zip文件夹里面的输出 以及提供详细的log 可以一起分析看看

miroda commented 3 years ago

空的,什么东西都没有

miroda commented 3 years ago

====== archive-white-pod-list = ["CCBin", "FMDB"]

FMDB被加入了archive白名单了,不会被架构合成、zip压缩上传等

白名单是要进行合成和压缩上传吧

dabing1022 commented 3 years ago

====== archive-white-pod-list = ["CCBin", "FMDB"]

FMDB被加入了archive白名单了,不会被架构合成、zip压缩上传等

白名单是要进行合成和压缩上传吧

不会

miroda commented 3 years ago

Building static Library CCBin (1) Building ios libraries with archs ["arm64", "armv7"] lipo -create -output ios/CCBin.framework/Versions/A/CCBin build-arm64/libCCBin.a build-armv7/libCCBin.a build-x86_64/libCCBin.a fatal error: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/lipo: can't open input file: build-arm64/libCCBin.a (No such file or directory)

[!] 【CCBin | 1】组件spec push失败 .

这里意思是说 要合成CCBin这个静态库,然后要上传,结果发现没有CCBin这个静态库,结果就出错了,CCBin是我的主工程,这个怎么解决呢

miroda commented 3 years ago

我看了一下,由于在temp目录下 新建了一个项目,然后没有选择团队,针对真机,无法编译,xcodebuild命令就会执行出错; 这个地方可以加一个选择团队的配置选项,类似于fastlane,这样就可以解决这个问题

dabing1022 commented 3 years ago

Building static Library CCBin (1) Building ios libraries with archs ["arm64", "armv7"] lipo -create -output ios/CCBin.framework/Versions/A/CCBin build-arm64/libCCBin.a build-armv7/libCCBin.a build-x86_64/libCCBin.a fatal error: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/lipo: can't open input file: build-arm64/libCCBin.a (No such file or directory)

[!] 【CCBin | 1】组件spec push失败 .

这里意思是说 要合成CCBin这个静态库,然后要上传,结果发现没有CCBin这个静态库,结果就出错了,CCBin是我的主工程,这个怎么解决呢

按照imy-bin的处理思路,你应该先将CCBin发布到私有源中,然后建立类似demo中的podspec一样,依赖CCBin这库,注意和Cocoapods-packager打包思路不同。imy-bin依赖壳工程编译,将依赖到的库编译成二进制。