Hive Hive
Sign in

Mixed swift/ObjC code and buildable folders

GitHub issue · Open

Metadata
Source
tuist/tuist #9601
Updated
Jun 11, 2026
Domains
Generated projects
Details

What happened?

Hello 👋 I’m trying to move from sources/resources/… to buildable folders but I’m having an issue with mixed swift/ObjC targets where swift code cannot see headers included with buildable folders.

I’m wondering if it’s a limitation of buildable folders, a limitation of Tuist, or a problem in my project definitino

How do we reproduce it?

  1. Use attached project buildable-folders-objc-headers.zip
  2. tuist generate
  3. Build fails
  4. Set useBuildableFolders to false
  5. tuist generate
  6. Build succeesds

Error log

If I don’t set headers:

Sources/MixedKit/MixedFacade.swift:5:9: Cannot find 'MixedObjc' in scope

If I set headers:

Trying to add a file at path /Users/df/Developer/komoot/komoot-ios/repro/buildable-folders-objc-headers/Sources/MixedKit/MixedKit.h to a build phase that hasn't been added to the project.

macOS version

26.3

Tuist version

4.152.0

Xcode version

26.3

Comments
L
linear[bot] Feb 25, 2026
D
dosubot[bot] Feb 25, 2026

This is a known limitation of buildable folders with mixed Swift/Objective-C targets. Unlike Xcode, which automatically filters out header files from the sources build phase, Tuist’s buildableFolders doesn’t perform this filtering, causing build errors when directories contain both source and header files (related issue).

You can try configuring headers using BuildableFolderException with publicHeaders and privateHeaders arrays, but there’s currently no API to exclude files from buildable folders.

Recommended workaround: Use the sources attribute instead of buildableFolders for targets with mixed Swift/Objective-C content, as it mimics Xcode’s behavior by handling headers automatically.

If you’d like to debug this further with a coding agent, you can install this skill following the steps in the agent-skills repo and use an AI coding agent (Claude, Codex, etc.) to investigate the generated project.

To reply, just mention @dosu.


Docs are dead. Just use Dosu.

Leave Feedback Ask Dosu about tuist Share Dosu with your team