Skip to content
This repository has been archived by the owner on Jun 13, 2023. It is now read-only.

Project build failure for release 2.4.0 using Carthage build #159

Closed
bayareahank opened this issue Apr 2, 2018 · 7 comments
Closed

Project build failure for release 2.4.0 using Carthage build #159

bayareahank opened this issue Apr 2, 2018 · 7 comments

Comments

@bayareahank
Copy link

Trying out latest 2.4.0 with Carthage, the demo project reports failure at beginning of main.swift.

import ParseLiveQuery

"Module file was created for incompatible target x86_64-apple-ios8.0: ~/liveDemo/Carthage/Build/iOS/ParseLiveQuery.framework/Modules/ParseLiveQuery.swiftmodule/x86_64.swiftmodule".

After that, I tried a number of steps to get around the error, but so far to no avail. The steps I tried:

  1. rm -rf ~/Library/Developer/Xcode/DerivedData/
  2. carthage update --no-use-binaries --platform iOS
  3. Create a new project and repeat the steps above

The environment setting is:
MacOS 10.13.4
Xcode 9.3
Carthage 0.29.0

cat Cartfile
github "ParsePlatform/ParseLiveQuery-iOS-OSX"

Demo project for previous release 2.3.0 built with Carthage also failed to work, see #155 . Yet it went beyond 'import' phase.

Some background info, Parse-SDK-iOS-OSX works fine with Carthage in my project. Just LiveQuery ran into problems.

Wondering what more steps I should take to make the demo project pass build phrase.

@bayareahank
Copy link
Author

I start to suspect this is a Carthage issue. Some more steps I tried:

rm -rf ~/Library/Caches/org.carthage.CarthageKit/DerivedData/*
Cleaning up the Build folder by Cmd ⌘ + Alt ⌥ + Shift ⇧ + K

I also tried reset Xcode by following the steps:
https://gist.github.com/maciekish/66b6deaa7bc979d0a16c50784e16d697

So far this is still not working.

@bayareahank
Copy link
Author

bayareahank commented Apr 2, 2018

With all the steps taken, it doesn't look like a Carthage issue at this moment. Suspecting it could be related to the recent Xcode and Swift update (9.2/4.0 - 9.3/4.1). To dig further.

Again, Parse-SDK-iOS-OSX works fine after the update.

In the same project that parseLiveQuery failed, it goes past "import Parse" without reporting similar error (inside main.swift), so it looks still something ParseLiveQuery related. :

import Foundation
import Parse
import ParseLiveQuery

@bayareahank
Copy link
Author

Still not giving up yet, I tried carthage bootstrap, rather than carthage upate. This gets the build over the import phase (interestingly). Yet it stops at the same place of #155, reporting

redefinition of module 'SSCZLib'
redefinition of module 'SSCommonCrypto'
could not build Objective-C module 'Starscream'

Essentially this is a duplicate of #155.

@bayareahank
Copy link
Author

Since this failure is starstream related, found this from starstream's github issues:

Fix Redefinition of module error in Xcode ≧ 8.3, Take 2 #482
https://github.com/daltoniam/Starscream/pull/482/files

Wondering whether that issuing is causing the StarStream compile failure.

@bayareahank
Copy link
Author

Indeed this bug was introduced by Starscream.

I then tried a hack from Starscream's daltoniam/Starscream#445, by manually remove the SSCZlib and SSCommonCrypto module from Carthage/Checkouts/Starscream/zlib/module.modulemap file, after Carthage build. That makes my liveQuery code run again.

Still, it is a hack, even though it works. I am going to close this bug after the Starscream people resolves it finally.

@bayareahank
Copy link
Author

ParseLiveQuery code needs to be updated, to use StarScream 3.0.6 or later (3.1.0 latest for Swift 5), to get rid of this error.

@TomWFox
Copy link
Contributor

TomWFox commented Aug 19, 2019

@noobs2ninjas recently updated the StarScream dependency, I think it's now at 3.0.5, does this solve your issue?

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

No branches or pull requests

3 participants