diff --git a/ChangeLog b/ChangeLog index 09486ada7..a8d0f4023 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,15 @@ +2008-09-30 suzuki toshiya + + * src/base/rules.mk: Add conditional source to BASE_SRC, for + `make multi' on Mac OS X. If the macro $(ftmac_c) is defined, + $(BASE_DIR)/$(ftmac_c) is added to BASE_SRC. In normal build, + the lack of ftmac.c in BASE_SRC is not serious because ftbase.c + includes ftmac.c. + * builds/unix/unix-def.in: Add a macro definition of $(ftmac_c). + * builds/unix/configure.raw: Add procedure to set up appropriate + value of $(ftmac_c) with the consideration of the availability + of Carbon framework. + 2008-09-30 suzuki toshiya * src/base/Jamfile: Add target for multi build by jam on Mac OS X. diff --git a/builds/unix/configure.raw b/builds/unix/configure.raw index 5f48d8205..d5b053a8e 100644 --- a/builds/unix/configure.raw +++ b/builds/unix/configure.raw @@ -263,6 +263,8 @@ esac # Whether to use Mac OS resource-based fonts. +ftmac_c="" # src/base/ftmac.c should not be included in makefiles by default + # don't quote AS_HELP_STRING! AC_ARG_WITH([old-mac-fonts], AS_HELP_STRING([--with-old-mac-fonts], @@ -293,6 +295,7 @@ if test x$with_old_mac_fonts = xyes; then ])], [AC_MSG_RESULT([ok]) + ftmac_c='ftmac.c' AC_MSG_CHECKING([OS_INLINE macro is ANSI compatible]) orig_CFLAGS="$CFLAGS" CFLAGS="$CFLAGS $XX_CFLAGS $XX_ANSIFLAGS" @@ -626,6 +629,7 @@ case "$CFLAGS" in esac +AC_SUBST([ftmac_c]) AC_SUBST([LIBZ]) AC_SUBST([CFLAGS]) AC_SUBST([LDFLAGS]) diff --git a/builds/unix/unix-def.in b/builds/unix/unix-def.in index b90ed0c4c..3a499e7ba 100644 --- a/builds/unix/unix-def.in +++ b/builds/unix/unix-def.in @@ -65,6 +65,10 @@ version_info := @version_info@ # LIB_DIR := $(OBJ_DIR) +# The BASE_SRC macro lists all source files that should be included in +# src/base/ftbase.c. When configure sets up CFLAGS to build ftmac.c, +# ftmac.c should be added to BASE_SRC. +ftmac_c := @ftmac_c@ # The SYSTEM_ZLIB macro is defined if the user wishes to link dynamically # with its system wide zlib. If SYSTEM_ZLIB is 'yes', the zlib part of the diff --git a/src/base/rules.mk b/src/base/rules.mk index 4a152ab44..5a89b45c4 100644 --- a/src/base/rules.mk +++ b/src/base/rules.mk @@ -47,6 +47,10 @@ BASE_SRC := $(BASE_DIR)/ftcalc.c \ $(BASE_DIR)/ftutil.c \ $(BASE_DIR)/ftadvanc.c +ifneq ($(ftmac_c),) + BASE_SRC += $(BASE_DIR)/$(ftmac_c) +endif + # Base layer `extensions' sources # # An extension is added to the library file as a separate object. It is