macOS: upgrade to Xcode 15 #110243

Merged
Brecht Van Lommel merged 9 commits from brecht/blender:xcode15 into main 2023-09-20 16:25:23 +02:00

For official 4.0 builds, older Xcode versions keep working.

The new linker in Xcode 15 gives many warnings due to duplicated
libraries, generated by CMake to resolve circular dependencies. For now
use the old linker to silence these warnings.

Remove legacy flags for libc++, this is the default for a long time and
generates warnings with the new linker.

Reason for upgrade is to take advantage of MetalRT curve support.

For official 4.0 builds, older Xcode versions keep working. The new linker in Xcode 15 gives many warnings due to duplicated libraries, generated by CMake to resolve circular dependencies. For now use the old linker to silence these warnings. Remove legacy flags for libc++, this is the default for a long time and generates warnings with the new linker. Reason for upgrade is to take advantage of MetalRT curve support.
Brecht Van Lommel added 1 commit 2023-07-18 17:23:04 +02:00
macOS: test Xcode 15
All checks were successful
buildbot/vexp-code-patch-coordinator Build done.
61d6b3fe68
Author
Owner

This shows many linker warnings, presumably due to the new linker included in Xcode 15.
https://builder-uatest.blender.org/admin/#/builders/170/builds/77

This shows many linker warnings, presumably due to the new linker included in Xcode 15. https://builder-uatest.blender.org/admin/#/builders/170/builds/77
Author
Owner

@blender-bot build macos

@blender-bot build macos
Brecht Van Lommel added 1 commit 2023-07-20 15:14:04 +02:00
Test older linker
Some checks failed
buildbot/vexp-code-patch-coordinator Build done.
eb038e7375
Author
Owner

@blender-bot build macos

@blender-bot build macos
Brecht Van Lommel added 1 commit 2023-07-21 13:34:02 +02:00
Embree is now dynamic, libc++ is the default and only choice.
Author
Owner

So this warning was fixed:

ld: warning: ignoring duplicate library '-lc++'

The next one comes from the homebrew environment setting LIBRARY_PATH=/usr/local/lib. Not quite sure what the best way of dealing with that is. Maybe it needs to be solved in homebrew, to avoid setting this when the directory does not exist.

ld: warning: search path '/usr/local/lib' not found

The next types of warnings actually happen with both the old and new linker, and are due to circular dependencies, which causes CMake to generate the libs twice. Realistically we can not solve the circular dependencies any time soon.

Maybe there will be a change in CMake to not generate duplicate static libraries for Xcode 15+, since I guess those linkers do not need it. I did not see any CMake feature that could disable this.

Or the macOS linker could get a flag to silence these warnings.

ld: warning: ignoring duplicate static library 'lib/libbf_intern_guardedalloc.a'
ld: warning: ignoring duplicate static library '/Users/blender/git/blender-vexp/lib/darwin_arm64/openimagedenoise/lib/libOpenImageDenoise.a'
ld: warning: ignoring duplicate static library '/Users/blender/git/blender-vexp/lib/darwin_arm64/openimagedenoise/lib/libcommon.a'
ld: warning: ignoring duplicate static library '/Users/blender/git/blender-vexp/lib/darwin_arm64/gmp/lib/libgmpxx.a'
ld: warning: ignoring duplicate static library '/Users/blender/git/blender-vexp/lib/darwin_arm64/gmp/lib/libgmp.a'
ld: warning: ignoring duplicate library '-force_load'

For these I have no idea what is going on. Maybe they will disappear with an upgrade to OIDN 2 since these files no longer exist. And additionally we'll switch to dynamic instead of static libraries.

