Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

HOW to convert a .tk file into a windows executable one?

Status
Not open for further replies.

RajVerma

Programmer
Jun 11, 2003
62
DE
hi,

I have a tk program, in a single file, which is an interface between an electronic machine and the computer through COM1. I normally run this file from 'tkcon' Tk-console in windows using 'ActiveState ActiveTcl 8.4.4.0'.

Now I want to make it as an executable file so that the user doesn't have to open a Tk console every time he wants to run this file. how to make this .tk file as an executable file that runs on a double click?

thanx,
Raj.
 
hi sh00der,

thanx for the link. though that is what I need, the information given there is pretty confusing and I couldn't achieve my thing with the instructions given there. may be I'm so dumb to understand their explanation. I'm neither able to run this freewrap.exe file in windows nor I could find this binary file in linux, and they say that it is a single step process °_° can some one explain me how to run this freewrap and successfully get an executable file??

thankyou,
Raj.
 
Yeah, I know it's not the clearest set of instructions. I did manage to get some success with it.
I take it you have access to windows and Linux then?
I have only used the Linux version so here's what I would do. Download freewrap561.tar.gz from this link,


and gunzip then tar xvf and it will give you an executable linux file called freewrap in the directory that you did the tar command (lets call the directory FWLinux).

Then try a simple script, copy the tcl/tk script to the FWLinux directory and in this directory try,

freewrap simple.tcl

This should give you a Linux executable called simple.

If that works, then download the windows freewrap executable,


and unzip it to another directory, like FWLinux/FWWindows.

Then again from FWLinux try,

freewrap simple.tcl -w FWWindows/freewrap.exe

This should give you a windows executable called simple.exe

Try that executable in windows and let us know how you get on.

If you have multiple files it gets a little more complicated.
 
thanx sh00der,

I cud able to get it work in windows, but when I run this new exe file of a Tk script it opens a console along with the application. what shud I do to stop this console window opening along with the application?

In Linux I have a compatibility problem. It gives the following error while using this freewrap

diff@diff1:~/raj> freewrap com.tk
freewrap: /lib/libc.so.6: version `GLIBC_2.3' not found (required by freewrap)
diff@diff1:~/raj>

I guess it shud work with the latest version of Linux. The one that I have is an old SuSE.

hi fabien, MktclApp seems to be interesting but it is a bit time-consuming task for me right now.

anyway thanx for the suggestions.

cheers,
Raj.
 
The error message you get in SuSe just means that your glibc package needs updating.

As far as the console goes, try adding the command

console hide

to your Tk script, then wrap it again.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top