Skip to content

Xcode: header search paths with spaces (#303) - #681

Closed
danoli3 wants to merge 1 commit into
openframeworks:masterfrom
danoli3:xcode-spaces
Closed

danoli3 wants to merge 1 commit into
openframeworks:masterfrom
danoli3:xcode-spaces

Conversation

@danoli3

@danoli3 danoli3 commented Oct 25, 2026

Copy link
Copy Markdown
Member

Fixes #303.

The JSON pbxproj writer appended only the first word of a value to array build settings (cols[3] of the space-split command), so HEADER_SEARCH_PATHS got src/sub for src/sub folder and ../addons/ofxSpace for ../addons/ofxSpace Addon/src. Now the whole value is kept, and a value with spaces is stored quoted ("src/sub folder") the way Xcode itself writes such paths, since Xcode splits build settings on whitespace. Addon flags are already split into single words before this, so they're unchanged.

Before / after, project my proj with src/test 2.h, src/sub folder/deep.h, addon ../addons/ofxSpace Addon with src/inner dir/sp.h:

master: ['$(OF_CORE_HEADERS)', 'src', 'src', 'src/sub', '../addons/ofxSpace', '../addons/ofxSpace']
this:   ['$(OF_CORE_HEADERS)', 'src', 'src', '"src/sub folder"', '"../addons/ofxSpace Addon/src"', '"../addons/ofxSpace Addon/src/inner dir"']

#include "..." already worked through Xcode's header map; #include <deep.h> / <sp.h> (search paths only) failed on master with 'deep.h' file not found with <angled> include and builds with this (xcodebuild Release arm64). xcodebuild -showBuildSettings expands them as single quoted paths.

@danoli3

danoli3 commented Oct 25, 2026

Copy link
Copy Markdown
Member Author

Combined into #683.

@danoli3 danoli3 closed this Oct 25, 2026
@danoli3
danoli3 deleted the xcode-spaces branch October 25, 2026 12:00
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

Successfully merging this pull request may close these issues.

xcodeProj - fix handling filenames with spaces

1 participant