ld: warning: no platform load command found in '/Users/blender/git/blender-vexp/lib/darwin_arm64/openimagedenoise/lib/libOpenImageDenoise.a[25](input_reorder.dev.o)', assuming: macOS
ld: warning: no platform load command found in '/Users/blender/git/blender-vexp/lib/darwin_arm64/openimagedenoise/lib/libOpenImageDenoise.a[26](color.dev.o)', assuming: macOS
ld: warning: no platform load command found in '/Users/blender/git/blender-vexp/lib/darwin_arm64/openimagedenoise/lib/libOpenImageDenoise.a[28](output_copy.dev.o)', assuming: macOS
ld: warning: no platform load command found in '/Users/blender/git/blender-vexp/lib/darwin_arm64/openimagedenoise/lib/libOpenImageDenoise.a[29](output_reorder.dev.o)', assuming: macOS
So this warning was fixed: ``` ld: warning: ignoring duplicate library '-lc++' ``` The next one comes from the homebrew environment setting `LIBRARY_PATH=/usr/local/lib`. Not quite sure what the best way of dealing with that is. Maybe it needs to be solved in homebrew, to avoid setting this when the directory does not exist. ``` ld: warning: search path '/usr/local/lib' not found ``` The next types of warnings actually happen with both the old and new linker, and are due to circular dependencies, which causes CMake to generate the libs twice. Realistically we can not solve the circular dependencies any time soon. Maybe there will be a change in CMake to not generate duplicate static libraries for Xcode 15+, since I guess those linkers do not need it. I did not see any CMake feature that could disable this. Or the macOS linker could get a flag to silence these warnings. ``` ld: warning: ignoring duplicate static library 'lib/libbf_intern_guardedalloc.a' ld: warning: ignoring duplicate static library '/Users/blender/git/blender-vexp/lib/darwin_arm64/openimagedenoise/lib/libOpenImageDenoise.a' ld: warning: ignoring duplicate static library '/Users/blender/git/blender-vexp/lib/darwin_arm64/openimagedenoise/lib/libcommon.a' ld: warning: ignoring duplicate static library '/Users/blender/git/blender-vexp/lib/darwin_arm64/gmp/lib/libgmpxx.a' ld: warning: ignoring duplicate static library '/Users/blender/git/blender-vexp/lib/darwin_arm64/gmp/lib/libgmp.a' ld: warning: ignoring duplicate library '-force_load' ``` For these I have no idea what is going on. Maybe they will disappear with an upgrade to OIDN 2 since these files no longer exist. And additionally we'll switch to dynamic instead of static libraries. ``` ld: warning: no platform load command found in '/Users/blender/git/blender-vexp/lib/darwin_arm64/openimagedenoise/lib/libOpenImageDenoise.a[25](input_reorder.dev.o)', assuming: macOS ld: warning: no platform load command found in '/Users/blender/git/blender-vexp/lib/darwin_arm64/openimagedenoise/lib/libOpenImageDenoise.a[26](color.dev.o)', assuming: macOS ld: warning: no platform load command found in '/Users/blender/git/blender-vexp/lib/darwin_arm64/openimagedenoise/lib/libOpenImageDenoise.a[28](output_copy.dev.o)', assuming: macOS ld: warning: no platform load command found in '/Users/blender/git/blender-vexp/lib/darwin_arm64/openimagedenoise/lib/libOpenImageDenoise.a[29](output_reorder.dev.o)', assuming: macOS ```
Brecht Van Lommel added 1 commit 2023-09-07 19:04:23 +02:00
Brecht Van Lommel added 1 commit 2023-09-07 19:30:49 +02:00
Brecht Van Lommel added 1 commit 2023-09-07 19:45:08 +02:00
Brecht Van Lommel added 1 commit 2023-09-07 19:59:36 +02:00
Only use old linker flags for Xcode15+
Some checks reported errors
buildbot/vexp-code-patch-coordinator Build done.
8c01f05bf0
Brecht Van Lommel changed title from WIP: macOS: test Xcode 15 to macOS: upgrade to Xcode 15 2023-09-07 20:03:35 +02:00
Brecht Van Lommel changed title from macOS: upgrade to Xcode 15 to macOS: upgrade buildbot to Xcode 15 2023-09-07 20:04:07 +02:00
Brecht Van Lommel changed title from macOS: upgrade buildbot to Xcode 15 to macOS: upgrade to Xcode 15 2023-09-07 20:04:17 +02:00
Author
Owner

@blender-bot package macos

@blender-bot package macos
Member

Package build started. Download here when ready.

