2

Since I've begun to (try) to use_frameworks! my local development pods can't access code that is included at the top level of my project. This used to work, and still works if I comment out use_frameworks in my dead-simple Podfile below:

platform :ios, '9.0'
use_frameworks! #comment this out and all is well

target :test_use_frameworks do
  pod 'STHTTPRequest', '1.0.0' #test a well known library
  pod 'test_pod', :path => '../test_pod/' #Attempt to use that library from within local pod
end

I've made a simple objective-c only test project that is accessible here.

When I try to use STHTTPRequest from within my local test_pod, like so:

STHTTPRequest * r = [STHTTPRequest requestWithURLString:@"http://www.google.com"];

I get the following error:

Undefined symbols for architecture x86_64:
  "_OBJC_CLASS_$_STHTTPRequest", referenced from:
      objc-class-ref in TestClass.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)

(This happens no matter what class I try to use - the issue has nothing to do with STHTTPRequest...)

The local podspec is also as simple as it can be:

Pod::Spec.new do |s|
  s.name             = "test_pod"
  s.version          = "0.1.0"
  s.summary          = "A short description of test_pod."
  s.description      = "use_frameworks! is causing problems for me"
  s.homepage         = "https://github.com/<GITHUB_USERNAME>/test_pod"
  s.license          = 'MIT'
  s.source           = { :git => "https://github.com/<GITHUB_USERNAME>/test_pod.git", :tag => s.version.to_s }
  s.platform     = :ios, '7.0'
  s.requires_arc = true
  s.source_files = 'Pod/Classes/**/*'
  s.resource_bundles = {
    'test_pod' => ['Pod/Assets/*.png']
  }
  s.dependency 'AFNetworking', '~> 2.3'
end

Here are the SO questions I've found on this topic: 1 2 3, but none of them help. I've tried every variation of header search path, user header search path and framework search path that I can think of.

Again, this project HAS NO SWIFT in it. It will soon, if I can get this to work, but not yet...

I'm using cocoapods 0.39.0

What am I missing?

EDIT: This question was answered by the helpful Cocoapods team here

Community
  • 1
  • 1
shmim
  • 729
  • 9
  • 21

1 Answers1

0

This question was answered by the helpful Cocoapods team here

shmim
  • 729
  • 9
  • 21