Don't define ASM_SOURCES variable globally -- reserve that variable to be defined locally by makefiles, together with C_SOURCES and CPP_SOURCES.
is basically patch #2939 from X.org bugzilla #3379. This does *not* fix the bug as it does not dynamically generate stubs at run-time. It just gets things one step closer.
EXPAT_INCLUDES config variable (set on FreeBSD) which is then used in Makefile.template's INCLUDES.