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

XCode 12 Archive Fails #129

Closed
4 tasks done
jehartzog opened this issue Apr 15, 2021 · 5 comments
Closed
4 tasks done

XCode 12 Archive Fails #129

jehartzog opened this issue Apr 15, 2021 · 5 comments

Comments

@jehartzog
Copy link
Contributor

jehartzog commented Apr 15, 2021

image

Related issues #86 #119.

Since this is blocking us, we're going to open a CSM ticket in parallel to reporting here.

Reproduction

  1. With fresh app, follow Iterable docs to setup library

Expected

  1. Dev builds work, archive works

Actual

  1. Dev build works, archive fails with Use of undeclared identifier 'IterableAPI'.

Troubleshooting steps taken

  • Have @import IterableSDK; at the top of AppDelegate.m
  • Added blank swift bridging header
  • Play with different Library Search Paths per this comment
  • Set Always Embed Swift Standard Libraries to no

Env

  1. App boilerplate created with ignite cli v6.5
  2. XCode v12.4
  3. React Native 0.64
  4. Cocoapods 1.10.1
@jehartzog
Copy link
Contributor Author

At Michael's (CSM) request, here is our AppDelegate.m.

@jehartzog
Copy link
Contributor Author

jehartzog commented Apr 26, 2021

We finally figured this out. There were two issues going on:

  1. The original error posted here was due to my error, you can see in the listed AppDelegate.m that I had inadvertently nested @import IterableSDK; inside the flipper #ifdef statement. This was quickly identified by the Iterable CSM and corrected.

  2. We hit new errors exactly as listed in Unable to archive on XCode 12 #86. For whatever reason, the setting that required config to edit was not in our application target, but in our project configuration. Once we realized the documentation was leading us to look at the incorrect place, we were finally able to archive the build. Attaching screenshot since it's XCode.

image

@1280103995
Copy link

1280103995 commented Jun 11, 2021

Hi jehartzog,
The troubleshooting steps are complete, but it not work for me.

I added "$(TOOLCHAIN_DIR)/usr/lib/swift-5.0/$(PLATFORM_NAME)" and "$(inherited)" to Library Search Paths, but it didn’t work. (It’s worth noting that it was originally empty here)

XCode v12.5
React Native 0.64.2
Cocoapods 1.10.1

Could you give me some suggestions? Thanks!

@jehartzog
Copy link
Contributor Author

@1280103995 I don't have much for you. After removing the $(TOOLCHAIN_DIR)/usr/lib/swift-5.0/$(PLATFORM_NAME) entry, we actually had to add it back when we added the iterable message extension to enable rich iOS pushes. Already spent way too much time trying to configure swift-5.0 vs not, and still not sure exactly where we ended up.

@1280103995
Copy link

I read the first point carefully and after adjusting the import position, it worked. Cheers!

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