Re: about widget construction kit

Discussion in 'Python' started by Shi Mu, Nov 11, 2005.

  1. Shi Mu

    Shi Mu Guest

    On 11/11/05, Fredrik Lundh <> wrote:
    > Shi Mu wrote:
    >
    > > > > I tried to install WCK(Widget Construction Kit (WCK)):
    > > > >
    > > > > C:\Python23>python tkinter3000-1.0-20031212\setup.py install
    > > > > Traceback (most recent call last):
    > > > > File "tkinter3000-1.0-20031212\setup.py", line 23, in ?
    > > > > WCK_VERSION = setuplib.find_version("WCK/__init__.py")
    > > > > File "C:\wget2\tkinter3000-1.0-20031212\setuplib.py", line 74, in find_version
    > > > > for line in open(filename).readlines():
    > > > > IOError: [Errno 2] No such file or directory: 'WCK/__init__.py'
    > > > >
    > > > > I checked my files and found there is a __init__.py and got confused
    > > > > why the error came out?
    > > >
    > > > if you're using windows, please use a prebuilt version of the WCK.
    > > >
    > > > I also recommend using the 1.1b1 release; it's a lot better than 1.0.
    > > >
    > > > if you really want to build it yourself, and you have the right compilers
    > > > and all Tcl/Tk build files in the right places, change to the source directory
    > > > before running the setup script.

    >
    > > if I run python command, I need to go
    > > to the directory where python is installed, so how can I change to the
    > > source directory at the same time?

    >
    > you're 100% sure that you have a working compiler and the right Tcl/Tk
    > build files in the right place, but you don't know how to run an executable
    > from another directory?
    >
    > hmm.
    >
    > here are three ways:
    >
    > 1. pass in the full path to the executable:
    >
    > cd tkinter3000-1.0-20031212
    > c:\python23\python setup.py install
    >
    > 2. add the python installation directory to the path. random
    > google link:
    >
    > http://www.computerhope.com/issues/ch000549.htm
    >
    > when you've updated the environment, open up a new command
    > window, and do
    >
    > cd tkinter3000-1.0-20031212
    > python setup.py install
    >
    > 3. if you used a python.org installer, it's likely that you can run
    > the setup.py file directly:
    >
    > cd tkinter3000-1.0-20031212
    > setup.py install
    >

    still confused by th first way you mentioned. If I cd
    tkinter3000-1.0-20031212, i will be enter the directory witht hte
    setup.py; for example, it is located as
    c:\temp\tkinter3000-1.0-20031212\setup.py
    However, I need to use c:\python23\python setup.py install to process
    the installation, how did python know where the file of "setup.py"
    located?
    Shi Mu, Nov 11, 2005
    #1
    1. Advertising

  2. Shi Mu wrote:
    > On 11/11/05, Fredrik Lundh <> wrote:
    > > 1. pass in the full path to the executable:
    > >
    > > cd tkinter3000-1.0-20031212
    > > c:\python23\python setup.py install
    > > ...
    > >

    > still confused by th first way you mentioned. If I cd
    > tkinter3000-1.0-20031212, i will be enter the directory witht hte
    > setup.py; for example, it is located as
    > c:\temp\tkinter3000-1.0-20031212\setup.py
    > However, I need to use c:\python23\python setup.py install to process
    > the installation, how did python know where the file of "setup.py"
    > located?


    Since a full path was not given for the 'setup.py' file in the second
    line, it will be assumed to be in the current directory which was set
    by the 'cd' command in the first line.

    HTH
    Martin Miller, Nov 12, 2005
    #2
    1. Advertising

  3. Shi Mu

    Shi Mu Guest

    On 11 Nov 2005 16:06:37 -0800, Martin Miller
    <> wrote:
    > Shi Mu wrote:
    > > On 11/11/05, Fredrik Lundh <> wrote:
    > > > 1. pass in the full path to the executable:
    > > >
    > > > cd tkinter3000-1.0-20031212
    > > > c:\python23\python setup.py install
    > > > ...
    > > >

    > > still confused by th first way you mentioned. If I cd
    > > tkinter3000-1.0-20031212, i will be enter the directory witht hte
    > > setup.py; for example, it is located as
    > > c:\temp\tkinter3000-1.0-20031212\setup.py
    > > However, I need to use c:\python23\python setup.py install to process
    > > the installation, how did python know where the file of "setup.py"
    > > located?

    >
    > Since a full path was not given for the 'setup.py' file in the second
    > line, it will be assumed to be in the current directory which was set
    > by the 'cd' command in the first line.
    >
    > HTH

    I tried again and got the follwoing message:
    *** cannot find Tcl/Tk headers and library files
    change the TCL_ROOT variable in the setup.py file
    but i have already installed TCL under python23
    Shi Mu, Nov 12, 2005
    #3
  4. Shi Mu wrote:

    > I tried again and got the follwoing message:
    > *** cannot find Tcl/Tk headers and library files
    > change the TCL_ROOT variable in the setup.py file
    > but i have already installed TCL under python23


    hmm. I still think it would be easier if you used a prebuilt version, like
    everyone else.

    (if you insist on using an old source release instead of the latest binaries,
    follow the instructions, and make sure the TCL_ROOT variable points to
    the location of the Tcl/Tk development libraries (the directory that con-
    tains Tcl's "include" and "lib" directories, that is))

    </F>
    Fredrik Lundh, Nov 12, 2005
    #4
  5. Shi Mu

    Shi Mu Guest

    On 11/12/05, Fredrik Lundh <> wrote:
    > Shi Mu wrote:
    >
    > > I tried again and got the follwoing message:
    > > *** cannot find Tcl/Tk headers and library files
    > > change the TCL_ROOT variable in the setup.py file
    > > but i have already installed TCL under python23

    >
    > hmm. I still think it would be easier if you used a prebuilt version, like
    > everyone else.
    >
    > (if you insist on using an old source release instead of the latest binaries,
    > follow the instructions, and make sure the TCL_ROOT variable points to
    > the location of the Tcl/Tk development libraries (the directory that con-
    > tains Tcl's "include" and "lib" directories, that is))


    what is Tcl/Tk development libraries? I have a tcl folder under c:\python23..
    Is that what you mean?
    Regards,
    Shi Mu, Nov 12, 2005
    #5
  6. "Shi Mu" wrote:

    > > > I tried again and got the follwoing message:
    > > > *** cannot find Tcl/Tk headers and library files
    > > > change the TCL_ROOT variable in the setup.py file
    > > > but i have already installed TCL under python23

    > >
    > > hmm. I still think it would be easier if you used a prebuilt version, like
    > > everyone else.
    > >
    > > (if you insist on using an old source release instead of the latest binaries,
    > > follow the instructions, and make sure the TCL_ROOT variable points to
    > > the location of the Tcl/Tk development libraries (the directory that con-
    > > tains Tcl's "include" and "lib" directories, that is))

    >
    > what is Tcl/Tk development libraries?


    the stuff you get if you install tcl-devel/tk-devel on unix, or a complete
    Tcl/Tk distribution on Windows (e.g. ActiveTcl).

    > I have a tcl folder under c:\python23. Is that what you mean?


    if you set TCL_ROOT to that directory and setup still says that it cannot
    find the development files, the answer is most likely "no".

    can you explain why you cannot use a prebuilt version?

    </F>
    Fredrik Lundh, Nov 12, 2005
    #6
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Shi Mu

    about widget construction kit

    Shi Mu, Nov 11, 2005, in forum: Python
    Replies:
    0
    Views:
    282
    Shi Mu
    Nov 11, 2005
  2. Ook
    Replies:
    10
    Views:
    553
  3. Replies:
    0
    Views:
    331
  4. Frederic Rentsch
    Replies:
    0
    Views:
    238
    Frederic Rentsch
    Jul 8, 2012
  5. Terry Reedy
    Replies:
    15
    Views:
    633
    Frederic Rentsch
    Jul 16, 2012
Loading...

Share This Page