"TH" == Taco Hoekwater writes: >> /usr/libexec/gcc/i686-apple-darwin8/4.0.1/ld: Undefined >> symbols: _libintl_gettext
TH> This one is simple to fix, I forgot to suppress libintl (gettext) TH> in fontforge's configuration. There are two lines containing TH> #undef HAVE_LIBINTL_H TH> inside src/libs/luafontforge/fontforge/inc/config.h.in (one is TH> enough really, the other one is a fluke) TH> If you put those in C comment tags (like the _HAS_LONGLONG is TH> already) then this error will go away, I am sure. maybe it fixed apple-darwin, but it broke sparc-solaris. :( here is why: * on solaris, there IS /usr/include/libintl.h, so HAVE_LIBINTL_H would've been normally defined. but hardwiring "#undef HAVE_LIBINTL_H" fools the libs/luafontforge/fontforge/inc/intl.h to believe that there is no libintl.h in the system, and it executes the branch "#if !defined( HAVE_LIBINTL_H )" which has: # define bindtextdomain(domain,dir) # define bind_textdomain_codeset(domain,enc) # define textdomain(domain) # define dgettext(domain,str) (str) * then, many fontforge headers have #include <locale.h> which is fine, but on solaris, /usr/include/locale.h contains #include <libintl.h> and so /usr/include/libintl.h gets included, but, because of the above #define's made in libs/luafontforge/fontforge/inc/intl.h, it causes havoc, because /usr/include/libintl.h has extern char *dgettext(const char *, const char *); extern char *textdomain(const char *); extern char *bindtextdomain(const char *, const char *); which, because of those #define's, get pre-processed to extern char * ( const char * ); extern char *; extern char *; * comparing libs/luafontforge/fontforge/inc/intl.h in texlive repository and in the "math" branch of luatex, i see that texlive has "#if ! defined(__sun__) && ! defined(__sun)" ... "#endif" around the above #define's (see the attached patch) while this does not look like a right fix (the problem seems to be caused by fooling intl.h by "#undef HAVE_LIBINTL_H" above), it seems to fix the build process. this was somehow lost during recent upgrade of fontforge in luatex. is it possible to fix the problem upstream (in fontforge) so it won't re-appear again after another update of fontforge in luatex? Best, v.
Index: inc/intl.h =================================================================== --- inc/intl.h (revision 1640) +++ inc/intl.h (working copy) @@ -32,6 +32,7 @@ # define P_(str1,str_non1,n) ((n)==1?str1:str_non1) # define U_(str) (str) +#if ! defined(__sun__) && ! defined(__sun) # ifdef bindtextdomain # undef bindtextdomain # endif @@ -47,6 +48,7 @@ # define textdomain(domain) # define dgettext(domain,str) (str) +#endif #elif defined( NODYNAMIC ) || defined ( _STATIC_LIBINTL )
_______________________________________________ dev-luatex mailing list [email protected] http://www.ntg.nl/mailman/listinfo/dev-luatex
