Re: WRAPPING TK GUI

From: Jeff Godfrey (jeff_godfrey_at_pobox.com)
Date: 03/05/05


Date: Sat, 5 Mar 2005 07:48:50 -0600


"MEMORICE" <memorice@gmail.com> wrote in message
news:60060344.0503050458.5be2070d@posting.google.com...
> "Gerald W. Lester" <Gerald.Lester@cox.net> wrote in message
> news:<mL8Wd.22765$Az.17890@lakeread02>...
>> MEMORICE wrote:
>> > I've build an interface, it will run with wish 8.4 there isn't any
>> > problem...
>> > I want to wrap it with freewrap, so I can use it as a .exe file, ...
>> > I hope anyone has a solution for me...
>>
>> If you can't solve your problem with freewrap, you could always switch to
>> wrapping it as a StarPack (also an .exe file). See:
>> http://wiki.tcl.tk/starpack
>> http://www.equi4.com/208
>>
>> And the pages they have links to.
>
> I've tried to do that, but I can make a <name>.kit file, and the map
> <name>.vfs... But I don't get a .exe file...
>
> (tclkitsh-win32.upx.exe sdx.kit qwrap gui.tcl gives a gui.kit file)
> (tclkitsh-win32.upx.exe sdx.kit unwrap gui.kit gives a gui.vfs map
> with tcl files)
> (tclkitsh-win32.upx.exe sdx.kit wrap gui.kit gives a .bat file that's
> not working)

Yep, you're right... That last line won't give you an exe, because it's not
correct. I haven't been following this thread, but I assume you want
something like this (in place of your last line).

tclkitsh-win32.upx.exe sdx.kit wrap gui.exe -runtime tclkit-win32.upx.exe

(Note, the above is untested, but I think correct).

Note, the "tclkitsh..." file does not contain Tk, just Tcl. The "tclkit..."
file contains Tk. So, while you can use the "tcl-only" version to wrap your
code, you need to use the "Tk" version as the "runtime" (the version
included in the final exe) in order to have access to Tk within the
generated exe.

Also, to save some typing, you might rename the two tclkit's to tclkitsh.exe
and tclkit.exe...

One other tip... You *can't* use the same copy of tclkit.exe or tclkitsh.exe
to both perform the actual wrapping *and* be included as the -runtime.
Above, we wrap with the non-Tk version, but include the Tk version in the
exe. This is OK, because they are 2 physically different files. If you
want to wrap with, and include the same tclkit (with or without Tk), you
must create a copy of the tclkit*.exe file, so that the 2 tclkit exe's
called on the above command line reference 2 physically different files...

HTH,

Jeff



Relevant Pages

  • Re: Stand Alone EXE
    ... Thank you very much Jim! ... to use this application to wrap my applications into working? ... but it's a single .EXE file. ... you can use Thinstall to wrap the exe and only the portions of the ...
    (microsoft.public.dotnet.general)
  • wrapping application that uses .dlls
    ... My tcl script uses two packages that are implemented as dll's. ... When I wrap my app w/ prowrap myapp.tcl -uses tclsh, I get an exe ...
    (comp.lang.tcl)
  • Weird error from Starkit
    ... the VFS expansion on my HD, when I wrap it and try to run the exe I ... Error in starup script ... ("package ifneeded" script) ...
    (comp.lang.tcl)
  • Re: WRAPPING TK GUI
    ... >> with tcl files) ... That last line won't give you an exe, ... > Above, we wrap with the non-Tk version, but include the Tk version in the ... > want to wrap with, and include the same tclkit, you ...
    (comp.lang.tcl)
  • Re: How to pass variables to another tcl script?
    ... #create a copy of tclkit to wrap ... in your main/calling script you might need to do ... This will replace your $arg with the value of the $arg before it gets ...
    (comp.lang.tcl)