Opened 12 months ago

Closed 9 months ago

#67459 closed defect (fixed)

mame: upstream issue tracking for 0.252 and later: 3rd-party component bgfx broken for 10.14/10.15

Reported by: mascguy (Christopher Nielsen) Owned by: mascguy (Christopher Nielsen)
Priority: Normal Milestone:
Component: ports Version: 2.8.1
Keywords: Cc:
Port: mame

Description (last modified by mascguy (Christopher Nielsen))

Presently Mame is pinned at 0.251 for 10.14 and later, due to breakage within 3rd-party component BGFX. Specifically, certain pixel formats are unavailable in releases prior to Big Sur, even though upstream still officially supports 10.14 and later.

For 10.14:

renderer_mtl.mm:: error: unknown type name 'MTLTextureSwizzleChannels'
renderer_mtl.mm:: error: use of undeclared identifier 'MTLTextureSwizzleAlpha'
renderer_mtl.mm:: error: use of undeclared identifier 'MTLTextureSwizzleBlue'
renderer_mtl.mm:: error: use of undeclared identifier 'MTLTextureSwizzleGreen'
renderer_mtl.mm:: error: use of undeclared identifier 'MTLTextureSwizzleRed'

For 10.15:

renderer_mtl.mm: error: 'MTLPixelFormatABGR4Unorm' is unavailable: not available on macOS
renderer_mtl.mm: error: 'MTLPixelFormatB5G6R5Unorm' is unavailable: not available on macOS
renderer_mtl.mm: error: 'MTLPixelFormatBGR5A1Unorm' is unavailable: not available on macOS

This issue has officially been reported to upstream, and is being tracked by:

While the issue would be easy enough to patch - it's limited to two source files - there's a possibility that it will cause downstream compilation (or runtime) issues with Mame. So rather than simply blindly patch it, the goal is to engage with upstream, and validate that we won't have other unexpected problems.

Change History (4)

comment:1 Changed 12 months ago by mascguy (Christopher Nielsen)

Description: modified (diff)

comment:2 Changed 12 months ago by mascguy (Christopher Nielsen)

Upstream - and specifically, Rob Belmont - was kind enough to provide the following patch. They aren't able to commit it to mainline at this point, but looks promising:

Currently testing locally on 10.14/10.15, to see if it does the trick.

comment:3 in reply to:  2 Changed 9 months ago by mascguy (Christopher Nielsen)

Replying to mascguy:

Upstream - and specifically, Rob Belmont - was kind enough to provide the following patch. They aren't able to commit it to mainline at this point, but looks promising:

Currently testing locally on 10.14/10.15, to see if it does the trick.

Unfortunately the patch needs to be slightly different, for 10.14 vs. 10.15. And it's going to be fragile.

So rather than deal with that, upstream recommended disabling the BGFX Metal renderer for 10.14/10.15. So that's the approach we'll follow going forward.

comment:4 Changed 9 months ago by Christopher Nielsen <mascguy@…>

Resolution: fixed
Status: assignedclosed

In 738f13d4f9f5fca8789380866c1d4e206eff2ef6/macports-ports (master):

mame: update to 0.256; use py311; use internal lua

Closes: #67459

Note: See TracTickets for help on using tickets.