diff options
author | jingham <jingham@noemail.net> | 1999-06-16 05:33:57 (GMT) |
---|---|---|
committer | jingham <jingham@noemail.net> | 1999-06-16 05:33:57 (GMT) |
commit | 3c07b4cf476904cdb64ae6a4638df9960440ee0e (patch) | |
tree | f7bb109ba27f45b2487a646b4af72e62b027c80a /mac/tkMacAppInit.c | |
parent | 44be36d738fa97852bac3afb5e7734f415045a64 (diff) | |
download | tk-3c07b4cf476904cdb64ae6a4638df9960440ee0e.zip tk-3c07b4cf476904cdb64ae6a4638df9960440ee0e.tar.gz tk-3c07b4cf476904cdb64ae6a4638df9960440ee0e.tar.bz2 |
Have to call Tcl_FindExecutable BEFORE creating the first interpreter. Need to do this in main, since Tk_Main surreptitiously creates the interpreter now.
FossilOrigin-Name: 979bc5babb4b20b7798b026c490fb7711b351922
Diffstat (limited to 'mac/tkMacAppInit.c')
-rw-r--r-- | mac/tkMacAppInit.c | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/mac/tkMacAppInit.c b/mac/tkMacAppInit.c index 9d27ca7..9772f36 100644 --- a/mac/tkMacAppInit.c +++ b/mac/tkMacAppInit.c @@ -9,7 +9,7 @@ * See the file "license.terms" for information on usage and redistribution * of this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tkMacAppInit.c,v 1.10 1999/05/22 06:32:08 jingham Exp $ + * RCS: @(#) $Id: tkMacAppInit.c,v 1.11 1999/06/16 05:33:58 jingham Exp $ */ #include <Gestalt.h> @@ -23,6 +23,7 @@ #include "tk.h" #include "tkInt.h" #include "tkMacInt.h" +#include "tclInt.h" #include "tclMac.h" #ifdef TK_TEST @@ -95,6 +96,15 @@ main( argc = 1; newArgv[0] = "Wish"; newArgv[1] = NULL; + + /* Tk_Main is actually #defined to + * Tk_MainEx(argc, argv, Tcl_AppInit, Tcl_CreateInterp()) + * Unfortunately, you also HAVE to call Tcl_FindExecutable + * BEFORE creating the first interp, or the tcl_library will not + * get set properly. So we call it by hand here... + */ + + Tcl_FindExecutable(newArgv[0]); Tk_Main(argc, newArgv, Tcl_AppInit); } |