Problem running a C/C++ program evaluating a tcl script

Mumit Khan khan@xraylith.wisc.EDU
Mon May 31 21:10:00 GMT 1999

Juergen Koehne <> writes:
> I've troubles running a C/C++ program evaluating a Tcl script. The
> program compiles without errors, but when I run it only the Tcl prompt
> appears on the command line but no window pops up.
> Under Unix and Linux all works well. When I start the program the popup
> window appears as expected.
> Has anyone an idea what's going wrong?

Short and pat answer -- you're doing it correctly ;-)

This has come up in the past and answer hasn't changed -- Unix and Cygwin
ports of Tcl are not the same (unless you build Cygwin Tcl as a Unix one,
which is not the case in the Cygwin distribution)!

Two choices:

- For truly portable Tcl code, you should use dynamic loading, and nothing
  but dynamic loading. It's simple and it works.

- If you really must have a "main" function and create all the
  interpreters yourself as you're doing, then you need different "main"
  programs for Unix and Windows32. Tcl folks have some examples to show
  how this is done, and you should look at the or
  example.tar.gz somewhere on Scriptics site.

Also, check the FAQ, which might have some more pertinent information.


Want to unsubscribe from this list?
Send a message to

More information about the Cygwin mailing list