1# This file is part of the FreeType project. 2# 3# Process this file with autoconf to produce a configure script. 4# 5# Copyright 2001-2013 by 6# David Turner, Robert Wilhelm, and Werner Lemberg. 7# 8# This file is part of the FreeType project, and may only be used, modified, 9# and distributed under the terms of the FreeType project license, 10# LICENSE.TXT. By continuing to use, modify, or distribute this file you 11# indicate that you have read the license and understand and accept it 12# fully. 13 14AC_INIT([FreeType], [2.4.12], [freetype@nongnu.org], [freetype]) 15AC_CONFIG_SRCDIR([ftconfig.in]) 16 17 18# Don't forget to update docs/VERSION.DLL! 19 20version_info='16:1:10' 21AC_SUBST([version_info]) 22ft_version=`echo $version_info | tr : .` 23AC_SUBST([ft_version]) 24 25 26# checks for system type 27 28AC_CANONICAL_HOST 29 30 31# checks for programs 32 33AC_PROG_CC 34AC_PROG_CPP 35AC_SUBST(EXEEXT) 36 37 38# checks for native programs to generate building tool 39 40if test ${cross_compiling} = yes; then 41 AC_CHECK_PROG(CC_BUILD, ${build}-gcc, ${build}-gcc) 42 test -z "${CC_BUILD}" && AC_CHECK_PROG(CC_BUILD, gcc, gcc) 43 test -z "${CC_BUILD}" && AC_CHECK_PROG(CC_BUILD, cc, cc, , , /usr/ucb/cc) 44 test -z "${CC_BUILD}" && AC_MSG_ERROR([cannot find native C compiler]) 45 46 AC_MSG_CHECKING([for suffix of native executables]) 47 rm -f a.* b.* a_out.exe conftest.* 48 echo > conftest.c "int main() { return 0;}" 49 ${CC_BUILD} conftest.c || AC_MSG_ERROR([native C compiler is not working]) 50 rm -f conftest.c 51 if test -x a.out -o -x b.out -o -x conftest; then 52 EXEEXT_BUILD="" 53 elif test -x a_out.exe -o -x conftest.exe; then 54 EXEEXT_BUILD=".exe" 55 elif test -x conftest.*; then 56 EXEEXT_BUILD=`echo conftest.* | sed -n '1s/^.*\././'` 57 fi 58 rm -f a.* b.* a_out.exe conftest.* 59 AC_MSG_RESULT($EXEEXT_BUILD) 60else 61 CC_BUILD=${CC} 62 EXEEXT_BUILD=${EXEEXT} 63fi 64 65AC_SUBST(CC_BUILD) 66AC_SUBST(EXEEXT_BUILD) 67 68 69# auxiliary programs 70 71AC_CHECK_PROG([RMDIR], [rmdir], [rmdir]) 72 73 74# Since this file will be finally moved to another directory we make 75# the path of the install script absolute. This small code snippet has 76# been taken from automake's `ylwrap' script. 77 78AC_PROG_INSTALL 79case "$INSTALL" in 80/*) 81 ;; 82*/*) 83 INSTALL="`pwd`/$INSTALL" 84 ;; 85esac 86 87 88# checks for header files 89 90AC_HEADER_STDC 91AC_CHECK_HEADERS([fcntl.h unistd.h]) 92 93 94# checks for typedefs, structures, and compiler characteristics 95 96AC_C_CONST 97AC_CHECK_SIZEOF([int]) 98AC_CHECK_SIZEOF([long]) 99 100 101# check whether cpp computation of size of int and long in ftconfig.in works 102 103AC_MSG_CHECKING([whether cpp computation of bit length in ftconfig.in works]) 104orig_CPPFLAGS="${CPPFLAGS}" 105CPPFLAGS="-I${srcdir} -I. ${CPPFLAGS}" 106 107ac_clean_files= 108for f in ft2build.h ftoption.h ftstdlib.h; do 109 if test ! -f $f; then 110 ac_clean_files="$ac_clean_files $f" 111 touch $f 112 fi 113done 114 115cat > conftest.c <<\_ACEOF 116#include <limits.h> 117#define FT_CONFIG_OPTIONS_H "ftoption.h" 118#define FT_CONFIG_STANDARD_LIBRARY_H "ftstdlib.h" 119#define FT_UINT_MAX UINT_MAX 120#define FT_ULONG_MAX ULONG_MAX 121#include "ftconfig.in" 122_ACEOF 123echo >> conftest.c "#if FT_SIZEOF_INT == "${ac_cv_sizeof_int} 124echo >> conftest.c "ac_cpp_ft_sizeof_int="${ac_cv_sizeof_int} 125echo >> conftest.c "#endif" 126echo >> conftest.c "#if FT_SIZEOF_LONG == "${ac_cv_sizeof_long} 127echo >> conftest.c "ac_cpp_ft_sizeof_long="${ac_cv_sizeof_long} 128echo >> conftest.c "#endif" 129 130${CPP} ${CPPFLAGS} conftest.c | ${GREP} ac_cpp_ft > conftest.sh 131eval `cat conftest.sh` 132rm -f conftest.* $ac_clean_files 133 134if test x != "x${ac_cpp_ft_sizeof_int}" \ 135 -a x != x"${ac_cpp_ft_sizeof_long}"; then 136 unset ft_use_autoconf_sizeof_types 137else 138 ft_use_autoconf_sizeof_types=yes 139fi 140 141AC_ARG_ENABLE(biarch-config, 142[ --enable-biarch-config install biarch ftconfig.h to support multiple 143 architectures by single file], [], []) 144 145case :${ft_use_autoconf_sizeof_types}:${enable_biarch_config}: in 146 :yes:yes:) 147 AC_MSG_RESULT([broken but use it]) 148 unset ft_use_autoconf_sizeof_types 149 ;; 150 ::no:) 151 AC_MSG_RESULT([works but ignore it]) 152 ft_use_autoconf_sizeof_types=yes 153 ;; 154 ::yes: | :::) 155 AC_MSG_RESULT([yes]) 156 unset ft_use_autoconf_sizeof_types 157 ;; 158 *) 159 AC_MSG_RESULT([no]) 160 ft_use_autoconf_sizeof_types=yes 161 ;; 162esac 163 164if test x"${ft_use_autoconf_sizeof_types}" = xyes; then 165 AC_DEFINE([FT_USE_AUTOCONF_SIZEOF_TYPES], [], 166 [Define if autoconf sizeof types should be used.]) 167fi 168 169CPPFLAGS="${orig_CPPFLAGS}" 170 171 172# checks for library functions 173 174# Here we check whether we can use our mmap file component. 175 176AC_ARG_ENABLE([mmap], 177 AS_HELP_STRING([--disable-mmap], 178 [do not check mmap() and do not use]), 179 [enable_mmap="no"],[enable_mmap="yes"]) 180if test "x${enable_mmap}" != "xno"; then 181 AC_FUNC_MMAP 182fi 183if test "x${enable_mmap}" = "xno" \ 184 -o "$ac_cv_func_mmap_fixed_mapped" != "yes"; then 185 FTSYS_SRC='$(BASE_DIR)/ftsystem.c' 186else 187 FTSYS_SRC='$(BUILD_DIR)/ftsystem.c' 188 189 AC_CHECK_DECLS([munmap], 190 [], 191 [], 192 [ 193 194#ifdef HAVE_UNISTD_H 195#include <unistd.h> 196#endif 197#include <sys/mman.h> 198 199 ]) 200 201 FT_MUNMAP_PARAM 202fi 203AC_SUBST([FTSYS_SRC]) 204 205AC_CHECK_FUNCS([memcpy memmove]) 206 207 208# get compiler flags right 209# we try to make the compiler work for C89-strict source. 210# even if C compiler is GCC and C89 flags are available, 211# some system headers (e.g. Android Bionic libc) is broken 212# in C89 mode. we have to check the compilation finishes 213# successfully. 214# 215if test "x$GCC" = xyes; then 216 XX_CFLAGS="-Wall" 217 XX_ANSIFLAGS="" 218 for a in -pedantic -ansi 219 do 220 AC_MSG_CHECKING([gcc compiler flag ${a} to assure ANSI C works correctly]) 221 orig_CFLAGS="${CFLAGS}" 222 CFLAGS="${CFLAGS} ${XX_ANSIFLAGS} ${a}" 223 AC_COMPILE_IFELSE([ 224 AC_LANG_PROGRAM([#include <stdio.h>],[{puts("");return 0;}]) 225 ],[ 226 AC_MSG_RESULT([ok, add it to XX_ANSIFLAGS]) 227 XX_ANSIFLAGS="${XX_ANSIFLAGS} ${a}" 228 ],[ 229 AC_MSG_RESULT([no]) 230 ]) 231 CFLAGS="${orig_CFLAGS}" 232 done 233else 234 case "$host" in 235 *-dec-osf*) 236 CFLAGS= 237 XX_CFLAGS="-std1 -g3" 238 XX_ANSIFLAGS= 239 ;; 240 *) 241 XX_CFLAGS= 242 XX_ANSIFLAGS= 243 ;; 244 esac 245fi 246AC_SUBST([XX_CFLAGS]) 247AC_SUBST([XX_ANSIFLAGS]) 248 249 250# check for system zlib 251 252# don't quote AS_HELP_STRING! 253AC_ARG_WITH([zlib], 254 AS_HELP_STRING([--without-zlib], 255 [use internal zlib instead of system-wide])) 256if test x$with_zlib != xno && test -z "$LIBZ"; then 257 AC_CHECK_LIB([z], [gzsetparams], [AC_CHECK_HEADER([zlib.h], [LIBZ='-lz'])]) 258fi 259if test x$with_zlib != xno && test -n "$LIBZ"; then 260 SYSTEM_ZLIB=yes 261fi 262 263# check for system libbz2 264 265# don't quote AS_HELP_STRING! 266AC_ARG_WITH([bzip2], 267 AS_HELP_STRING([--without-bzip2], 268 [do not support bzip2 compressed fonts])) 269if test x$with_bzip2 != xno && test -z "$LIBBZ2"; then 270 AC_CHECK_LIB([bz2], [BZ2_bzDecompress], [AC_CHECK_HEADER([bzlib.h], [LIBBZ2='-lbz2'])]) 271fi 272if test x$with_bzip2 != xno && test -n "$LIBBZ2"; then 273 SYSTEM_LIBBZ2=yes 274fi 275 276# Some options handling SDKs/archs in CFLAGS should be copied 277# to LDFLAGS. Apple TechNote 2137 recommends to include these 278# options in CFLAGS but not in LDFLAGS. 279 280save_config_args=$* 281set dummy ${CFLAGS} 282i=1 283while test $i -le $# 284do 285 c=$1 286 287 case "${c}" in 288 -isysroot|-arch) # options taking 1 argument 289 a=$2 290 AC_MSG_CHECKING([whether CFLAGS and LDFLAGS share ${c} ${a}]) 291 if expr " ${LDFLAGS} " : ".* ${c} *${a}.*" > /dev/null 292 then 293 AC_MSG_RESULT([yes]) 294 else 295 AC_MSG_RESULT([no, copy to LDFLAGS]) 296 LDFLAGS="${LDFLAGS} ${c} ${a}" 297 fi 298 shift 1 299 ;; 300 -m32|-m64|-march=*|-mcpu=*) # options taking no argument 301 AC_MSG_CHECKING([whether CFLAGS and LDFLAGS share ${c}]) 302 if expr " ${LDFLAGS} " : ".* ${c} *${a}.*" > /dev/null 303 then 304 AC_MSG_RESULT([yes]) 305 else 306 AC_MSG_RESULT([no, copy to LDFLAGS]) 307 LDFLAGS="${LDFLAGS} ${c}" 308 fi 309 ;; 310 # *) 311 # AC_MSG_RESULT([${c} is not copied to LDFLAGS]) 312 # ;; 313 esac 314 315 shift 1 316done 317set ${save_config_args} 318 319 320# Whether to use Mac OS resource-based fonts. 321 322ftmac_c="" # src/base/ftmac.c should not be included in makefiles by default 323 324# don't quote AS_HELP_STRING! 325AC_ARG_WITH([old-mac-fonts], 326 AS_HELP_STRING([--with-old-mac-fonts], 327 [allow Mac resource-based fonts to be used])) 328if test x$with_old_mac_fonts = xyes; then 329 orig_LDFLAGS="${LDFLAGS}" 330 AC_MSG_CHECKING([CoreServices & ApplicationServices of Mac OS X]) 331 FT2_EXTRA_LIBS="-Wl,-framework,CoreServices -Wl,-framework,ApplicationServices" 332 LDFLAGS="$LDFLAGS $FT2_EXTRA_LIBS" 333 AC_LINK_IFELSE([ 334 AC_LANG_PROGRAM([ 335 336#if defined(__GNUC__) && defined(__APPLE_CC__) 337# include <CoreServices/CoreServices.h> 338# include <ApplicationServices/ApplicationServices.h> 339#else 340# include <ConditionalMacros.h> 341# include <Files.h> 342#endif 343 344 ], 345 [ 346 347 short res = 0; 348 349 350 UseResFile( res ); 351 352 ])], 353 [AC_MSG_RESULT([ok]) 354 ftmac_c='ftmac.c' 355 AC_MSG_CHECKING([whether OS_INLINE macro is ANSI compatible]) 356 orig_CFLAGS="$CFLAGS -DFT_MACINTOSH" 357 CFLAGS="$CFLAGS $XX_CFLAGS $XX_ANSIFLAGS" 358 AC_COMPILE_IFELSE([ 359 AC_LANG_PROGRAM([ 360 361#if defined(__GNUC__) && defined(__APPLE_CC__) 362# include <CoreServices/CoreServices.h> 363# include <ApplicationServices/ApplicationServices.h> 364#else 365# include <ConditionalMacros.h> 366# include <Files.h> 367#endif 368 369 ], 370 [ 371 372 /* OSHostByteOrder() is typed as OS_INLINE */ 373 int32_t os_byte_order = OSHostByteOrder(); 374 375 376 if ( OSBigEndian != os_byte_order ) 377 return 1; 378 379 ])], 380 [AC_MSG_RESULT([ok]) 381 CFLAGS="$orig_CFLAGS" 382 CFLAGS="$CFLAGS -DHAVE_ANSI_OS_INLINE=1" 383 ], 384 [AC_MSG_RESULT([no, ANSI incompatible]) 385 CFLAGS="$orig_CFLAGS" 386 ]) 387 AC_MSG_CHECKING([type ResourceIndex]) 388 orig_CFLAGS="$CFLAGS" 389 CFLAGS="$CFLAGS $XX_CFLAGS $XX_ANSIFLAGS" 390 AC_COMPILE_IFELSE([ 391 AC_LANG_PROGRAM([ 392 393#if defined(__GNUC__) && defined(__APPLE_CC__) 394# include <CoreServices/CoreServices.h> 395# include <ApplicationServices/ApplicationServices.h> 396#else 397# include <ConditionalMacros.h> 398# include <Files.h> 399# include <Resources.h> 400#endif 401 402 ], 403 [ 404 405 ResourceIndex i = 0; 406 return i; 407 408 ])], 409 [AC_MSG_RESULT([ok]) 410 CFLAGS="$orig_CFLAGS" 411 CFLAGS="$CFLAGS -DHAVE_TYPE_RESOURCE_INDEX=1" 412 ], 413 [AC_MSG_RESULT([no]) 414 CFLAGS="$orig_CFLAGS" 415 CFLAGS="$CFLAGS -DHAVE_TYPE_RESOURCE_INDEX=0" 416 ])], 417 [AC_MSG_RESULT([not found]) 418 FT2_EXTRA_LIBS="" 419 LDFLAGS="${orig_LDFLAGS}" 420 CFLAGS="$CFLAGS -DDARWIN_NO_CARBON"]) 421else 422 case x$host_os in 423 xdarwin*) 424 dnl AC_MSG_WARN([host system is MacOS but configured to build without Carbon]) 425 CFLAGS="$CFLAGS -DDARWIN_NO_CARBON" 426 ;; 427 *) 428 ;; 429 esac 430fi 431 432 433# Whether to use FileManager which is deprecated since Mac OS X 10.4. 434 435AC_ARG_WITH([fsspec], 436 AS_HELP_STRING([--with-fsspec], 437 [use obsolete FSSpec API of MacOS, if available (default=yes)])) 438if test x$with_fsspec = xno; then 439 CFLAGS="$CFLAGS -DHAVE_FSSPEC=0" 440elif test x$with_old_mac_fonts = xyes -a x$with_fsspec != x; then 441 AC_MSG_CHECKING([FSSpec-based FileManager]) 442 AC_LINK_IFELSE([ 443 AC_LANG_PROGRAM([ 444 445#if defined(__GNUC__) && defined(__APPLE_CC__) 446# include <CoreServices/CoreServices.h> 447# include <ApplicationServices/ApplicationServices.h> 448#else 449# include <ConditionalMacros.h> 450# include <Files.h> 451#endif 452 453 ], 454 [ 455 456 FCBPBPtr paramBlock; 457 short vRefNum; 458 long dirID; 459 ConstStr255Param fileName; 460 FSSpec* spec; 461 462 463 /* FSSpec functions: deprecated since Mac OS X 10.4 */ 464 PBGetFCBInfoSync( paramBlock ); 465 FSMakeFSSpec( vRefNum, dirID, fileName, spec ); 466 467 ])], 468 [AC_MSG_RESULT([ok]) 469 CFLAGS="$CFLAGS -DHAVE_FSSPEC=1"], 470 [AC_MSG_RESULT([not found]) 471 CFLAGS="$CFLAGS -DHAVE_FSSPEC=0"]) 472fi 473 474 475# Whether to use FileManager in Carbon since MacOS 9.x. 476 477AC_ARG_WITH([fsref], 478 AS_HELP_STRING([--with-fsref], 479 [use Carbon FSRef API of MacOS, if available (default=yes)])) 480if test x$with_fsref = xno; then 481 AC_MSG_WARN([ 482*** WARNING 483 FreeType2 built without FSRef API cannot load 484 data-fork fonts on MacOS, except of XXX.dfont. 485 ]) 486 CFLAGS="$CFLAGS -DHAVE_FSREF=0" 487elif test x$with_old_mac_fonts = xyes -a x$with_fsref != x; then 488 AC_MSG_CHECKING([FSRef-based FileManager]) 489 AC_LINK_IFELSE([ 490 AC_LANG_PROGRAM([ 491 492#if defined(__GNUC__) && defined(__APPLE_CC__) 493# include <CoreServices/CoreServices.h> 494# include <ApplicationServices/ApplicationServices.h> 495#else 496# include <ConditionalMacros.h> 497# include <Files.h> 498#endif 499 500 ], 501 [ 502 503 short vRefNum; 504 long dirID; 505 ConstStr255Param fileName; 506 507 Boolean* isDirectory; 508 UInt8* path; 509 SInt16 desiredRefNum; 510 SInt16* iterator; 511 SInt16* actualRefNum; 512 HFSUniStr255* outForkName; 513 FSVolumeRefNum volume; 514 FSCatalogInfoBitmap whichInfo; 515 FSCatalogInfo* catalogInfo; 516 FSForkInfo* forkInfo; 517 FSRef* ref; 518 519#if HAVE_FSSPEC 520 FSSpec* spec; 521#endif 522 523 /* FSRef functions: no need to check? */ 524 FSGetForkCBInfo( desiredRefNum, volume, iterator, 525 actualRefNum, forkInfo, ref, 526 outForkName ); 527 FSPathMakeRef( path, ref, isDirectory ); 528 529#if HAVE_FSSPEC 530 FSpMakeFSRef ( spec, ref ); 531 FSGetCatalogInfo( ref, whichInfo, catalogInfo, 532 outForkName, spec, ref ); 533#endif 534 ])], 535 [AC_MSG_RESULT([ok]) 536 CFLAGS="$CFLAGS -DHAVE_FSREF=1"], 537 [AC_MSG_RESULT([not found]) 538 CFLAGS="$CFLAGS -DHAVE_FSREF=0"]) 539fi 540 541 542# Whether to use QuickDraw API in ToolBox which is deprecated since 543# Mac OS X 10.4. 544 545AC_ARG_WITH([quickdraw-toolbox], 546 AS_HELP_STRING([--with-quickdraw-toolbox], 547 [use MacOS QuickDraw in ToolBox, if available (default=yes)])) 548if test x$with_quickdraw_toolbox = xno; then 549 CFLAGS="$CFLAGS -DHAVE_QUICKDRAW_TOOLBOX=0" 550elif test x$with_old_mac_fonts = xyes -a x$with_quickdraw_toolbox != x; then 551 AC_MSG_CHECKING([QuickDraw FontManager functions in ToolBox]) 552 AC_LINK_IFELSE([ 553 AC_LANG_PROGRAM([ 554 555#if defined(__GNUC__) && defined(__APPLE_CC__) 556# include <CoreServices/CoreServices.h> 557# include <ApplicationServices/ApplicationServices.h> 558#else 559# include <ConditionalMacros.h> 560# include <Fonts.h> 561#endif 562 563 ], 564 [ 565 566 Str255 familyName; 567 SInt16 familyID = 0; 568 FMInput* fmIn = NULL; 569 FMOutput* fmOut = NULL; 570 571 572 GetFontName( familyID, familyName ); 573 GetFNum( familyName, &familyID ); 574 fmOut = FMSwapFont( fmIn ); 575 576 ])], 577 [AC_MSG_RESULT([ok]) 578 CFLAGS="$CFLAGS -DHAVE_QUICKDRAW_TOOLBOX=1"], 579 [AC_MSG_RESULT([not found]) 580 CFLAGS="$CFLAGS -DHAVE_QUICKDRAW_TOOLBOX=0"]) 581fi 582 583 584# Whether to use QuickDraw API in Carbon which is deprecated since 585# Mac OS X 10.4. 586 587AC_ARG_WITH([quickdraw-carbon], 588 AS_HELP_STRING([--with-quickdraw-carbon], 589 [use MacOS QuickDraw in Carbon, if available (default=yes)])) 590if test x$with_quickdraw_carbon = xno; then 591 CFLAGS="$CFLAGS -DHAVE_QUICKDRAW_CARBON=0" 592elif test x$with_old_mac_fonts = xyes -a x$with_quickdraw_carbon != x; then 593 AC_MSG_CHECKING([QuickDraw FontManager functions in Carbon]) 594 AC_LINK_IFELSE([ 595 AC_LANG_PROGRAM([ 596 597#if defined(__GNUC__) && defined(__APPLE_CC__) 598# include <CoreServices/CoreServices.h> 599# include <ApplicationServices/ApplicationServices.h> 600#else 601# include <ConditionalMacros.h> 602# include <Fonts.h> 603#endif 604 605 ], 606 [ 607 608 FMFontFamilyIterator famIter; 609 FMFontFamily family; 610 Str255 famNameStr; 611 FMFontFamilyInstanceIterator instIter; 612 FMFontStyle style; 613 FMFontSize size; 614 FMFont font; 615 FSSpec* pathSpec; 616 617 618 FMCreateFontFamilyIterator( NULL, NULL, kFMUseGlobalScopeOption, 619 &famIter ); 620 FMGetNextFontFamily( &famIter, &family ); 621 FMGetFontFamilyName( family, famNameStr ); 622 FMCreateFontFamilyInstanceIterator( family, &instIter ); 623 FMGetNextFontFamilyInstance( &instIter, &font, &style, &size ); 624 FMDisposeFontFamilyInstanceIterator( &instIter ); 625 FMDisposeFontFamilyIterator( &famIter ); 626 FMGetFontContainer( font, pathSpec ); 627 628 ])], 629 [AC_MSG_RESULT([ok]) 630 CFLAGS="$CFLAGS -DHAVE_QUICKDRAW_CARBON=1"], 631 [AC_MSG_RESULT([not found]) 632 CFLAGS="$CFLAGS -DHAVE_QUICKDRAW_CARBON=0"]) 633fi 634 635 636# Whether to use AppleTypeService since Mac OS X. 637 638# don't quote AS_HELP_STRING! 639AC_ARG_WITH([ats], 640 AS_HELP_STRING([--with-ats], 641 [use AppleTypeService, if available (default=yes)])) 642if test x$with_ats = xno; then 643 CFLAGS="$CFLAGS -DHAVE_ATS=0" 644elif test x$with_old_mac_fonts = xyes -a x$with_ats != x; then 645 AC_MSG_CHECKING([AppleTypeService functions]) 646 AC_LINK_IFELSE([ 647 AC_LANG_PROGRAM([ 648 649#if defined(__GNUC__) && defined(__APPLE_CC__) 650# include <CoreServices/CoreServices.h> 651# include <ApplicationServices/ApplicationServices.h> 652#else 653# include <ConditionalMacros.h> 654# include <Files.h> 655#endif 656 657 ], 658 [ 659 660 FSSpec* pathSpec; 661 662 663 ATSFontFindFromName( NULL, kATSOptionFlagsUnRestrictedScope ); 664#if HAVE_FSSPEC 665 ATSFontGetFileSpecification( 0, pathSpec ); 666#endif 667 668 ])], 669 [AC_MSG_RESULT([ok]) 670 CFLAGS="$CFLAGS -DHAVE_ATS=1"], 671 [AC_MSG_RESULT([not found]) 672 CFLAGS="$CFLAGS -DHAVE_ATS=0"]) 673fi 674 675case "$CFLAGS" in 676 *HAVE_FSSPEC* | *HAVE_FSREF* | *HAVE_QUICKDRAW* | *HAVE_ATS* ) 677 AC_MSG_WARN([ 678*** WARNING 679 FSSpec/FSRef/QuickDraw/ATS options are explicitly given, 680 thus it is recommended to replace src/base/ftmac.c by builds/mac/ftmac.c. 681 ]) 682 CFLAGS="$CFLAGS "'-I$(TOP_DIR)/builds/mac/' 683 ;; 684 *) 685 ;; 686esac 687 688 689AC_SUBST([ftmac_c]) 690AC_SUBST([LIBZ]) 691AC_SUBST([LIBBZ2]) 692AC_SUBST([FT2_EXTRA_LIBS]) 693AC_SUBST([SYSTEM_ZLIB]) 694 695LT_INIT(win32-dll) 696 697AC_SUBST([hardcode_libdir_flag_spec]) 698AC_SUBST([wl]) 699AC_SUBST([build_libtool_libs]) 700 701# changing LDFLAGS value should only be done after 702# lt_cv_prog_compiler_static_works test 703if test x$SYSTEM_ZLIB = xyes; then 704 CFLAGS="$CFLAGS -DFT_CONFIG_OPTION_SYSTEM_ZLIB" 705 LDFLAGS="$LDFLAGS $LIBZ" 706fi 707 708if test x$SYSTEM_LIBBZ2 = xyes; then 709 CFLAGS="$CFLAGS -DFT_CONFIG_OPTION_USE_BZIP2" 710 LDFLAGS="$LDFLAGS $LIBBZ2" 711fi 712 713AC_SUBST([CFLAGS]) 714AC_SUBST([LDFLAGS]) 715 716# configuration file -- stay in 8.3 limit 717# 718# since #undef doesn't survive in configuration header files we replace 719# `/undef' with `#undef' after creating the output file 720 721AC_CONFIG_HEADERS([ftconfig.h:ftconfig.in], 722 [mv ftconfig.h ftconfig.tmp 723 sed 's|/undef|#undef|' < ftconfig.tmp > ftconfig.h 724 rm ftconfig.tmp]) 725 726# create the Unix-specific sub-Makefiles `builds/unix/unix-def.mk' 727# and `builds/unix/unix-cc.mk' that will be used by the build system 728# 729AC_CONFIG_FILES([unix-cc.mk:unix-cc.in 730 unix-def.mk:unix-def.in]) 731 732# re-generate the Jamfile to use libtool now 733# 734# AC_CONFIG_FILES([../../Jamfile:../../Jamfile.in]) 735 736AC_OUTPUT 737 738# end of configure.raw 739