|
Packit |
4e910c |
# intlmacosx.m4 serial 5 (gettext-0.18.2)
|
|
Packit |
4e910c |
dnl Copyright (C) 2004-2014, 2016 Free Software Foundation, Inc.
|
|
Packit |
4e910c |
dnl This file is free software; the Free Software Foundation
|
|
Packit |
4e910c |
dnl gives unlimited permission to copy and/or distribute it,
|
|
Packit |
4e910c |
dnl with or without modifications, as long as this notice is preserved.
|
|
Packit |
4e910c |
dnl
|
|
Packit |
4e910c |
dnl This file can be used in projects which are not available under
|
|
Packit |
4e910c |
dnl the GNU General Public License or the GNU Library General Public
|
|
Packit |
4e910c |
dnl License but which still want to provide support for the GNU gettext
|
|
Packit |
4e910c |
dnl functionality.
|
|
Packit |
4e910c |
dnl Please note that the actual code of the GNU gettext library is covered
|
|
Packit |
4e910c |
dnl by the GNU Library General Public License, and the rest of the GNU
|
|
Packit |
4e910c |
dnl gettext package is covered by the GNU General Public License.
|
|
Packit |
4e910c |
dnl They are *not* in the public domain.
|
|
Packit |
4e910c |
|
|
Packit |
4e910c |
dnl Checks for special options needed on Mac OS X.
|
|
Packit |
4e910c |
dnl Defines INTL_MACOSX_LIBS.
|
|
Packit |
4e910c |
AC_DEFUN([gt_INTL_MACOSX],
|
|
Packit |
4e910c |
[
|
|
Packit |
4e910c |
dnl Check for API introduced in Mac OS X 10.2.
|
|
Packit |
4e910c |
AC_CACHE_CHECK([for CFPreferencesCopyAppValue],
|
|
Packit |
4e910c |
[gt_cv_func_CFPreferencesCopyAppValue],
|
|
Packit |
4e910c |
[gt_save_LIBS="$LIBS"
|
|
Packit |
4e910c |
LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation"
|
|
Packit |
4e910c |
AC_LINK_IFELSE(
|
|
Packit |
4e910c |
[AC_LANG_PROGRAM(
|
|
Packit |
4e910c |
[[#include <CoreFoundation/CFPreferences.h>]],
|
|
Packit |
4e910c |
[[CFPreferencesCopyAppValue(NULL, NULL)]])],
|
|
Packit |
4e910c |
[gt_cv_func_CFPreferencesCopyAppValue=yes],
|
|
Packit |
4e910c |
[gt_cv_func_CFPreferencesCopyAppValue=no])
|
|
Packit |
4e910c |
LIBS="$gt_save_LIBS"])
|
|
Packit |
4e910c |
if test $gt_cv_func_CFPreferencesCopyAppValue = yes; then
|
|
Packit |
4e910c |
AC_DEFINE([HAVE_CFPREFERENCESCOPYAPPVALUE], [1],
|
|
Packit |
4e910c |
[Define to 1 if you have the Mac OS X function CFPreferencesCopyAppValue in the CoreFoundation framework.])
|
|
Packit |
4e910c |
fi
|
|
Packit |
4e910c |
dnl Check for API introduced in Mac OS X 10.3.
|
|
Packit |
4e910c |
AC_CACHE_CHECK([for CFLocaleCopyCurrent], [gt_cv_func_CFLocaleCopyCurrent],
|
|
Packit |
4e910c |
[gt_save_LIBS="$LIBS"
|
|
Packit |
4e910c |
LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation"
|
|
Packit |
4e910c |
AC_LINK_IFELSE(
|
|
Packit |
4e910c |
[AC_LANG_PROGRAM(
|
|
Packit |
4e910c |
[[#include <CoreFoundation/CFLocale.h>]],
|
|
Packit |
4e910c |
[[CFLocaleCopyCurrent();]])],
|
|
Packit |
4e910c |
[gt_cv_func_CFLocaleCopyCurrent=yes],
|
|
Packit |
4e910c |
[gt_cv_func_CFLocaleCopyCurrent=no])
|
|
Packit |
4e910c |
LIBS="$gt_save_LIBS"])
|
|
Packit |
4e910c |
if test $gt_cv_func_CFLocaleCopyCurrent = yes; then
|
|
Packit |
4e910c |
AC_DEFINE([HAVE_CFLOCALECOPYCURRENT], [1],
|
|
Packit |
4e910c |
[Define to 1 if you have the Mac OS X function CFLocaleCopyCurrent in the CoreFoundation framework.])
|
|
Packit |
4e910c |
fi
|
|
Packit |
4e910c |
INTL_MACOSX_LIBS=
|
|
Packit |
4e910c |
if test $gt_cv_func_CFPreferencesCopyAppValue = yes || test $gt_cv_func_CFLocaleCopyCurrent = yes; then
|
|
Packit |
4e910c |
INTL_MACOSX_LIBS="-Wl,-framework -Wl,CoreFoundation"
|
|
Packit |
4e910c |
fi
|
|
Packit |
4e910c |
AC_SUBST([INTL_MACOSX_LIBS])
|
|
Packit |
4e910c |
])
|