Package build started. [Download here](https://builder.blender.org/download/patch/PR110243) when ready.
Author
Owner

It appears that the warnings no longer exist for the old linker, but are still there for the new linker. So use the old linker for now.

An example of the warnings with the new linker:
https://builder-uatest.blender.org/admin/#/builders/24/builds/10/steps/3/logs/stdio

It appears that the warnings no longer exist for the old linker, but are still there for the new linker. So use the old linker for now. An example of the warnings with the new linker: https://builder-uatest.blender.org/admin/#/builders/24/builds/10/steps/3/logs/stdio
Brecht Van Lommel added 1 commit 2023-09-08 15:56:57 +02:00
Fix Xcode version check only working with Xcode generator
All checks were successful
buildbot/vexp-code-patch-coordinator Build done.
c6f8eaeb82
Author
Owner

@blender-bot package macos

@blender-bot package macos
Member

Package build started. Download here when ready.

Package build started. [Download here](https://builder.blender.org/download/patch/PR110243) when ready.
Brecht Van Lommel added 1 commit 2023-09-19 19:28:38 +02:00
Merge branch 'main' into xcode15
All checks were successful
buildbot/vexp-code-patch-coordinator Build done.
77823197f4
Author
Owner

@blender-bot build macos

@blender-bot build macos
Author
Owner

@blender-bot build macos

@blender-bot build macos
Author
Owner

@blender-bot build macos

@blender-bot build macos
Brecht Van Lommel merged commit d387ef224f into main 2023-09-20 16:25:23 +02:00
Brecht Van Lommel deleted branch xcode15 2023-09-20 16:25:25 +02:00
Sign in to join this conversation.
No reviewers
No Label
Interest
Alembic
Interest
Animation & Rigging
Interest
Asset System
Interest
Audio
Interest
Automated Testing
Interest
Blender Asset Bundle
Interest
BlendFile
Interest
Collada
Interest
Compatibility
Interest
Compositing
Interest
Core
Interest
Cycles
Interest
Dependency Graph
Interest
Development Management
Interest
EEVEE
Interest
Freestyle
Interest
Geometry Nodes
Interest
Grease Pencil
Interest
ID Management
Interest
Images & Movies
Interest
Import Export
Interest
Line Art
Interest
Masking
Interest
Metal
Interest
Modeling
Interest
Modifiers
Interest
Motion Tracking
Interest
Nodes & Physics
Interest
OpenGL
Interest
Overlay
Interest
Overrides
Interest
Performance
Interest
Physics
Interest
Pipeline, Assets & IO
Interest
Platforms, Builds & Tests
Interest
Python API
Interest
Render & Cycles
Interest
Render Pipeline
Interest
Sculpt, Paint & Texture
Interest
Text Editor
Interest
Translations
Interest
Triaging
Interest
Undo
Interest
USD
Interest
User Interface
Interest
UV Editing
Interest
VFX & Video
Interest
Video Sequencer
Interest
Viewport & EEVEE
Interest
Virtual Reality
Interest
Vulkan
Interest
Wayland
Interest
Workbench
Interest: X11
Legacy
Asset Browser Project
Legacy
Blender 2.8 Project
Legacy
Milestone 1: Basic, Local Asset Browser
Legacy
OpenGL Error
Meta
Good First Issue
Meta
Papercut
Meta
Retrospective
Meta
Security
Module
Animation & Rigging
Module
Core
Module
Development Management
Module
Grease Pencil
Module
Modeling
Module
Nodes & Physics
Module
Pipeline, Assets & IO
Module
Platforms, Builds & Tests
Module
Python API
Module
Render & Cycles
Module
Sculpt, Paint & Texture
Module
Triaging
Module
User Interface
Module
VFX & Video
Module
Viewport & EEVEE
Platform
FreeBSD
Platform
Linux
Platform
macOS
Platform
Windows
Severity
High
Severity
Low
Severity
Normal
Severity
Unbreak Now!
Status
Archived
Status
Confirmed
Status
Duplicate
Status
Needs Info from Developers
Status
Needs Information from User
Status
Needs Triage
Status
Resolved
Type
Bug
Type
Design
Type
Known Issue
Type
Patch
Type
Report
Type
To Do
No Milestone
No project
No Assignees
2 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: blender/blender#110243
No description provided.