[aclocal] In generated Makefile.win32.config, don't overwrite feature vars

When I designed this first I thought people can define make vars on the
command line to override default features.  That works.  However, it's
natural to want to define the list of features in the toplevel Makefile
and not on command line.  So, we don't override user's var now.  They
can set a make feature var to 0 to disable it.
This commit is contained in:
Behdad Esfahbod 2008-09-20 18:05:01 -04:00
parent 6d0d5e7ba0
commit 9c27323959
2 changed files with 12 additions and 9 deletions

View file

@ -50,6 +50,9 @@ AC_DEFUN([CAIRO_INIT_MAKEFILES],
AM_CONDITIONAL(cr_feature_tag, [test "x$use_]cr_feature[" = xyes])dnl
])dnl
dnl An empty line per feature for readability
CAIRO_MAKEFILE_ACCUMULATE(*,[]m4_newline[])dnl
dnl Turn win32 features on
CAIRO_FEATURE_HOOK_REGISTER_WIN32(*, [_CAIRO_MAKEFILES_WIN32_DEFINE_FEATURE])dnl
])dnl
@ -58,7 +61,7 @@ m4_define([_CAIRO_MAKEFILES_WIN32_DEFINE_FEATURE],
[
m4_foreach_w([cr_makefile], _CAIRO_MAKEFILES,
[dnl
CAIRO_ACCUMULATE_UNQUOTED_UNCHECKED([MAKEFILE_]cr_makefile[_WIN32], [cr_feature_tag = 1])dnl
CAIRO_ACCUMULATE([MAKEFILE_]cr_makefile[_WIN32], [ifeq ($(]cr_feature_tag[),)]m4_newline[]cr_feature_tag[ = 1]m4_newline[endif])dnl
])dnl
])dnl

View file

@ -89,8 +89,8 @@ CAIRO_MAKEFILE_ACCUMULATE_FEATURE(*,*,*,!,
[dnl
all_$1_headers += $($1_$2_headers)
all_$1_private += $($1_$2_private)
all_$1_sources += $($1_$2_sources)
])dnl
all_$1_sources += $($1_$2_sources)]dnl
)dnl
dnl Collect list of source files for enabled public features
CAIRO_MAKEFILE_ACCUMULATE(*,
@ -104,8 +104,8 @@ CAIRO_MAKEFILE_ACCUMULATE_FEATURE(*,yes,*,!,
[dnl
enabled_$1_headers += $($1_$2_headers)
enabled_$1_private += $($1_$2_private)
enabled_$1_sources += $($1_$2_sources)
])dnl
enabled_$1_sources += $($1_$2_sources)]dnl
)dnl
dnl No public headers for private features
@ -113,15 +113,15 @@ dnl Collect list of source files for all private features
CAIRO_MAKEFILE_ACCUMULATE_FEATURE(*,*,*,,
[dnl
all_$1_private += $($1_$2_private) $($1_$2_headers)
all_$1_sources += $($1_$2_sources)
])dnl
all_$1_sources += $($1_$2_sources)]dnl
)dnl
dnl Collect list of source files for enabled private features
CAIRO_MAKEFILE_ACCUMULATE_FEATURE(*,yes,*,,
[dnl
enabled_$1_private += $($1_$2_private) $($1_$2_headers)
enabled_$1_sources += $($1_$2_sources)
])dnl
enabled_$1_sources += $($1_$2_sources)]dnl
)dnl
dnl ===========================================================================