0

I am trying to install a pod. Following is my Podfile(my project name is NLP):

source 'https://github.com/CocoaPods/Specs.git'
platform :ios, '9.0'

def pod_target
    pod 'Alamofire','~>4.4'
end

target 'NLP' do
    use_frameworks!
    pod_target
    pod 'KFSwiftImageLoader'
    pod 'FMDB'
    pod 'Fabric'
    pod 'Crashlytics'
    pod 'Charts'
    pod 'OpenSSL-Universal'
end

target 'SwaggerRolesAndPolicies' do
    use_frameworks!
    pod_target
end

target 'SwaggerUserProfile' do
    use_frameworks!
    pod_target
end

target 'SwaggerNextStudent' do
    use_frameworks!
    pod_target
end

target 'SwaggerLogin' do
    use_frameworks!
    pod_target
end

target 'SwaggerNextAttendance' do
    use_frameworks!
    pod_target
end

target 'SwaggerNextFee' do
    use_frameworks!
    pod_target
end

target 'SwaggerNextStaff' do
    use_frameworks!
    pod_target
end

Following is happening when i try pod install:

Preparing

Analyzing dependencies

Inspecting targets to integrate
  Using `ARCHS` setting to build architectures of target `Pods-NLP`: (``)
  Using `ARCHS` setting to build architectures of target
  `Pods-SwaggerRolesAndPolicies`: (``)
  Using `ARCHS` setting to build architectures of target
  `Pods-SwaggerUserProfile`: (``)
  Using `ARCHS` setting to build architectures of target
  `Pods-SwaggerNextStudent`: (``)
  Using `ARCHS` setting to build architectures of target `Pods-SwaggerLogin`:
  (``)
  Using `ARCHS` setting to build architectures of target
  `Pods-SwaggerNextAttendance`: (``)
  Using `ARCHS` setting to build architectures of target `Pods-SwaggerNextFee`:
  (``)
  Using `ARCHS` setting to build architectures of target
  `Pods-SwaggerNextStaff`: (``)

Finding Podfile changes
  A OpenSSL-Universal
  - Alamofire
  - Charts
  - Crashlytics
  - FMDB
  - Fabric
  - KFSwiftImageLoader

Resolving dependencies of `Podfile`

Comparing resolved specification to the sandbox manifest
  A OpenSSL-Universal
  - Alamofire
  - Charts
  - Crashlytics
  - FMDB
  - Fabric
  - KFSwiftImageLoader

Downloading dependencies

-> Using Alamofire (4.4.0)

-> Using Charts (3.0.1)

-> Using Crashlytics (3.8.4)

-> Using FMDB (2.6.2)

-> Using Fabric (1.6.11)

-> Using KFSwiftImageLoader (3.0.0)

-> Installing OpenSSL-Universal (1.0.2.10)
 > Git download
 > Git download
     $ /usr/bin/git clone https://github.com/krzyzanowskim/OpenSSL.git
     /var/folders/nz/8hrtwpzd5dj617b_38nqrw940000gn/T/d20170523-2509-vg335k
     --template= --single-branch --depth 1 --branch 1.0.2.10
     Cloning into '/var/folders/nz/8hrtwpzd5dj617b_38nqrw940000gn/T/d20170523-2509-vg335k'...

It is getting struck at this point. What might be the error and how can i resolve it? The error only comes when OpenSSL-Universal pod is added. My xcode version is 8.3.2.

Nishant Bhindi
  • 2,242
  • 8
  • 21
Bharath Reddy
  • 636
  • 1
  • 5
  • 21
  • If your project name/target is NLP why are you using other targets ? – roy May 23 '17 at 10:12
  • I added other targets to the project...I need Alamofire in other targets so I added in that way. – Bharath Reddy May 23 '17 at 10:13
  • try `pod install` with `--verbose` to see if there's any error – Tj3n May 23 '17 at 10:57
  • Thank you. Problem solved. It installed after a very long time... @Tj3n I used it that's why i was getting all those logs. I don't why it took that long though.... Generally other pods take less than a minute. – Bharath Reddy May 23 '17 at 10:59
  • sometimes github act very slow, like when u reset pod spec master, it took over an hour for me to download like 300mb from git, but stuck does look like error somehow :d – Tj3n May 23 '17 at 11:14

1 Answers1

0

Add below code at the end of your podfile. It may resolve the issue.

post_install do |installer|
installer.pods_project.targets.each do |target|
    target.build_configurations.each do |config|
        config.build_settings['SWIFT_VERSION'] = '3.0'
    end
end
end

Thanks..

Nishant Bhindi
  • 2,242
  • 8
  • 21
  • Thank You for the answer. I don't know how but after like one hour it automatically installed pod(I did not add your code). – Bharath Reddy May 23 '17 at 10:55
  • Just curious What does your code do? Does it set Swift version of each target to 3.0?? – Bharath Reddy May 23 '17 at 11:36
  • Yes thats correct. You can refer below link for more information. https://stackoverflow.com/questions/38446097/xcode-8-beta-3-use-legacy-swift-issue/38466703#38466703 – Nishant Bhindi May 24 '17 at 05:05