VETO SUPERSEDES 21.5
Thanks for the reports! Sorry about this. Some not-ready-for-prime-
time changes leaked into the patch in src, and CVS (as usual)
presented the conflicts in configure.ac the most confusing possible
way.
Aidan> As well as your patch, something like the below is needed
Aidan> to compile with Xft enabled.
This patch fixes configure, also the macro in objects-x.c and removes
some redundant code (the check for debug level is done in the
DEBUG_XFT2 macro), as well as removing some dead code in xft-fonts.c
and fixing the stray DEFSUBR.
Index: ChangeLog
===================================================================
RCS file: /pack/xemacscvs/XEmacs/xemacs/ChangeLog,v
retrieving revision 1.474
diff -u -U0 -r1.474 ChangeLog
--- ChangeLog 26 Nov 2005 11:45:47 -0000 1.474
+++ ChangeLog 26 Nov 2005 17:59:05 -0000
@@ -0,0 +1,5 @@
+2005-11-27 Stephen J. Turnbull <stephen(a)xemacs.org>
+
+ * configure.ac (XE_COMPLEX_ARG[xft]): Remove merge detritus and
+ regenerate configure to fix syntax error.
+
Index: src/ChangeLog
===================================================================
RCS file: /pack/xemacscvs/XEmacs/xemacs/src/ChangeLog,v
retrieving revision 1.894
diff -u -r1.894 ChangeLog
--- src/ChangeLog 26 Nov 2005 13:20:21 -0000 1.894
+++ src/ChangeLog 26 Nov 2005 17:41:16 -0000
@@ -0,0 +1,11 @@
+2005-11-27 Stephen J. Turnbull <stephen(a)xemacs.org>
+
+ Build fixes and dead code removal.
+
+ * xft-fonts.c (Ffc_pattern_destroy): Delete.
+ (syms_of_xft_fonts): Delete Ffc_pattern_destroy and comment out
+ Fxft_name_unparse.
+
+ * objects-x.c (DECLARE_DEBUG_FONTNAME): Renamed improved
+ SET_DEBUG_FONTNAME. Remove redundant debug level checks.
+
Index: configure.ac
===================================================================
RCS file: /pack/xemacscvs/XEmacs/xemacs/configure.ac,v
retrieving revision 1.23
diff -u -r1.23 configure.ac
--- configure.ac 26 Nov 2005 11:45:48 -0000 1.23
+++ configure.ac 26 Nov 2005 17:59:14 -0000
@@ -643,7 +643,6 @@
XE_COMPLEX_OPTION([menubars],[yes]),
XE_COMPLEX_OPTION([tabs],[yes]),
XE_COMPLEX_OPTION([gauges],[yes])])
- [], [])
XE_MERGED_ARG([gtk],
AC_HELP_STRING([--with-gtk],[Support GTK on the X Window System. (EXPERIMENTAL)]),
[true], [with_gtk=no])
Index: objects-x.c
===================================================================
RCS file: /pack/xemacscvs/XEmacs/xemacs/src/objects-x.c,v
retrieving revision 1.29
diff -u -r1.29 objects-x.c
--- objects-x.c 26 Nov 2005 11:46:09 -0000 1.29
+++ objects-x.c 26 Nov 2005 18:13:26 -0000
@@ -1155,11 +1155,14 @@
/* Choose appropriate font name for debug messages.
Use only in the top half of next function (enforced with #undef). */
-#define SET_DEBUG_FONTNAME(name) \
- do { name = \
- debug_xft > 2 ? eistr_fullname \
-: debug_xft > 1 ? eistr_longname \
-: eistr_shortname } while (0)
+#define DECLARE_DEBUG_FONTNAME(__xemacs_name) \
+ Eistring *__xemacs_name; \
+ do \
+ { \
+ __xemacs_name = debug_xft > 2 ? eistr_fullname \
+: debug_xft > 1 ? eistr_longname \
+: eistr_shortname; \
+ } while (0)
#endif /* USE_XFT */
@@ -1302,11 +1305,8 @@
if (cr->rfc3066)
{
- if (debug_xft > 0)
- {
- SET_DEBUG_FONTNAME (name);
- CHECKING_LANG (0, eidata(name), cr->language);
- }
+ DECLARE_DEBUG_FONTNAME (name);
+ CHECKING_LANG (0, eidata(name), cr->language);
lang = cr->rfc3066;
}
else if (cr->charset)
@@ -1348,12 +1348,9 @@
should have the full thing internally as truename, and
filter stuff the client doesn't want to see on output.
Should we just store it into the truename right here? */
- if (debug_xft > 0)
- {
- SET_DEBUG_FONTNAME (name);
- DEBUG_XFT2 (0, "Xft font %s supports %s\n",
- eidata(name), lang);
- }
+ DECLARE_DEBUG_FONTNAME (name);
+ DEBUG_XFT2 (0, "Xft font %s supports %s\n",
+ eidata(name), lang);
#ifdef RETURN_LONG_FONTCONFIG_NAMES
result = eimake_string(eistr_fullname);
#else
@@ -1362,12 +1359,9 @@
}
else
{
- if (debug_xft > 0)
- {
- SET_DEBUG_FONTNAME (name);
- DEBUG_XFT2 (0, "Xft font %s doesn't support %s\n",
- eidata(name), lang);
- }
+ DECLARE_DEBUG_FONTNAME (name);
+ DEBUG_XFT2 (0, "Xft font %s doesn't support %s\n",
+ eidata(name), lang);
result = Qnil;
}
@@ -1394,12 +1388,9 @@
}
else if (FcLangSetHasLang (v.u.l, lang) != FcLangDifferentLang)
{
- if (debug_xft > 0)
- {
- SET_DEBUG_FONTNAME (name);
- DEBUG_XFT2 (0, "Xft font %s supports %s\n",
- eidata(name), lang);
- }
+ DECLARE_DEBUG_FONTNAME (name);
+ DEBUG_XFT2 (0, "Xft font %s supports %s\n",
+ eidata(name), lang);
#ifdef RETURN_LONG_FONTCONFIG_NAMES
result = eimake_string(eistr_fullname);
#else
@@ -1408,12 +1399,9 @@
}
else
{
- if (debug_xft > 0)
- {
- SET_DEBUG_FONTNAME (name);
- DEBUG_XFT2 (0, "Xft font %s doesn't support %s\n",
- eidata(name), lang);
- }
+ DECLARE_DEBUG_FONTNAME (name);
+ DEBUG_XFT2 (0, "Xft font %s doesn't support %s\n",
+ eidata(name), lang);
result = Qnil;
}
}
@@ -1434,7 +1422,7 @@
DEBUG_XFT1 (0, "shit happens, try X11 charset match for %s\n",
XSTRING_DATA(font));
-#undef SET_DEBUG_FONTNAME
+#undef DECLARE_DEBUG_FONTNAME
#endif /* USE_XFT */
LISP_STRING_TO_EXTERNAL (font, patternext, Qx_font_name_encoding);
Index: src/xft-fonts.c
===================================================================
RCS file: /pack/xemacscvs/XEmacs/xemacs/src/xft-fonts.c,v
retrieving revision 1.2
diff -u -r1.2 xft-fonts.c
--- src/xft-fonts.c 26 Nov 2005 11:46:11 -0000 1.2
+++ src/xft-fonts.c 26 Nov 2005 17:41:18 -0000
@@ -463,25 +463,6 @@
}
}
-#if 0
-/* #### delete this after some testing!! don't forget the DEFSUBR */
-/* #### This is a big mistake, no? --- crap, there's no implicit finalizer */
-DEFUN("fc-pattern-destroy", Ffc_pattern_destroy, 1, 1, 0, /*
-Explicitly deallocate a fc pattern object PATTERN. */
- (pattern))
-{
- CHECK_FCPATTERN(pattern);
-
- /* paranoia strikes deep */
- if (XFCPATTERN_PTR(pattern))
- {
- FcPatternDestroy(XFCPATTERN_PTR(pattern));
- XFCPATTERN_PTR(pattern) = 0;
- }
- return Qnil;
-}
-#endif
-
DEFUN("fc-font-match", Ffc_font_match, 2, 2, 0, /*
Return the font on DEVICE that most closely matches PATTERN.
@@ -785,14 +766,13 @@
DEFSUBR(Ffc_pattern_create);
DEFSUBR(Ffc_name_parse);
DEFSUBR(Ffc_name_unparse);
+#if 0
DEFSUBR(Fxft_name_unparse); /* URK! */
+#endif
DEFSUBR(Ffc_pattern_duplicate);
DEFSUBR(Ffc_pattern_add);
DEFSUBR(Ffc_pattern_del);
DEFSUBR(Ffc_pattern_get);
-#if 0
- DEFSUBR(Ffc_pattern_destroy);
-#endif
DEFSUBR(Ffc_list_fonts_pattern_objects);
DEFSUBR(Ffc_font_sort);
DEFSUBR(Ffc_font_match);
--
School of Systems and Information Engineering
http://turnbull.sk.tsukuba.ac.jp
University of Tsukuba Tennodai 1-1-1 Tsukuba 305-8573 JAPAN
Ask not how you can "do" free software business;
ask what your business can "do for" free software.