This is the mail archive of the insight@sources.redhat.com mailing list for the Insight project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: potential tix build problem


Mo DeJong wrote:
> 
> On Thu, 26 Jul 2001, Keith Seitz wrote:
> 
> > On Thu, 26 Jul 2001, Jonathan Larmour wrote:
> >
> > > make[3]: Entering directory
> > > `/export/bucket/sourceware/gdb/build/arm-elf/tix/unix/tk8.0'
> > > TCL_LIBRARY=/home/jlarmour/sourceware/gdb/insight/src/tcl/library
> > > TK_LIBRARY=/home/jlarmour/sourceware/gdb/insight/src/tk/library
> > > @TCL_BIN_DIR@/tclsh
> > > /home/jlarmour/sourceware/gdb/insight/src/tix/tools/tclc.tcl
> > > /home/jlarmour/sourceware/gdb/insight/src/tix/library/pref/*.fsc
> > > /home/jlarmour/sourceware/gdb/insight/src/tix/library/pref/*.csc
> > > /home/jlarmour/sourceware/gdb/insight/src/tix/library/*.tcl \
> > >     > tixSamLib.c
> > > /bin/sh: @TCL_BIN_DIR@/tclsh: No such file or directory
> > > make[3]: *** [tixSamLib.c] Error 127
> >
> > Hmmm... I don't seem to ever see this error when installing on linux.
> 
> Ugh. We are really trying to remove any use of Tcl executables at
> runtime since it does not work when cross compiling.
> 
> Poking around in src/tix/unix/tk8.0/Makefile.in trned up:
> 
> tclSamLib.c:
>         $(RUN_TCLSH) $(SRC_DIR)/tools/tclc.tcl $(TCL_SCRIPTS) \
>             > tclSamLib.c
> 
> It seems RUN_TCLSH is used to generate .c files of static Tcl
> code. I am not sure why that would be kicked off at runtime.
> 
> > > The error was ignored and the make install continued. The reason for this
> > > is actually in tcl/unix/ where there is nothing in the autoconf stuff to
> > > substitute in the correct value of TCL_BIN_DIR into tclConfig.sh.in that I
> > > can see.
> > >
> > > It seems that the configury in tcl/win/ solves this, so the appropriate
> > > patch to tcl/unix/configure.in would be:
> 
> Ok, I am a bit confused by this patch. If the problem is a lack of
> TCL_BIN_DIR in the tix configure script, why is this patch for
> Tcl?
> 
> The TCL_BIN_DIR var seems to be set in src/tix/unix/tk8.0/configure.in
> 
> (On line 147)
> 
> TCL_BIN_DIR=../../../tcl/unix
> 
> It also get substituted later:
> 
> AC_SUBST(TCL_BIN_DIR)

However, TCL_BIN_DIR gets reset by the run of tclConfig.sh on line 224.
 
> > > If it's okay to check in, off-line you can tell me how to deal with our
> > > internal devo, and any consequences for irox's TCL update.
> >
> > I dunno. I looked at what is in Sourceforge's Tcl repository, and it looks
> > like they just now do a "AC_SUBST(TCL_BIN_DIR)", without ever setting it.
> > In any case, if it works, I say check it in. I'm not entirely sure what
> > this tix sam stuff is all about, anyway. (Stand-alone module?)
> 
> In the Tcl config, TCL_BIN_DIR is set by the SC_PATH_TCLCONFIG macro.
> This TCL_BIN_DIR value does not show up in tclConfig.sh so each
> module needs to figure it out.

It does show up, as being set to @TCL_BIN_DIR@. It's just there is no
AC_SUBST for that variable so it remains set as literally that.

> That makes sense because tclConfig.sh
> lives in ${TCL_BIN_DIR} so how would an extension know how to
> load ${TCL_BIN_DIR}/tclConfig.sh if it did not know what
> TCL_BIN_DIR was?

Then why does the variable exist at all? Perhaps just to give location
independence to tclConfig.sh (hah!).
 
> > I'm not sure it really matters for us either way. I've never had any
> > problems with running/installing Insight because of tix
> > (installation/build problems).
> 
> I just took a peek at the 8.0 code on sources and it seems to set
> TCL_BIN_DIR in unix/tclConfig.sh.in. This seems to be an
> ill advised cygnus local change. This change does not appear
> in the 8.3 upgrade so I would advise against adding the patch.
> It seems like setting TCL_BIN_DIR in the tix configure script
> is the right fix for this problem.

TCL_BIN_DIR is already set and AC_SUBST'd in tix/unix/tk8.0. Perhaps than
the change should be either to remove the setting of TCL_BIN_DIR from
tcl/unix/tclConfig.sh.in, or to move the set of TCL_BIN_DIR to beneath the
execution of tclConfig.sh.

All I was doing was trying to make the unix build process similar to the
win one, which has this solved. So if you're saying this method is wrong,
it means the AC_SUBST in tcl/win/configure.in should be removed too.

If you think that's what should happen, I'll make the patch.

Jifl
-- 
Red Hat, Rustat House, Clifton Road, Cambridge, UK. Tel: +44 (1223) 271062
Maybe this world is another planet's Hell -Aldous Huxley || Opinions==mine


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]