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

Bugfender doesn't seem to compile for xcode test target #3

Closed
tonyxiao opened this issue Apr 10, 2015 · 6 comments
Closed

Bugfender doesn't seem to compile for xcode test target #3

tonyxiao opened this issue Apr 10, 2015 · 6 comments

Comments

@tonyxiao
Copy link

Works fine for the app target itself, but when xcode tries to compile the test target from command line it fails to find bugfender at link time. Building the project itself seems to be fine. This is reproducible in a clean VM continuous integration environment. I'm linking bugfender using cocoapods, if that makes a different.

xcodebuild test -workspace $WORKSPACE -scheme $SCHEME -destination 'platform=iOS Simulator,OS=latest,name=iPhone 6'

Undefined symbols for architecture x86_64:
  "_OBJC_CLASS_$_Bugfender", referenced from:
      __TMaCSo9Bugfender in Logging.o
      __TMaCSo9Bugfender in AppDelegate.o
      l_OBJC_$_CATEGORY_Bugfender_$_Swift in Ketch-Bridging.o
  "___BFLog", referenced from:
      +[Bugfender(Swift) logWithFilename:lineNumber:functionName:tag:level:message:] in Ketch-Bridging.o
ld: symbol(s) not found for architecture x86_64
@jgimenez
Copy link
Member

jgimenez commented May 7, 2015

Hi @tonyxiao it looks like one of the methods you're testing uses Bugfender. The compiler knows about the Bugfender headers but the linker does not.

Since you're using Swift, the frameworks included in the main target are not included in the testing one. You should link Bugfender as well in the testing target. Did you do that?

@tonyxiao
Copy link
Author

tonyxiao commented May 9, 2015

Cleaning the project solves the problem, but then it would resurface from time to time and re-clean is required. I'm using many libraries but this problem only happens with Bugfender.

@jgimenez
Copy link
Member

I'm sorry but if it does sometimes work and sometimes not it's more probably that you hit a bug in CocoaPods or Xcode. I tried several things but could not reproduce your problem

I would recommend including the cleaning in your script so that you always build the whole project from scratch. It's a best practice anyway, since sometimes you could run into a situation that something works in your machine due to incremental compilation but the build is broken and your colleagues can not build.

@tonyxiao
Copy link
Author

We're still seeing issues with Bugfender dependency, is it possible to open source the framework instead of shipping an compiled library? That way if I run into issues I can fix myself rather than having to open an issue and go back and forth like this.

@jgimenez
Copy link
Member

Hi @tonyxiao . What are you having problems with? We'd like to help you fix them. The SDK unfortunately can not be made open source.

Please open bug reports and we'll take care of them.

@tonyxiao
Copy link
Author

The same issue in the original post. Whether or not it's a bug with xcode or cocoapods I don't know, but we only run into this issue with BugFender dependency, not any other dependency for some reason.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants