[SOLVED] How to build pygtk with non system default python?
Linux - SoftwareThis forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
How to build pygtk with non system default python?
I'm on Debian Lenny. I've built and installed python-3.2 in /opt/python-3.2. Then i want to build and install pygtk, pycairo with /opt/python-3.2 and install them in that folder and not to use system default python (which is python-2.6) for their build process.
How do I tell pygtk and pycairo 's configure and makefile script to use /opt/python-3.2 's interpreter, include file and library for their build process(and not the system default python)?
I tried doing ./configure --help in pygtk folder but there was no option for specific non-system default python's folder location. Anyone has any ideas?
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,513
Rep:
Python 3 is a new different Python. I guess that the pygtk and pycairo
you can get now are for Python 2.
But anyway this works for setting a 'python' : grep -n PYTHON configure
to find where in 'configure' PYTHON is defined, and then edit PYTHON = " "
to : PYTHON = /opt/python-3.2/bin/python
Suggest : Read about Python 3, and find what has to be changed to
make it possible porting Python 2 applications to "3".
..
Python 3 is a new different Python. I guess that the pygtk and pycairo
you can get now are for Python 2.
But anyway this works for setting a 'python' : grep -n PYTHON configure
to find where in 'configure' PYTHON is defined, and then edit PYTHON = " "
to : PYTHON = /opt/python-3.2/bin/python
Suggest : Read about Python 3, and find what has to be changed to
make it possible porting Python 2 applications to "3".
..
Thank you for your help. I'll look into it. Also I'll check what you said about porting python 2 app to python 3.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.