Index: Makefile.in ================================================================== --- Makefile.in +++ Makefile.in @@ -5,10 +5,13 @@ CPPFLAGS = @CPPFLAGS@ -I@srcdir@ -I. @DEFS@ @TCL_DEFS@ LDFLAGS = @LDFLAGS@ @SHOBJLDFLAGS@ LIBS = @LIBS@ INSTALL = @INSTALL@ PACKAGE_VERSION = @PACKAGE_VERSION@ +prefix = @prefix@ +exec_prefix = @exec_prefix@ +libdir = @libdir@ TCL_PACKAGE_PATH = @TCL_PACKAGE_PATH@ PACKAGE_INSTALL_DIR = $(TCL_PACKAGE_PATH)/tcltls$(PACKAGE_VERSION) VPATH = @srcdir@ all: @EXTENSION_TARGET@ Index: aclocal/tcl.m4 ================================================================== --- aclocal/tcl.m4 +++ aclocal/tcl.m4 @@ -154,10 +154,14 @@ )` TCL_DEFS="${TCL_DEFS_TCL_ONLY}" AC_SUBST(TCL_DEFS) dnl Needed for package installation - TCL_PACKAGE_PATH="`echo "${TCL_PACKAGE_PATH}" | sed 's@ *$''@@' | awk '{ print [$]1 }'`" + if test "$prefix" = 'NONE' -a "$exec_prefix" = 'NONE' -a "${libdir}" = '${exec_prefix}/lib'; then + TCL_PACKAGE_PATH="`echo "${TCL_PACKAGE_PATH}" | sed 's@ *$''@@' | awk '{ print [$]1 }'`" + else + TCL_PACKAGE_PATH='${libdir}' + fi AC_SUBST(TCL_PACKAGE_PATH) AC_SUBST(LIBS) ])