From: Christopher S. M. <mor...@AR...> - 2002-03-12 22:52:43
|
My apologies if this is an answered question (couldn't find it in archives), but I'm having difficulty getting 8.3.2 to find itself properly after installation. I have similar problems for everything else thereafter (tk, itcl, itk, iwidgets). The quick fix is to set the corresponding XXXX_LIBRARY environment variable to the packages find what they need, and all is good. But that doesn't fix the problem, it quells the symptom. How does /System/Library/Tcl/8.3 get into that search path and how can I go about to get that to be based off --prefix's value. There is a little oddity of the Makefile getting modified (necessarily on other platforms) prior to building. The details are included below. Any help is appreciated. As a side note, I have to use 8.3.2 for this release, unfortunately. Then I'll be upgrading it to newer tcl/tk sources. A short-term fix to get this version working would be nice, though. Here is the error message: bash2.04 sean@dhcp-32-233 ~/brlcad6/.libtcl8.3.pmac % tclsh application-specific initialization failed: Can't find a usable init.tcl in the following directories: /System/Library/Tcl/8.3 /usr/brlcad/lib/tcl8.3 /usr/lib/tcl8.3 /usr/lib/tcl8.3/library /usr/library /usr/tcl8.3/library /tcl8.3/library /System/Library/Tcl/8.3 This probably means that Tcl wasn't installed properly. Here is the initial build: ( CFLAGS=" -O3 -fno-common -ffast-math -fstrength-reduce -fexpensive-optimizations "; AFTER_MAKE="rm -f libtcl.a ; ln -s libtcl8.3.a libtcl.a"; RANLIB="ranlib -c"; LDFLAGS="-O3 -fno-common -ffast-math -fstrength-reduce -fexpensive-optimizations "; BUILD_LIBRARY="ar r"; CC="cc"; export CFLAGS RANLIB LDFLAGS BUILD_LIBRARY CC AFTER_MAKE; ../libtcl8.3/"unix"/configure --srcdir=/Users/sean/brlcad6/.libtcl8.3.pmac/../libtcl8.3/"unix" --quiet --cache-file cache.pmac --exec-prefix=/usr/brlcad --prefix=/usr/brlcad --disable-shared; ../libtcl8.3/fix_makefile.sh > Makefile.pmac) creating cache cache.pmac Can't figure out how to do dynamic loading or shared libraries on this system. updating cache cache.pmac creating ./config.status creating Makefile creating tclConfig.sh make -f Makefile.pmac tclsh cc -c -O3 -fno-common -ffast-math -fstrength-reduce -fexpensive-optimizations -Wall -Wconversion -Wno-implicit-int -I/Users/sean/brlcad6/.libtcl8.3.pmac/../libtcl8.3/unix/../generic -I/Users/sean/brlcad6/.libtcl8.3.pmac/../libtcl8.3/unix -DHAVE_UNISTD_H=1 -DHAVE_LIMITS_H=1 -DHAVE_GETCWD=1 -DHAVE_OPENDIR=1 -DHAVE_STRSTR=1 -DHAVE_STRTOL=1 -DHAVE_TMPNAM=1 -DHAVE_WAITPID=1 -DNO_VALUES_H=1 -DNO_DLFCN_H=1 -DHAVE_UNISTD_H=1 -DHAVE_SYS_PARAM_H=1 -DUSE_TERMIOS=1 -DHAVE_SYS_TIME_H=1 -DTIME_WITH_SYS_TIME=1 -DHAVE_TM_ZONE=1 -DHAVE_TM_GMTOFF=1 -DHAVE_ST_BLKSIZE=1 -DSTDC_HEADERS=1 -DNEED_MATHERR=1 -DHAVE_SIGNED_CHAR=1 -DHAVE_SYS_IOCTL_H=1 -DHAVE_SYS_FILIO_H=1 -DSTATIC_BUILD=1 -DTCL_SHLIB_EXT=\"\" /Users/sean/brlcad6/.libtcl8.3.pmac/../libtcl8.3/unix/../unix/tclAppInit.c . . . The fix_makefile.sh file looks like this: bash2.04 sean@dhcp-32-233 ~/brlcad6/.libtcl8.3.pmac % less ../libtcl8.3/fix_makefile.sh #!/bin/sh sed -e s@lib/tcl\$\(VERSION\)@tcl\$\(VERSION\)@ Makefile |\ sed -e s@\(prefix\)/include@\(prefix\)/include/brlcad@ |\ sed -e "s@\${\C\C} \${TCLSH_OBJS}@\${\C\C} $LDFLAGS \${TCLSH_OBJS}@" |\ sed -e "s@\${\C\C} \${TCLTEST_OBJS}@\${\C\C} $LDFLAGS \${TCLTEST_OBJS}@" Resulting in the following diff in the Makefile: bash2.04 sean@dhcp-32-233 ~/brlcad6/.libtcl8.3.pmac % diff Makefile.pmac Makefile 42c42 < TCL_LIBRARY = $(prefix)/tcl$(VERSION) --- > TCL_LIBRARY = $(prefix)/lib/tcl$(VERSION) 432c432 < ${CC} -O3 -fno-common -ffast-math -fstrength-reduce -fexpensive-optimizations ${TCLSH_OBJS} -L/Users/sean/brlcad6/.libtcl8.3.pmac -ltcl8.3${TCL_DBGX} ${LIBS} \ --- > ${CC} ${TCLSH_OBJS} -L/Users/sean/brlcad6/.libtcl8.3.pmac -ltcl8.3${TCL_DBGX} ${LIBS} \ 436c436 < ${CC} -O3 -fno-common -ffast-math -fstrength-reduce -fexpensive-optimizations ${TCLTEST_OBJS} -L/Users/sean/brlcad6/.libtcl8.3.pmac -ltcl8.3${TCL_DBGX} ${LIBS} \ --- > ${CC} ${TCLTEST_OBJS} -L/Users/sean/brlcad6/.libtcl8.3.pmac -ltcl8.3${TCL_DBGX} ${LIBS} \ Cheers! Sean |