commit 680c57a15c51c302d89aec134e25f08820d3f30d from: Rudá Moura via: David du Colombier <0intro@gmail.com> date: Mon Oct 09 08:26:14 2017 UTC devdraw: fix build on macOS < 10.12 After making the build on macOS silent on commit 310ae03, the build was broken on macOS lesser than 10.12 (Sierra). This commit conditionally checks the version the of the SDK before using the defined values for silent build. Fixes #66. commit - c665ab76a83dbe4a56410d3f65e02716cd773a6d commit + 680c57a15c51c302d89aec134e25f08820d3f30d blob - 6a3f70f07b5b29bc4b6f2b1bc93564542b6308fc blob + e7296e44dee01f9018ff28d8d350b7685371c6ad --- src/cmd/devdraw/cocoa-screen.m +++ src/cmd/devdraw/cocoa-screen.m @@ -29,6 +29,7 @@ #include "glendapng.h" // Use non-deprecated names. +#if MAC_OS_X_VERSION_MAX_ALLOWED >= 101200 #define NSKeyDown NSEventTypeKeyDown #define NSShiftKeyMask NSEventModifierFlagShift #define NSAlternateKeyMask NSEventModifierFlagOption @@ -52,6 +53,7 @@ #define NSClosableWindowMask NSWindowStyleMaskClosable #define NSMiniaturizableWindowMask NSWindowStyleMaskMiniaturizable #define NSBorderlessWindowMask NSWindowStyleMaskBorderless +#endif AUTOFRAMEWORK(Cocoa)