Skip to content
Tcl Source Code Ticket Change Details
Login

Ticket Change Details

Overview

Artifact ID: 94901ee40b0493a055c1d35195a789a684cd36ab
Ticket: 218128ffffffffffffffffffffffffffffffffff
8.1 installation issue? Tcl_Init no longer supported?
User & Date: nobody on 2000-10-26 00:53:28
Changes

  1. assignee changed to: "nobody"
  2. cmimetype changed to: "text/plain"
  3. comment changed to:
    OriginalBugID: 1987 Bug
    Version: 8.1
    SubmitDate: '1999-05-05'
    LastModified: '1999-11-07'
    Severity: CRIT
    Status: Closed
    Submitter: pat
    ChangedBy: hobbs
    OS: Solaris
    OSVersion: 2.5
    Machine: Other
    FixedDate: '2000-10-25'
    ClosedDate: '1999-11-07'
    
    
    Name: Paul Danielson
    
    Comments:
    My 8.1 version of tclsh and wish both operate fine, but the C-API seems
        flakey.
        I tried directly evaluating the init.tcl script, which got me a little
        further and then into a core-dump. Any thoughts would be appreciated.
    
    ReproducibleScript:
    int
        main(argc, argv)
          int    argc;
          char **argv;
        {
          int  status;
        
          Tcl_Interp* interp;
          Tcl_Obj*    zero;
          Tcl_Obj*    name;
        
          status = TCL_OK;
        
          interp = Tcl_CreateInterp();
        
          zero = Tcl_NewBooleanObj( 0 );
          name = Tcl_NewStringObj( "::appDone", 9 );
          Tcl_ObjSetVar2( interp, name, NULL, zero, 0 );
        
          if( (status = Tcl_Init( interp )) != TCL_ERROR )
          {
            if( (status = Tk_Init( interp )) != TCL_ERROR )
            {
            }
          } else
        printf("interp = %s\n", interp->result);
        
        printf("status = %s\n", (status == TCL_ERROR) ? "error" : "good");
        
          return status;
        }
        
        compile with gcc:
        gcc -I/usr/openwin/include -I/home/tcl/include -I.  -c  test.c
        gcc -I/usr/openwin/include -I/home/tcl/include -I.  -L/home/tcl/lib
        -R/home/tcl/lib -ltcl8.1 -ltk8.1 -lstdc++ -L/usr/openwin/lib -lX11 -lm
        test.o  -o tester
        
        Then execute tester. This is on a Solaris 2.5/SPARC platform.
    
    ObservedBehavior:
    The result field of the intepreter contains:
        interp = Can't find a usable init.tcl in the following directories: 
            
        
        This probably means that Tcl wasn't installed properly.
        
        I installed it the same way as always: configure --enable-gcc
        --prefix=/home/tcl; make; make install. Tcl_Init does not seem to be a
        documented command (at least on the web site man pages), but it did work
        in 8.0, and the change log didn't say "DANGER!!! Incompatible!". Going
        back to 8.0 on the compile line (-ltcl8.0) restores the expected
        behaviour.
    
    DesiredBehavior:
    Initialization of the interpreter, and a functioning program...
    
    
    
    Tcl_FindExecutable needs to be called first to set up the i18n
    stuff and find the right directories.  Use of this can be seen
    in the source.  Unfortunately, this wasn't documented appropriately. 
    -- 11/07/1999 hobbs
    
  4. foundin changed to: "obsolete: 8.1"
  5. priority changed to: "5 Medium"
  6. resolution changed to: "None"
  7. status changed to: "Open"
  8. submitter changed to: "nobody"
  9. subsystem changed to: "61. (unused)"
  10. title changed to:
    8.1 installation issue? Tcl_Init no longer supported?
    
  11. type changed to: "Bug"