0

How to download python 3.6 for opensuse linux.

I try to download it by using yum but its not downloading then I try to download it by using YaST it says change your URL. I already have Python version 2.7.5 on my system as well as 3.3 is also downloaded.

In which directory should I download it.

After downloading python3.6 I want to download anaconda and for that 3.6 python Version is required so how to access 3.6 Python version instead of other versions.

Yum code on terminal:

 yum install python

wget https://www.python.org/ftp/python/3.5.2/Python-3.5.2.tgz

tar -xvzf Python-3.5.2.tgz

cd Python-3.5.2

 ./configure --prefix=/usr/bin

 make altinstall

How I add repository in YaST https media type:

URL of the repository:https://www.python.org/ftp/python/3.6.0/Python-3.6.0.tgz

Repository name: Python

Error of using YUM command: on usr/bin directory I try to run python3.6:

mysys:/usr/bin/Python-3.6.0 # python3.6
Could not find platform dependent libraries <exec_prefix>
Consider setting $PYTHONHOME to <prefix>[:<exec_prefix>]
Python 3.6.0 (default, Feb  1 2018, 10:59:47) 
[GCC 4.8.1 20130909 [gcc-4_8-branch revision 202388]] on linux
Type "help", "copyright", "credits" or "license" for more information.
Traceback (most recent call last):
  File "/etc/pythonstart", line 7, in <module>
    import readline
ModuleNotFoundError: No module named 'readline'

On home directory:

mysys:/home> python3.3
Python 3.3.2 (default, Jun 13 2013, 16:05:31) [GCC] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> 
[1]+  Stopped                 python3.3
mysys:/home> python3.6
Could not find platform dependent libraries <exec_prefix>
Consider setting $PYTHONHOME to <prefix>[:<exec_prefix>]
Python 3.6.0 (default, Feb  1 2018, 10:59:47) 
[GCC 4.8.1 20130909 [gcc-4_8-branch revision 202388]] on linux
Type "help", "copyright", "credits" or "license" for more information.
Traceback (most recent call last):
  File "/etc/pythonstart", line 7, in <module>
    import readline
ModuleNotFoundError: No module named 'readline'
>>> 
3
  • Can you add the errors you get while installing from source? Feb 1, 2018 at 4:39
  • @Hunter.S.Thompson I have added the errors in the post
    – Rhea
    Feb 1, 2018 at 6:37
  • what is the value for $PYTHONHOME?
    – mcalex
    Feb 2, 2018 at 3:35

1 Answer 1

0

Jani Karhunen has a process for installing python 3.6.

Essentially:

Ensure your yum utils are up to date:

  • sudo yum update
  • sudo yum install yum-utils
  • sudo yum groupinstall development

Install IUS repository:

  • sudo yum install https://centos7.iuscommunity.org/ius-release.rpm

Then install python 3.6:

  • sudo yum install python36u
1
  • I got the same given lines for all the above commands. mysys:/usr/bin> sudo yum update Loaded plugins: aliases, allowdowngrade, basearchonly, changelog, dellsysid, downloadonly, fastestmirror, filter-data, list-data, merge-conf, priorities, protect-packages, protectbase, refresh-updatesd, tmprepo, tsflags, upgrade-helper, verify, versionlock There are no enabled repos. Run "yum repolist all" to see the repos you have. You can enable repos with yum-config-manager --enable <repo> yum repolist all repolist: 0
    – Rhea
    Feb 1, 2018 at 11:12

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .