24
25
26
27
28
29
30
31
32
33
34
35
36
37
|
AX_CHECK_COMPILER_FLAGS(-pipe, [OBJCFLAGS="$OBJCFLAGS -pipe"])
AX_CHECK_COMPILER_FLAGS(-fno-common, [OBJCFLAGS="$OBJCFLAGS -fno-common"])
AX_CHECK_COMPILER_FLAGS(-fno-constant-cfstrings, [
NO_CONST_CFSTRINGS="-fno-constant-cfstrings"
OBJCFLAGS="$OBJCFLAGS -fno-constant-cfstrings"
])
AC_SUBST(NO_CONST_CFSTRINGS)
AC_MSG_CHECKING(whether Objective C compiler supports fast enumeration)
AC_TRY_COMPILE([
@protocol OFFastEnumeration
- (int)countByEnumeratingWithState: (void*)state
objects: (id*)objects
|
>
|
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
|
AX_CHECK_COMPILER_FLAGS(-pipe, [OBJCFLAGS="$OBJCFLAGS -pipe"])
AX_CHECK_COMPILER_FLAGS(-fno-common, [OBJCFLAGS="$OBJCFLAGS -fno-common"])
AX_CHECK_COMPILER_FLAGS(-fno-constant-cfstrings, [
NO_CONST_CFSTRINGS="-fno-constant-cfstrings"
OBJCFLAGS="$OBJCFLAGS -fno-constant-cfstrings"
])
AX_CHECK_COMPILER_FLAGS(-Wshorten-64-to-32, [OBJCFLAGS="$OBJCFLAGS -pipe"])
AC_SUBST(NO_CONST_CFSTRINGS)
AC_MSG_CHECKING(whether Objective C compiler supports fast enumeration)
AC_TRY_COMPILE([
@protocol OFFastEnumeration
- (int)countByEnumeratingWithState: (void*)state
objects: (id*)objects
|
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
|
AS_IF([test x"$objc_runtime" = x"Apple"], [
AC_CHECK_HEADER(Foundation/NSObject.h, [
AC_SUBST(FOUNDATION_COMPAT_M, "foundation-compat.m")
])
])
AS_IF([test x"$GOBJC" = x"yes"], [
OBJCFLAGS="$OBJCFLAGS -Wwrite-strings -Wshorten-64-to-32 -Wcast-align"
OBJCFLAGS="$OBJCFLAGS -Wpointer-arith -Werror"
AC_MSG_CHECKING(whether gcc has bug objc/27438)
AC_TRY_COMPILE([
@interface OFConstantString
{
struct objc_class *isa;
const char *string;
|
|
|
|
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
|
AS_IF([test x"$objc_runtime" = x"Apple"], [
AC_CHECK_HEADER(Foundation/NSObject.h, [
AC_SUBST(FOUNDATION_COMPAT_M, "foundation-compat.m")
])
])
AS_IF([test x"$GOBJC" = x"yes"], [
OBJCFLAGS="$OBJCFLAGS -Wwrite-strings -Wcast-align -Wpointer-arith"
OBJCFLAGS="$OBJCFLAGS -Werror"
AC_MSG_CHECKING(whether gcc has bug objc/27438)
AC_TRY_COMPILE([
@interface OFConstantString
{
struct objc_class *isa;
const char *string;
|