RxExpect icon indicating copy to clipboard operation
RxExpect copied to clipboard

RxExpect expects RxTest to have been compiled with bitcode enabled

Open wlucjan opened this issue 8 years ago • 10 comments

I am getting following error from linker when I try to run my tests:

RxTest/RxTest.framework/RxTest' does not contain bitcode. You must rebuild it with bitcode enabled (Xcode setting ENABLE_BITCODE)

Here is my podfile:

target App
  ...
  target 'AppTests' do
    inherit! :search_paths
    # Pods for testing
    pod 'RxTest'
    pod 'RxExpect', '~> 0.2'
  end
end

Test target has disabled bitcode.

Any idea what's wrong?

wlucjan avatar Jan 03 '17 17:01 wlucjan

@wlucjan, sorry for delay. I didn't realize that I'm not receiving any notifications from this repo 😱 Anyway, could you try again with 0.3.0 release?

devxoul avatar Jan 15 '17 20:01 devxoul

I get the same error.

Installing RxExpect 0.3.0 (was 0.2.0)
Using RxTest (3.1.0)

wlucjan avatar Jan 16 '17 18:01 wlucjan

Hmm. that's weird. Could you try with new project?

devxoul avatar Jan 17 '17 05:01 devxoul

Same here, just added RxExpect, 0.3.0 with RxTest 3.1.0, on clean build it gives the bitcode error. RxTest/RxTest.framework/RxTest does not contain bitcode. You must rebuild it with bitcode enabled (Xcode setting ENABLE_BITCODE), obtain an updated library from the vendor, or disable bitcode for this target

DriesSchulten avatar Jan 18 '17 10:01 DriesSchulten

@wlucjan @DriesSchulten what is the ENABLE_BITCODE value of your project?

devxoul avatar Jan 18 '17 13:01 devxoul

Like mentioned in my first post - Test target has disabled bitcode. Yet both Release targets have enabled bitcode.

wlucjan avatar Jan 18 '17 13:01 wlucjan

@wlucjan could you please try with a new project? I cannot reproduce this issue.

devxoul avatar Jan 18 '17 14:01 devxoul

I've tried to reproduce it with a new project; but I haven't been able to so far. I don't know what triggered it in the normal project; added it yesterday and it was working; after some clean/rebuild actions it was giving this error today.

I will try some more.

And indeed bitcode is disabled.

Update: when I build the test against the simulator it works, when I build it against an actual device it gives the error.

Maybe related to: https://github.com/Quick/Nimble/issues/170, also error when deploying to actual device.

DriesSchulten avatar Jan 18 '17 16:01 DriesSchulten

I have the same error using Carthage: Cartfile github "devxoul/RxExpect" ~> 0.5

$ carthage update --platform iOS

*** Fetching RxExpect *** Fetching RxSwift *** Downloading RxSwift.framework binary at "Naldi" *** Checking out RxExpect at "0.5.0" *** xcodebuild output can be found in /var/folders/16/07q__61d5tbddh51nly_g3vw0000gn/T/carthage-xcodebuild.FYNGty.log *** Building scheme "RxExpect-iOS" in RxExpect.xcworkspace ** BUILD FAILED **

The following build commands failed: CompileSwift normal arm64 CompileSwiftSources normal arm64 com.apple.xcode.tools.swift.compiler (2 failures) /Users/valeriykliuk/Documents/Bitbucket/TestLab/RxApp3/Carthage/Checkouts/RxExpect/Sources/RxAssertion.swift:25:8: error: no such module 'RxCocoa' A shell task (/usr/bin/xcrun xcodebuild -workspace /Users/valeriykliuk/Documents/Bitbucket/TestLab/RxApp3/Carthage/Checkouts/RxExpect/RxExpect.xcworkspace -scheme RxExpect-iOS -configuration Release -sdk iphoneos ONLY_ACTIVE_ARCH=NO BITCODE_GENERATION_MODE=bitcode CODE_SIGNING_REQUIRED=NO CODE_SIGN_IDENTITY= CARTHAGE=YES clean build) failed with exit code 65: ** BUILD FAILED **

The following build commands failed: CompileSwift normal arm64 CompileSwiftSources normal arm64 com.apple.xcode.tools.swift.compiler (2 failures)

carthage-xcodebuild.FYNGty.log

RxApp3/Carthage/Checkouts/RxExpect/Sources/RxAssertion.swift:25:8: error: no such module 'RxCocoa' import RxCocoa ^

ValeriyKliuk avatar Feb 10 '17 18:02 ValeriyKliuk

I got the same error when only I tried to test with real device.

giboJK avatar Oct 26 '20 11:10 giboJK