Created
April 8, 2015 09:35
-
-
Save rmetzler/29addb7588a9a3f52127 to your computer and use it in GitHub Desktop.
Build Python from source on SLES
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# | |
# shamelessly copied from http://stackoverflow.com/a/11371726 | |
# | |
# Install Python 2.7.2 alternatively | |
# | |
zypper install -t pattern sdk_c_c++ -y | |
zypper install readline-devel openssl-devel gmp-devel ncurses-devel gdbm-devel zlib-devel expat-devel libGL-devel tk tix gcc-c++ libX11-devel glibc-devel bzip2 tar tcl-devel tk-devel pkgconfig tix-devel bzip2-devel sqlite-devel autoconf db4-devel libffi-devel valgrind-devel -y | |
mkdir tmp | |
cd tmp | |
wget http://python.org/ftp/python/2.7.2/Python-2.7.2.tgz | |
tar xvfz Python-2.7.2.tgz | |
cd Python-2.7.2 | |
./configure --prefix=/opt/python2.7 --enable-shared | |
make | |
make altinstall | |
echo "/opt/python2.7/lib" >> /etc/ld.so.conf.d/opt-python2.7.conf | |
ldconfig | |
cd .. | |
cd .. | |
rm -rf tmp |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment