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

Embed Pod Frameworks fails if the target has spaces in the name #6121

Closed
1 task done
harlanhaskins opened this issue Nov 2, 2016 · 1 comment
Closed
1 task done
Labels
s2:confirmed Issues that have been confirmed by a CocoaPods contributor t2:defect These are known bugs. The issue should also contain steps to reproduce. PRs welcome!

Comments

@harlanhaskins
Copy link
Contributor

harlanhaskins commented Nov 2, 2016

Report

What did you do?

Attempt to build my project after running pod install

What did you expect to happen?

A successful build

What happened instead?

A cryptic error message, because the frameworks path is not quoted:

/usr/bin/codesign --force --sign 3529B9D2157072B8C666FCDCB5561B2FB83CD9F2  --preserve-metadata=identifier,entitlements /Users/harlan/Library/Developer/Xcode/DerivedData/Bryx_911-etlctfgizhnmsigivwwqqolxshkr/Build/Products/Debug-iphoneos/Bryx 911.app/Frameworks/Alamofire.framework
/Users/harlan/Library/Developer/Xcode/DerivedData/Bryx_911-etlctfgizhnmsigivwwqqolxshkr/Build/Products/Debug-iphoneos/Bryx: No such file or directory

CocoaPods Environment

Stack

   CocoaPods : 1.2.0.beta.1
        Ruby : ruby 2.0.0p648 (2015-12-16 revision 53162) [universal.x86_64-darwin16]
    RubyGems : 2.0.14.1
        Host : Mac OS X 10.12.2 (16C32e)
       Xcode : 8.1 (8B62)
         Git : git version 2.7.0
Ruby lib dir : /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib
Repositories : master - https://github.com/CocoaPods/Specs.git @ b558170a7d2e713784f599de9e9c799368474e3a

Installation Source

Executable Path: /usr/local/bin/pod

Plugins

cocoapods-deintegrate : 1.0.1
cocoapods-plugins     : 1.0.0
cocoapods-search      : 1.0.0
cocoapods-stats       : 1.0.0
cocoapods-trunk       : 1.1.1
cocoapods-try         : 1.1.0

Podfile

source 'https://github.com/CocoaPods/Specs.git'
platform :ios, "8.0"
use_frameworks!
inhibit_all_warnings!

def shared_pods
    pod 'FormatterKit'
    pod 'FXKeychain'
    pod 'RMPhoneFormat', :git => 'https://github.com/davbeck/RMPhoneFormat.git'
    pod 'Alamofire', '~>3.5.0'
end

target 'Bryx 911' do
    shared_pods
    pod 'BRYXBanner', '=0.6.3'
    pod 'MBProgressHUD', '=0.9.2'
    pod 'UIDevice-Hardware', '=0.1.7'
    pod 'GeoJSONSerialization', '=0.0.4'
    pod 'TTTAttributedLabel', '=2.0.0'
    pod "STKWebKitViewController", '=0.5.0'
    pod 'DZNEmptyDataSet', '=1.8.1'
    pod 'M13ProgressSuite', '=1.2.7'
    pod 'OAStackView', '=1.0.1'
    pod 'AsyncSwift', '=1.7.4'
    pod 'BRYXGradientView', '=0.1.0'
    pod 'SocketRocket', '=0.5.1'
    pod 'UITextView+Placeholder', '=1.2'
end

post_install do |installer|
    require 'fileutils'
    FileUtils.cp_r('Pods/Target Support Files/Pods-Bryx 911/Pods-Bryx 911-acknowledgements.plist', 'Bryx 911/Settings.bundle/Acknowledgements.plist', :remove_destination => true)
    PLISTBUDDY = '/usr/libexec/PlistBuddy'
    installer.pods_project.targets.each do |target|
    # plist = "Pods/Target Support Files/#{target}/Info.plist"
    resource_plist = "Pods/Target Support Files/#{target}/ResourceBundle-#{target}-Info.plist"
    if File.exist?(resource_plist)
      `#{PLISTBUDDY} -c "Set :CFBundlePackageType BNDL" '#{resource_plist}' 2>&1`
      `#{PLISTBUDDY} -c "Delete :CFBundleExecutable" '#{resource_plist}' 2>&1`
    end
    # `#{PLISTBUDDY} -c "Delete :CFBundleExecutable" '#{plist}' 2>&1`
    # `#{PLISTBUDDY} -c "Set :CFBundlePackageType BNDL" '#{plist}' 2>&1`
  end
end

I've got a pull request that fixes this issue, verified locally, at #6120.

@benasher44 benasher44 added t2:defect These are known bugs. The issue should also contain steps to reproduce. PRs welcome! s2:confirmed Issues that have been confirmed by a CocoaPods contributor labels Nov 2, 2016
@benasher44
Copy link
Member

Closed via #6120

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
s2:confirmed Issues that have been confirmed by a CocoaPods contributor t2:defect These are known bugs. The issue should also contain steps to reproduce. PRs welcome!
Projects
None yet
Development

No branches or pull requests

2 participants