injectionforxcode icon indicating copy to clipboard operation
injectionforxcode copied to clipboard

Symbol not found: __llvm_gcda_emit_arcs

Open davisford opened this issue 6 years ago • 7 comments

Hi, I'm using XCode 10.1

I had hit #274 and so I turned off test coverage in the scheme.

screen shot 2019-02-21 at 3 42 37 pm

Now, I'm hitting this:

💉 *** Compiling /Users/dford/git/myproject/Classes/Controllers/AppUpdateViewController.m ***
💉 Loading .dylib - Ignore any duplicate class warning...
💉 *** dlopen() error: dlopen(/Users/dford/Library/Containers/com.johnholdsworth.InjectionIII/Data/eval101.dylib, 2): Symbol not found: _llvm_gcda_emit_arcs
  Referenced from: /Users/dford/Library/Containers/com.johnholdsworth.InjectionIII/Data/eval101.dylib
  Expected in: flat namespace

So I tried turning off coverage in the linker settings, to no avail. Any idea how to work past this issue?

screen shot 2019-02-21 at 3 24 30 pm

davisford avatar Feb 21 '19 20:02 davisford

Also did a full clean and rebuild, to no avail.

davisford avatar Feb 21 '19 20:02 davisford

Not encountered this exact error before, You may not be able to inject that file. Any ideas @zenangst?

johnno1962 avatar Feb 21 '19 21:02 johnno1962

This is a new one for me, but then again I only use Swift these days. @davisford you reckon that this could be replicated in an example project so that we could try it out and test it in isolation?

zenangst avatar Feb 21 '19 21:02 zenangst

I now realize that I posted this in the old injection repo. I am using InjectionIII I believe. I installed it via the App Store on Mojave. Does that make a difference at all? I can look at trying to create a demo project.

davisford avatar Feb 26 '19 14:02 davisford

I have solved this by setting GCC_INSTRUMENT_PROGRAM_FLOW_ARCS = NO GCC_GENERATE_TEST_COVERAGE_FILES = NO. If you don't need code coverage, this would be a good way. @davisford @johnno1962 @zenangst

HighwayLaw avatar Jul 03 '19 07:07 HighwayLaw

Thanks for letting us know @lhwcqu. It was a bit of a mystery. What version of Xcode is this?

johnno1962 avatar Jul 03 '19 10:07 johnno1962

Thanks for letting us know @lhwcqu. It was a bit of a mystery. What version of Xcode is this?

That's all right. Am using Xcode 10.2.1

HighwayLaw avatar Jul 03 '19 10:07 HighwayLaw