diff -urN TeX.orig/texk/kpathsea/configure TeX/texk/kpathsea/configure --- TeX.orig/texk/kpathsea/configure 2005-08-21 22:04:18.000000000 +0200 +++ TeX/texk/kpathsea/configure 2006-05-27 20:01:29.000000000 +0200 @@ -5539,7 +5539,11 @@ LIBTOOL_DEPS="$ac_aux_dir/ltmain.sh" # Always use our own libtool. -LIBTOOL='$(SHELL) $(top_builddir)/libtool' +if [ "${USERLAND}" = "Darwin" ]; then +LIBTOOL='glibtool' +else +LIBTOOL='libtool' +fi # Prevent multiple expansion diff -urN TeX.orig/texk/libtool.m4 TeX/texk/libtool.m4 --- TeX.orig/texk/libtool.m4 2005-08-14 16:13:04.000000000 +0200 +++ TeX/texk/libtool.m4 2006-05-27 20:02:13.000000000 +0200 @@ -31,7 +31,13 @@ LIBTOOL_DEPS="$ac_aux_dir/ltmain.sh" # Always use our own libtool. -LIBTOOL='$(SHELL) $(top_builddir)/libtool' +# Use the system libtool +if [ "${USERLAND}" = "Darwin" ]; then +LIBTOOL='glibtool' +else +LIBTOOL='libtool' +fi + AC_SUBST(LIBTOOL)dnl # Prevent multiple expansion diff -urN TeX.orig/texk/make/common.mk TeX/texk/make/common.mk --- TeX.orig/texk/make/common.mk 2004-08-06 20:40:50.000000000 +0200 +++ TeX/texk/make/common.mk 2006-05-27 20:03:18.000000000 +0200 @@ -12,7 +12,11 @@ LDFLAGS = @LDFLAGS@ $(XLDFLAGS) # Kpathsea needs this for compiling, programs need it for linking. -LIBTOOL = $(SHELL) $(kpathsea_parent)/libtool +ifeq ($(USERLAND),Darwin) +LIBTOOL='glibtool' +else +LIBTOOL='libtool' +endif # You can change [X]CPPFLAGS, [X]CFLAGS, or [X]DEFS, but # please don't change ALL_CPPFLAGS or ALL_CFLAGS.