Documentation Generation Fails Due to Missing Header

Question or problem

After migrating Firebase from Carthage to Swift Package Manager (SPM) and updating its version, I encountered an issue where Build Documentation fails due to missing FirebaseCore headers:

This appears to be similar to the issue reported in Tuist Issue #6637, where the build documentation fails when the app target has a Firebase dependency.

Expectation

  • Build Documentation should successfully generate documentation without missing headers.

Actual Behavior:

  • The documentation build process fails because FIRApp.h cannot be found in FirebaseCore.
  • However, the app can be compiled and archived successfully.

Context

  • Tuist version: 4.39.1
  • Xcode version: 16.2
  • Firebase version: 11.8.1
  • App: DBFFM
  • App version: 3.94.0

I encountered this issue after migrating Firebase dependencies from Carthage to SPM. While the app itself builds and runs correctly, Build Documentation fails due to missing headers in FirebaseCore.

Reproduction (mandatory for problems)

You can see the detailed error when you build documentation via Xcode: Product -> Build Documentation.

1 Like

Is ther any time horizon when we can count at least on an answer? This is really blocking us…

Hey, folks :wave:

I’m aware of this, but I actually have no idea what the fix could be and haven’t had the time to look into this. Fwiw, this doesn’t require a lot of Tuist knowledge, so you should be able to look into this yourself – Tuist is a community-led project after all :slightly_smiling_face:

There are essentially two pieces to look into:

For debugging and what could shed a light on this is to inspect the build commands Xcode runs when building for documentation and compare those with a regular build. There must be something that Xcode does differently when building for documentation.

I understand you’d love an answer “we will look into this later this week”, but our resources are stretched and we can’t look into everything. Sorry about that. It’s in my backlog, but can’t guarantee when I will have time to look into this deeper.