Last active
December 28, 2015 20:46
-
-
Save Brant/9993559 to your computer and use it in GitHub Desktop.
Install Python2.7 on Redhat/CentOS
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 | |
# Install Python 2.7.8 alternatively | |
yum groupinstall "development tools" -y | |
yum 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.9/Python-2.7.8.tgz | |
tar xvfz Python-2.7.9.tgz | |
cd Python-2.7.9 | |
./configure --prefix=/usr/local --enable-shared LDFLAGS="-Wl,-rpath /usr/local/lib" | |
make && make altinstall | |
cd .. | |
cd .. | |
rm -rf tmp |
updated for 2.7.9
I think you have a small bug. You want to install 2.7.9 but you make one reference to 2.7.8 in:
I think libffi-devel is just libffi now.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
updated for 2.7.8