diff options
-rw-r--r-- | ChangeLog | 13 | ||||
-rw-r--r-- | configure.in | 34 | ||||
-rw-r--r-- | modules/Makefile.am | 5 | ||||
-rw-r--r-- | pango/.cvsignore | 5 | ||||
-rw-r--r-- | pango/Makefile.am | 40 | ||||
-rw-r--r-- | pango/modules.c | 4 | ||||
-rw-r--r-- | pango/modules.h | 1 |
7 files changed, 77 insertions, 25 deletions
@@ -1,3 +1,16 @@ +2006-10-13 Behdad Esfahbod <behdad@gnome.org> + + Bug 361938 – Can't include *-lang modules (./configure + --with-included-modules fails) + + * configure.in: + * modules/Makefile.am: + * pango/.cvsignore: + * pango/Makefile.am: + * pango/modules.c (init_modules): + * pango/modules.h: + Make included language engines work. + 2006-10-12 Behdad Esfahbod <behdad@gnome.org> Bug 353877 – Sinhala is_cursor_position and diff --git a/configure.in b/configure.in index 36120426..ced5ea83 100644 --- a/configure.in +++ b/configure.in @@ -447,11 +447,13 @@ INCLUDED_X_MODULES= INCLUDED_FC_MODULES= INCLUDED_WIN32_MODULES= INCLUDED_ATSUI_MODULES= +INCLUDED_LANG_MODULES= AC_SUBST(INCLUDED_X_MODULES) AC_SUBST(INCLUDED_FC_MODULES) AC_SUBST(INCLUDED_WIN32_MODULES) AC_SUBST(INCLUDED_ATSUI_MODULES) +AC_SUBST(INCLUDED_LANG_MODULES) IFS="${IFS= }"; pango_save_ifs="$IFS"; IFS=", " for module in $included_modules; do @@ -462,10 +464,11 @@ for module in $included_modules; do included_path="\$(top_builddir)/modules/$dir/libpango-$module.la" case $module in - *-fc) INCLUDED_FC_MODULES="$INCLUDED_FC_MODULES $included_path" ;; *-x) INCLUDED_X_MODULES="$INCLUDED_X_MODULES $included_path" ;; + *-fc) INCLUDED_FC_MODULES="$INCLUDED_FC_MODULES $included_path" ;; *-win32) INCLUDED_WIN32_MODULES="$INCLUDED_WIN32_MODULES $included_path" ;; *-atsui) INCLUDED_ATSUI_MODULES="$INCLUDED_ATSUI_MODULES $included_path" ;; + *-lang) INCLUDED_LANG_MODULES="$INCLUDED_LANG_MODULES $included_path" ;; *) AC_MSG_ERROR([specified module $module not recognized]) ;; esac done @@ -803,6 +806,35 @@ cat >> pango/module-defs-atsui.c <<EOTEXT EOTEXT ]) +AC_CONFIG_COMMANDS([pango/module-defs-lang.c], +[ +### lang modules +cat > pango/module-defs-lang.c <<EOTEXT +/* Autogenerated by configure. Do not edit */ + +#include "module-defs.h" + +PangoIncludedModule _pango_included_lang_modules@<:@@:>@ = { +EOTEXT + +IFS="${IFS= }"; pango_save_ifs="$IFS"; IFS="," +for module in $included_modules; do + if echo $module | egrep -- "-lang($|,)" > /dev/null; then + module_c=`echo $module | sed s/-/_/` + cat >> pango/module-defs-lang.c <<EOTEXT + { _pango_${module_c}_script_engine_list, _pango_${module_c}_script_engine_init, _pango_${module_c}_script_engine_exit, _pango_${module_c}_script_engine_create }, +EOTEXT + fi +done + +IFS="$pango_save_ifs" + +cat >> pango/module-defs-lang.c <<EOTEXT + { NULL, NULL, NULL, NULL }, +}; +EOTEXT +]) + AC_HEADER_DIRENT AC_CHECK_HEADERS(unistd.h) diff --git a/modules/Makefile.am b/modules/Makefile.am index 43c5410e..f985a06b 100644 --- a/modules/Makefile.am +++ b/modules/Makefile.am @@ -46,7 +46,10 @@ install-data-local: $(top_builddir)/pango/pango-querymodules uninstall-local: $(RM) $(DESTDIR)$(sysconfdir)/pango/pango.modules -pango.modules: $(top_builddir)/pango/pango-querymodules $(SUBDIRS) +pango.modules: \ + $(SUBDIRS) \ + $(top_builddir)/config.status \ + $(top_builddir)/pango/pango-querymodules @if find . -name '*.la' | grep -v '\.libs' | grep -v libpango | grep '.' > /dev/null ; then \ echo "Writing a pango.modules file to use with tests/examples."; \ $(top_builddir)/pango/pango-querymodules `find . -name '*.la' | grep -v '\.libs' | grep -v libpango` > $@ ;\ diff --git a/pango/.cvsignore b/pango/.cvsignore index 9363569d..db2705df 100644 --- a/pango/.cvsignore +++ b/pango/.cvsignore @@ -8,10 +8,7 @@ pango-enum-types.[ch] s-enum-types-[ch] pango-querymodules module-defs.h -module-defs-atsui.c -module-defs-x.c -module-defs-fc.c -module-defs-win32.c +module-defs-*.c *.lo *.la .deps diff --git a/pango/Makefile.am b/pango/Makefile.am index 7728215c..473b6124 100644 --- a/pango/Makefile.am +++ b/pango/Makefile.am @@ -42,8 +42,12 @@ endif lib_LTLIBRARIES = libpango-1.0.la libpango_1_0_la_LDFLAGS = $(LIBRARY_LIBTOOL_OPTIONS) -libpango_1_0_la_LIBADD = $(GLIB_LIBS) $(libm) -libpango_1_0_la_DEPENDENCIES = +libpango_1_0_la_LIBADD = \ + $(GLIB_LIBS) \ + $(libm) \ + $(INCLUDED_LANG_MODULES) +libpango_1_0_la_DEPENDENCIES = \ + $(INCLUDED_LANG_MODULES) libpango_1_0_la_LIBADD += mini-fribidi/libmini-fribidi.la libpango_1_0_la_DEPENDENCIES += mini-fribidi/libmini-fribidi.la @@ -87,7 +91,8 @@ libpango_1_0_la_SOURCES = \ pango-matrix.c \ reorder-items.c \ shape.c \ - pango-enum-types.c + pango-enum-types.c \ + module-defs-lang.c pango_headers = \ pango.h \ @@ -430,28 +435,29 @@ EXTRA_DIST = \ pangoft2.rc \ pangoft2.rc.in \ pangowin32.rc \ - pangowin32.rc.in + pangowin32.rc.in \ + check.defs if HAVE_INCLUDED_MODULES included-modules: @cd $(top_builddir)/modules && $(MAKE) $(AM_MAKEFLAGS) included-modules -$(INCLUDED_X_MODULES) $(INCLUDED_FC_MODULES) $(INCLUDED_WIN32_MODULES): included-modules +$(INCLUDED_LANG_MODULES) $(INCLUDED_X_MODULES) $(INCLUDED_FC_MODULES) $(INCLUDED_WIN32_MODULES) $(INCLUDED_ATSUI_MODULES): included-modules @true .PHONY: included-modules endif -module-defs.h: $(top_builddir)/config.status - cd $(top_builddir) && $(SHELL) ./config.status pango/$@ -module-defs-x.c: $(top_builddir)/config.status - cd $(top_builddir) && $(SHELL) ./config.status pango/$@ -module-defs-fc.c: $(top_builddir)/config.status - cd $(top_builddir) && $(SHELL) ./config.status pango/$@ -module-defs-win32.c: $(top_builddir)/config.status - cd $(top_builddir) && $(SHELL) ./config.status pango/$@ -module-defs-atsui.c: $(top_builddir)/config.status +MODULE_DEF_FILES = \ + module-defs.h \ + module-defs-lang.c \ + module-defs-x.c \ + module-defs-fc.c \ + module-defs-win32.c \ + module-defs-atsui.c + +$(MODULE_DEF_FILES): $(top_builddir)/config.status cd $(top_builddir) && $(SHELL) ./config.status pango/$@ CLEANFILES = \ @@ -461,11 +467,7 @@ CLEANFILES = \ s-enum-types-c DISTCLEANFILES = \ - module-defs.h \ - module-defs-x.c \ - module-defs-fc.c \ - module-defs-win32.c \ - module-defs-atsui.c + $(MODULE_DEF_FILES) install-data-local: install-ms-lib install-def-files diff --git a/pango/modules.c b/pango/modules.c index 2c2b7321..301c098d 100644 --- a/pango/modules.c +++ b/pango/modules.c @@ -31,6 +31,7 @@ #include "pango-enum-types.h" #include "pango-modules.h" #include "pango-impl-utils.h" +#include "modules.h" typedef struct _PangoModule PangoModule; typedef struct _PangoModuleClass PangoModuleClass; @@ -536,6 +537,7 @@ static void init_modules (void) { static gboolean init = FALSE; + int i; if (init) return; @@ -545,6 +547,8 @@ init_modules (void) /* Make sure that the type system is initialized */ g_type_init (); + for (i = 0; _pango_included_lang_modules[i].list; i++) + pango_module_register (&_pango_included_lang_modules[i]); read_modules (); } diff --git a/pango/modules.h b/pango/modules.h index eb04d5b4..ca22701b 100644 --- a/pango/modules.h +++ b/pango/modules.h @@ -25,6 +25,7 @@ #ifndef __MODULES_H__ #define __MODULES_H__ +extern PangoIncludedModule _pango_included_lang_modules[]; extern PangoIncludedModule _pango_included_x_modules[]; extern PangoIncludedModule _pango_included_fc_modules[]; extern PangoIncludedModule _pango_included_win32_modules[]; |