Opened 3 years ago

Closed 3 years ago

Last modified 3 years ago

#63868 closed defect (fixed)

tk @8.6.12: error: use of undeclared identifier 'NSBitmapFormatAlphaFirst'

Reported by: macdeport Owned by: MarcusCalhoun-Lopez (Marcus Calhoun-Lopez)
Priority: Normal Milestone:
Component: ports Version: 2.7.1
Keywords: yosemite Cc: macdeport, mascguy (Christopher Nielsen), evanmiller (Evan Miller), chrstphrchvz (Christopher Chavez)
Port: tk

Description

:info:build /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_x11_tk/tk/work/tk8.6.12/unix/../macosx/tkMacOSXImage.c:778:40: error: use of undeclared identifier 'NSBitmapFormatAlphaFirst'
:info:build         if ((bitmap_fmt != 0 && bitmap_fmt != NSBitmapFormatAlphaFirst)
:info:build                                               ^
:info:build 1 error generated.
:info:build make: *** [tkMacOSXImage.o] Error 1
:info:build make: *** Waiting for unfinished jobs....
:info:build make: Leaving directory `/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_x11_tk/tk/work/tk8.6.12/unix'
:info:build Command failed:  cd

Attachments (1)

main.log.zip (10.4 KB) - added by macdeport 3 years ago.
/opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_x11_tk/tk/main.log

Download all attachments as: .zip

Change History (11)

Changed 3 years ago by macdeport

Attachment: main.log.zip added

/opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_x11_tk/tk/main.log

comment:1 Changed 3 years ago by macdeport

Cc: macdeport added

comment:2 Changed 3 years ago by ryandesign (Ryan Carsten Schmidt)

Keywords: yosemite added
Owner: set to MarcusCalhoun-Lopez
Port: 8.6.12 removed
Status: newassigned
Summary: Failed to build Tcl/Tk version 8.6.12tk @8.6.12: error: use of undeclared identifier 'NSBitmapFormatAlphaFirst'

Apple says NSBitmapFormatAlphaFirst was introduced in macOS 10.12 and your log shows you are on 10.10. Hopefully there is a way that we don't have to require macOS 10.12 for tk; that would be unfortunate.

comment:3 Changed 3 years ago by mascguy (Christopher Nielsen)

Cc: mascguy added

comment:4 Changed 3 years ago by evanmiller (Evan Miller)

The old name is NSAlphaFirstBitmapFormat; likely a simple substitution to fix.

https://developer.apple.com/documentation/appkit/nsalphafirstbitmapformat?language=objc

comment:5 Changed 3 years ago by evanmiller (Evan Miller)

Cc: evanmiller added

comment:6 Changed 3 years ago by chrstphrchvz (Christopher Chavez)

Usually one of the lead upstream developers for Mac would test Tk going back to 10.6, but I guess this change made it to the release untested on older macOS. I will submit a patch for this shortly, using their likely preferred approach of predefining the old constant name to the value of the new constant in macosx/tkMacOSXConstants.h (so as to avoid deprecation warnings on newer macOS), and use NSAlphaFirstBitmapFormat instead of NSBitmapFormatAlphaFirst in macosx/tkMacOSXImage.c.

comment:7 Changed 3 years ago by chrstphrchvz (Christopher Chavez)

Cc: chrstphrchvz added

comment:8 Changed 3 years ago by chrstphrchvz (Christopher Chavez)

comment:9 Changed 3 years ago by chrstphrchvz (Christopher Chavez)

Resolution: fixed
Status: assignedclosed

In 960c9855b8143d50674dcfc2666f8db536a28cb7/macports-ports (master):

tk: fix build on macOS < 10.12

Fixes: #63868

comment:10 in reply to:  9 Changed 3 years ago by macdeport

Replying to chrstphrchvz:

In 960c9855b8143d50674dcfc2666f8db536a28cb7/macports-ports (master):

tk: fix build on macOS < 10.12

Fixes: #63868

Thanks to all those who make MacPorts live and especially this time @chrstphrchvz for putting my head above water 😰 efficiently & quickly

Note: See TracTickets for help on using tickets.