Use __APPLE__ token to control OSX-specific tests

The carbon framework is deprecated and not really related to OSX's
printf features. Directly test compiler-defined token for the platform
itself rather than that autodetected framework as a proxy.

https://bugzilla.gnome.org/show_bug.cgi?id=731625
This commit is contained in:
Daniel Macks 2014-06-13 15:16:51 -04:00 committed by Philip Withnall
parent d88d90c3c8
commit 0091f7f212

View File

@ -1433,14 +1433,14 @@ test_non_utf8_printf (void)
*/
TEST_PRINTF ("%a", "\345\234\237");
TEST_PRINTF ("%A", "\345\234\237\346\233\234\346\227\245");
#ifndef HAVE_CARBON /* OSX just returns the number */
#ifndef __APPLE__ /* OSX just returns the number */
TEST_PRINTF ("%b", "10\346\234\210");
#endif
TEST_PRINTF ("%B", "10\346\234\210");
TEST_PRINTF ("%d", "24");
TEST_PRINTF_DATE (2009, 1, 1, "%d", "01");
TEST_PRINTF ("%e", "24"); // fixme
#ifndef HAVE_CARBON /* OSX just returns the number */
#ifndef __APPLE__ /* OSX just returns the number */
TEST_PRINTF ("%h", "10\346\234\210");
#endif
TEST_PRINTF ("%H", "00");
@ -1457,7 +1457,7 @@ test_non_utf8_printf (void)
TEST_PRINTF_TIME (10, 13, 13, "%l", "10");
TEST_PRINTF ("%m", "10");
TEST_PRINTF ("%M", "00");
#ifndef HAVE_CARBON /* OSX returns latin "AM", not japanese */
#ifndef __APPLE__ /* OSX returns latin "AM", not japanese */
TEST_PRINTF ("%p", "\345\215\210\345\211\215");
TEST_PRINTF_TIME (13, 13, 13, "%p", "\345\215\210\345\276\214");
TEST_PRINTF ("%P", "\345\215\210\345\211\215");
@ -1470,7 +1470,7 @@ test_non_utf8_printf (void)
TEST_PRINTF ("%S", "00");
TEST_PRINTF ("%t", " ");
TEST_PRINTF ("%u", "6");
#ifndef HAVE_CARBON /* OSX returns YYYY/MM/DD in ASCII */
#ifndef __APPLE__ /* OSX returns YYYY/MM/DD in ASCII */
TEST_PRINTF ("%x", "2009\345\271\26410\346\234\21024\346\227\245");
#endif
TEST_PRINTF ("%X", "00\346\231\20200\345\210\20600\347\247\222");