[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#27059: Can't compile master branch on Mac OS X
From: |
David Caldwell |
Subject: |
bug#27059: Can't compile master branch on Mac OS X |
Date: |
Thu, 25 May 2017 09:25:47 -0700 |
User-agent: |
Mozilla/5.0 (Macintosh; Intel Mac OS X 10.12; rv:52.0) Gecko/20100101 Thunderbird/52.1.1 |
On 5/24/17 1:20 PM, Philipp Stephani wrote:
>
>
> David Caldwell <david@porkrind.org <mailto:david@porkrind.org>> schrieb
> am Mi., 24. Mai 2017 um 18:24 Uhr:
>
> CC nsmenu.o
> nsmenu.m:1496:70: error: expected a type
> - (instancetype)initWithContentRect: (NSRect)contentRect styleMask:
> (NSWindowStyleMask)aStyle
>
> Can you try applying the following patch:
>
> diff --git a/src/nsterm.h b/src/nsterm.h
> index 8f3d92b353..288b91269d 100644
> --- a/src/nsterm.h
> +++ b/src/nsterm.h
> @@ -65,7 +65,7 @@ typedef float EmacsCGFloat;
> /* FIXME: instancetype is a language built-in, but older versions of
> Clang don't support it, and I don't know if GCC supports it at all.
> Should this be tested for in ./configure? */
> -#if defined (NS_IMPL_GNUSTEP)
> +#if defined (NS_IMPL_GNUSTEP) \
> || MAC_OS_X_VERSION_MAX_ALLOWED < MAC_OS_X_VERSION_10_10
> typedef id instancetype;
> typedef NSUInteger NSWindowStyleMask;
>
That didn't work, neither did the current HEAD. The current HEAD is
missing the backslash after the defined (NS_IMPL_GNUSTEP), for one
thing. But testing against MAC_OS_X_VERSION_10_10 doesn't work on older
OSes, it needs to be the hardcoded value '101000' (since the define
didn't exist back then). To sum up, this is the patch that worked for me:
diff --git a/src/nsterm.h b/src/nsterm.h
index 8f3d92b353..04ec82814a 100644
--- a/src/nsterm.h
+++ b/src/nsterm.h
@@ -65,8 +65,8 @@ typedef float EmacsCGFloat;
/* FIXME: instancetype is a language built-in, but older versions of
Clang don't support it, and I don't know if GCC supports it at all.
Should this be tested for in ./configure? */
-#if defined (NS_IMPL_GNUSTEP)
- || MAC_OS_X_VERSION_MAX_ALLOWED < MAC_OS_X_VERSION_10_10
+#if defined (NS_IMPL_GNUSTEP) \
+ || MAC_OS_X_VERSION_MAX_ALLOWED < 101000
typedef id instancetype;
typedef NSUInteger NSWindowStyleMask;
#endif
-David
signature.asc
Description: OpenPGP digital signature
- bug#27059: Can't compile master branch on Mac OS X, David Caldwell, 2017/05/24
- bug#27059: Can't compile master branch on Mac OS X, Philipp Stephani, 2017/05/24
- bug#27059: Can't compile master branch on Mac OS X,
David Caldwell <=
- bug#27059: Can't compile master branch on Mac OS X, Alan Third, 2017/05/25
- bug#27059: Can't compile master branch on Mac OS X, David Caldwell, 2017/05/26
- bug#27059: Can't compile master branch on Mac OS X, Philipp Stephani, 2017/05/26
- bug#27059: Can't compile master branch on Mac OS X, David Caldwell, 2017/05/26
- bug#27059: Can't compile master branch on Mac OS X, Alan Third, 2017/05/26
- bug#27059: Can't compile master branch on Mac OS X, David Caldwell, 2017/05/29
- bug#27059: Can't compile master branch on Mac OS X, Alan Third, 2017/05/29
- bug#27059: Can't compile master branch on Mac OS X, David Caldwell, 2017/05/29
- bug#27059: Can't compile master branch on Mac OS X, Alan Third, 2017/05/29
- bug#27059: Can't compile master branch on Mac OS X, David Caldwell, 2017/05/30