2 different python versions / how to install packages?

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Logan

    2 different python versions / how to install packages?

    I have two different Python versions on my Linux system
    (2.2 and 2.3). I cannot remove version 2.2 because many
    configuration files of the system depend on this version
    of Python (and its extensions).

    Now I want to install extension packages for Python 2.3;
    if the package is distributed via Distutils, this is no
    problem: 'python2.3 setup.py install' will do the job (i.e.
    put everything in the 'site-packages' folder of Python 2.3).

    But how do I e.g. install PyGtk etc. etc. for my second
    Python version (2.3)???

    --
    mailto: logan@phreaker( NoSpam).net

  • Logan

    #2
    Re: 2 different python versions / how to install packages?

    On Fri, 21 Nov 2003 22:41:45 +0100, Logan wrote:
    [color=blue]
    > I have two different Python versions on my Linux system
    > (2.2 and 2.3). I cannot remove version 2.2 because many
    > configuration files of the system depend on this version
    > of Python (and its extensions).
    >
    > Now I want to install extension packages for Python 2.3;
    > if the package is distributed via Distutils, this is no
    > problem: 'python2.3 setup.py install' will do the job (i.e.
    > put everything in the 'site-packages' folder of Python 2.3).
    >
    > But how do I e.g. install PyGtk etc. etc. for my second
    > Python version (2.3)???[/color]

    OK, figured it out for the following (compiling everything from
    the sources):

    - Tcl/Tk 8.4.4 (separate from Tcl/Tk 8.3.5 of Fedora Core 1)
    - Python 2.3.2 with Tkinter
    - libxml2/libxslt Python-bindings (libxml2 2.5.11)
    - PyGTK 2.0.0 (Python bindings for GTK+ 2.0.x resp. 2.2.x)

    Remark: This was not as straightforward as I thought; I think
    (but maybe I am wrong) that Python is a mess on Red Hat 9 resp.
    Fedora Core 1 Linux. If someone is interested in how to install
    and use a 'separate & clean' Python 2.3 as described above on
    Fedora Core 1, please let me know. I could post a short 'HOWTO'.

    --
    mailto: logan@phreaker( NoSpam).net

    Comment

    • Nick Vargish

      #3
      Re: 2 different python versions / how to install packages?

      I would install Python 2.3 in a seperate location from the system
      version. The system version is probably in /usr/bin, so install Python
      2.3 with "--prefix=/usr/local".

      Make sure /usr/local/bin is before /usr/bin in your PATH. Then, when
      you run configure for the extensions you want to install, the
      configure script should pick up /usr/local/bin/python, and all should
      be well.

      You will also need to make sure /usr/local/bin is before /usr/bin if
      you use "#!/usr/bin/env python" in your scripts. Or you could just
      explicitly say "#!/usr/local/bin/python" to make sure you're using the
      "correct" version.

      Nick

      --
      # sigmask || 0.2 || 20030107 || public domain || feed this to a python
      print reduce(lambda x,y:x+chr(ord(y )-1),' Ojdl!Wbshjti!=o bwAcboefstobudi/psh?')

      Comment

      • Ranger_Nemo

        #4
        Re: 2 different python versions / how to install packages?

        """
        If someone is interested in how to install and use a 'separate &
        clean' Python 2.3 as described above on Fedora Core 1, please let me
        know. I could post a short 'HOWTO'.
        """

        I would. I've been working on it a bit for a couple weeks and haven't
        made any progress.

        TTFN,

        Ranger_Nemo

        Comment

        • Logan

          #5
          Re: 2 different python versions / how to install packages?

          On Tue, 25 Nov 2003 06:03:36 -0800, Ranger_Nemo wrote:
          [color=blue]
          > """
          > If someone is interested in how to install and use a 'separate &
          > clean' Python 2.3 as described above on Fedora Core 1, please let me
          > know. I could post a short 'HOWTO'.
          > """
          >
          > I would. I've been working on it a bit for a couple weeks and haven't
          > made any progress.[/color]

          Hi Ranger Nemo,

          I posted the HOWTO in a new thread called

          'HOWTO: Python 2.3 on Fedora Core 1 Linux'
          (posted on Nov., 26)

          Please check it out!

          HTH, L.


          --
          mailto: logan@phreaker( NoSpam).net

          Comment

          • Doveclaw

            #6
            Re: 2 different python versions / how to install packages?

            Just wondering, but why would this be a problem. Fedora, like many Linux
            distributions, has the irritating habit of installing the entire
            distribution under /usr without making logical use of the /usr/local
            tree. You just download the source, do the traditional
            configure/make/make install dance and your good to go. The only
            difference is you must type python2.3 since the python in /usr/bin will
            take precedence over the one in /usr/local/bin. I'm using Fedora right
            now, and all though I have not yet installed 2.3 on this distribution
            the above is the standard way to install Python and I can't find much of
            a reason as to why this wouldn't work.

            On Tue, 2003-11-25 at 21:51, Logan wrote:[color=blue]
            > On Tue, 25 Nov 2003 06:03:36 -0800, Ranger_Nemo wrote:
            >[color=green]
            > > """
            > > If someone is interested in how to install and use a 'separate &
            > > clean' Python 2.3 as described above on Fedora Core 1, please let me
            > > know. I could post a short 'HOWTO'.
            > > """
            > >
            > > I would. I've been working on it a bit for a couple weeks and haven't
            > > made any progress.[/color]
            >
            > Hi Ranger Nemo,
            >
            > I posted the HOWTO in a new thread called
            >
            > 'HOWTO: Python 2.3 on Fedora Core 1 Linux'
            > (posted on Nov., 26)
            >
            > Please check it out!
            >
            > HTH, L.
            >
            >
            > --
            > mailto: logan@phreaker( NoSpam).net[/color]
            --
            Doveclaw <doveclaw@users .sourceforge.ne t>



            Comment

            Working...