Installing Plone on Unix Derivatives
Often it can be difficult get the steps right to install Zope/Plone on Linux/BSD machines. Here is some bash code that shows a few good procedures.
# Originale versioner: Zope-2.7.3-0, python 2.3.4 # INSTANCE_HOME eg example.com or other directory name ########################################### # On FreeBSD ########################################### # there is a member called zope in the server... cd /home/zope mkdir downloads mkdir pythons mkdir zopes mkdir instances # Install python cd /home/zope/downloads/ wget http://www.python.org/ftp/python/2.3.4/Python-2.3.4.tgz tar xfz Python-2.3.4.tgz cd /home/zope/downloads/Python-2.3.4 # change make file (BSD ONLY) vi Makefile.pre.in #Go to line 59 where it says: #CPPFLAGS= -I. -I$(srcdir)/Include #and change it to this... #CPPFLAGS= -DTHREAD_STACK_SIZE=0x100000 -I. -I$(srcdir)/Include ./configure --prefix=/home/zope/pythons/python-2.3.4 make make altinstall cd /home/zope/downloads/ # Install zope wget http://www.zope.org/Products/Zope/2.7.3/Zope-2.7.3-0.tgz tar xfz Zope-2.7.3-0.tgz cd /home/zope/downloads/Zope-2.7.3-0 ./configure --prefix=/home/zope/zopes/Zope-2.7.3-0 --with-python=/home/zope/pythons/python-2.3.4/bin/python2.3 make make install cd /home/zope/downloads/ #-------- # Install MySQLdb wget http://www.zope.org/Members/adustman/Products/MySQLdb/1.2.0/MySQL-python-1.2.0.tar.gz tar xfz MySQL-python-1.2.0.tar.gz cd /home/zope/downloads/MySQL-python-1.2.0 /home/zope/pythons/python-2.3.4/bin/python2.3 setup.py build /home/zope/pythons/python-2.3.4/bin/python2.3 setup.py install cd /home/zope/downloads/ # Install PIL wget http://effbot.org/downloads/Imaging-1.1.5.tar.gz tar xfz Imaging-1.1.5.tar.gz cd /home/zope/downloads/Imaging-1.1.5 /home/zope/pythons/python-2.3.4/bin/python2.3 setup.py build /home/zope/pythons/python-2.3.4/bin/python2.3 setup.py install cd /home/zope/downloads/ # make instance /home/zope/zopes/Zope-2.7.3-0/bin/mkzopeinstance.py /home/zope/instances/INSTANCE_HOME # Install ZMySQLDA wget http://www.zope.org/Members/adustman/Products/ZMySQLDA/2.0.8/ZMySQLDA-2.0.8.tar.gz tar xfz ZMySQLDA-2.0.8.tar.gz cp -r /home/zope/downloads/lib/python/Products/ZMySQLDA /home/zope/instances/INSTANCE_HOME/Products chown zope /home/zope/instances/INSTANCE_HOME/Products/ZMySQLDA # Install mxTidy cd /home/zope/downloads/ wget http://www.egenix.com/files/python/egenix-mx-base-2.0.6.tar.gz tar xfz egenix-mx-base-2.0.6.tar.gz cd /home/zope/downloads/egenix-mx-base-2.0.6 /home/zope/pythons/python-2.3.4/bin/python2.3 setup.py build /home/zope/pythons/python-2.3.4/bin/python2.3 setup.py install wget http://www.egenix.com/files/python/egenix-mx-experimental-0.9.0.tar.gz tar xfz egenix-mx-experimental-0.9.0.tar.gz cd /home/zope/downloads/egenix-mx-experimental-0.9.0 /home/zope/pythons/python-2.3.4/bin/python2.3 setup.py build /home/zope/pythons/python-2.3.4/bin/python2.3 setup.py install cd /home/zope/downloads/ ########################################### # Redhat fedora core 4 ########################################### # Original versions: Zope 2.7.3-0, python 2.3.4 # Install python wget http://www.python.org/ftp/python/2.3.4/Python-2.3.4.tgz tar xfz Python-2.3.4.tgz cd /home/zope/downloads/python-2.3.4 ./configure --prefix=/home/zope/pythons/python-2.3.4 make make altinstall cd /home/zope/downloads/ # Install zope wget http://www.zope.org/Products/Zope/2.7.3/Zope-2.7.3-0.tgz tar xfz Zope-2.7.3-0.tgz cd /home/zope/downloads/Zope-2.7.3-0 ./configure --prefix=/home/zope/zopes/Zope-2.7.3-0 --with-python=/home/zope/pythons/python-2.3.4/bin/python2.3 make make install cd /home/zope/downloads/ # Install MySQLdb wget http://www.zope.org/Members/adustman/Products/MySQLdb/1.2.0/MySQL-python-1.2.0.tar.gz tar xfz MySQL-python-1.2.0.tar.gz cd /home/zope/downloads/MySQL-python-1.2.0 /home/zope/pythons/python-2.3.4/bin/python2.3 setup.py build /home/zope/pythons/python-2.3.4/bin/python2.3 setup.py install cd /home/zope/downloads/ # make instance /home/zope/zopes/Zope-2.7.3-0/bin/mkzopeinstance.py /home/zope/instances/www.INSTANCE_HOME # Install ZMySQLDA wget http://www.zope.org/Members/adustman/Products/ZMySQLDA/2.0.8/ZMySQLDA-2.0.8.tar.gz tar xfz ZMySQLDA-2.0.8.tar.gz cp -r /home/zope/downloads/lib/python/Products/ZMySQLDA /home/zope/instances/INSTANCE_HOME/Products chown zope /home/zope/instances/INSTANCE_HOME/Products/ZMySQLDA########################################### # Debian notes ########################################### # You can easliy miss some stuff on a minimal debian, so if you get some # complaints during the compilation of either Python, zope or PIL, # you probably need to do some of the below: # (I did them from memory, so they are probably buggy.) # compiler apt-get install gcc g++ make # zlib support for zope apt-get install zlib zlib-dev # jpeg suport for PIL apt-get install libjpeg62 libjpeg62-dev
########################################### # Apache notes ########################################### Then there is the setup of the Apache server, which can look something like this. NameVirtualHost * <VirtualHost *> ServerName www.example.com ServerAdmin admin DocumentRoot "/var/www/html" RewriteEngine on RewriteRule ^/(.*) http://localhost:8080/VirtualHostBase/http/www.example.com:80/portal/VirtualHostRoot/$1 [P] </VirtualHost>
good page
Posted by
Anonymous User
at
2007-05-16 12:42 PM
hi max,
Great work. THX for sharing it. I just want to add some notes:
1. Instead of editing the makefile on a bsd system to add the THREAD_STACK_SIZE, one can just give it in the command line as parameter to make:
$ make OPT="-DNDEBUG -g -O3 -Wall -Wstrict-prototypes -DTHREAD_STACK_SIZE=1000000"
2. About debian:
It is better to use aptitude instead of apt-get if you want to have a clean system. It is a hell to clean your system if you have installed all things with apt-get. aptitude removes (also give you the option to not remove) unused dependencies when you uninstall. apt-get does not.
3. About apache conf:
The [P] in the rewrite rule is for proxy and to prevent the server to be used as open-proxy:
<Proxy *>
Order Deny,Allow
Deny from all
Allow from my.host.com
</Proxy>
/Mustapha
Great work. THX for sharing it. I just want to add some notes:
1. Instead of editing the makefile on a bsd system to add the THREAD_STACK_SIZE, one can just give it in the command line as parameter to make:
$ make OPT="-DNDEBUG -g -O3 -Wall -Wstrict-prototypes -DTHREAD_STACK_SIZE=1000000"
2. About debian:
It is better to use aptitude instead of apt-get if you want to have a clean system. It is a hell to clean your system if you have installed all things with apt-get. aptitude removes (also give you the option to not remove) unused dependencies when you uninstall. apt-get does not.
3. About apache conf:
The [P] in the rewrite rule is for proxy and to prevent the server to be used as open-proxy:
<Proxy *>
Order Deny,Allow
Deny from all
Allow from my.host.com
</Proxy>
/Mustapha
Note for ubuntu 8.10 Intrepid Ibex
Posted by
maxm
at
2008-11-25 01:22 PM
http://orip.org/2008/10/building-python-235-on-ubuntu-intrepid.html
Short version: add BASECFLAGS=-U_FORTIFY_SOURCE to the 'configure' command line.
./configure --prefix=/home/zope/pythons/python-2.3.7 BASECFLAGS=-U_FORTIFY_SOURCE
Short version: add BASECFLAGS=-U_FORTIFY_SOURCE to the 'configure' command line.
./configure --prefix=/home/zope/pythons/python-2.3.7 BASECFLAGS=-U_FORTIFY_SOURCE
Replies to this comment