freetype-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[ft-devel] fix --with-old-mac-fonts option


From: mpsuzuki
Subject: [ft-devel] fix --with-old-mac-fonts option
Date: Mon, 6 Feb 2006 10:12:28 +0900

Hi all,

I'm sorry that --with-old-mac-fonts option in
configure.ac was broken by my previous jumbo
patch (to fix deprecated API issue on MacOS X).
At present, the option does not work well on
UNIX platforms. Following is patch to fix it.

Thinking of that CoreFoundation library is
published under OSI license, Carbon subset
is possible on traditional UNIX platform.
(maybe, we cannot expect opensource Quartz,
 but can expect opensource FSRef functions)
In such case, I should change linking test
for MacOS X specific LDFLAGS "-Xlinker -framework ..."
into more generic test. If anybody knows
such implementation, please let me know.

Regards,
mpsuzuki

--- freetype2.orig/builds/unix/configure.ac
+++ freetype2/builds/unix/configure.ac
@@ -140,10 +140,17 @@
   AS_HELP_STRING([--with-old-mac-fonts],
                  [allow Mac resource-based fonts to be used]))
 if test x$with_old_mac_fonts = xyes; then
+  orig_LDFLAGS="${LDFLAGS}"
+  AC_MSG_CHECKING([CoreServices & ApplicationServices of Mac OS X])
   LDFLAGS="$LDFLAGS -Xlinker -framework -Xlinker CoreServices \
                     -Xlinker -framework -Xlinker ApplicationServices"
-else
-  CFLAGS="$CFLAGS -DDARWIN_NO_CARBON"
+  AC_TRY_LINK([ ], [ ], [
+    AC_MSG_RESULT([ok])
+  ], [
+    AC_MSG_RESULT([not found])
+    LDFLAGS="${orig_LDFLAGS}"
+    CFLAGS="$CFLAGS -DDARWIN_NO_CARBON"
+  ])
 fi
 
 




reply via email to

[Prev in Thread] Current Thread [Next in Thread]