Install Plone 4.3.2 (4307) on a Mageia 3 Linux box

Denis Bitouzé Membre non connecté
-
- Voir le profil du membre Denis Bitouzé
- Inscrit le : 06/10/2013
- Site internet
- Groupes :
Download Plone-4.3.2-UnifiedInstaller
Code BASH :
wget https://launchpad.net/plone/4.3/4.3.2/+download/Plone-4.3.2-UnifiedInstaller.tgz tar xfj Plone-4.3.2-UnifiedInstaller.tar.bz2 cd Plone-4.3.2-UnifiedInstaller/
Avoid 'pyconfig.h:2:32: error: #include nested too deeply' error during installation
Running directly the installation, for instance with:
Code BASH :
./install.sh standalone
will fail with the error:
Code BASH :
pyconfig.h:2:32: error: #include nested too deeply
To avoid it:
Code BASH :
cd packages tar xfz virtualenv-1.10.1.tar.gz cd virtualenv-1.10.1/
then edit the file 'virtualenv.py' to replace its lines 1009 to 1019:
Code PYTHON :
multiarch_exec = '/usr/bin/multiarch-platform' if is_executable_file(multiarch_exec): # In Mageia (2) and Mandriva distros the include dir must be like: # virtualenv/include/multiarch-x86_64-linux/python2.7 # instead of being virtualenv/include/python2.7 p = subprocess.Popen(multiarch_exec, stdout=subprocess.PIPE, stderr=subprocess.PIPE) stdout, stderr = p.communicate() # stdout.strip is needed to remove newline character inc_dir = join(home_dir, 'include', stdout.strip(), py_version + abiflags) else: inc_dir = join(home_dir, 'include', py_version + abiflags)
by:
Code PYTHON :
inc_dir = join(home_dir, 'include', py_version + abiflags)
Install Plone
Install Plone by running:
Code BASH :
./install.sh standalone
After this, check if the default installation is okay by running:
Code BASH :
cd ~/Plone/zinstance ./bin/plonectl fg
If the message:
Code BASH :
YYYY-MM-DD HH:MM:SS INFO Zope Ready to handle requests
appears, Plone is correctly installed so just hit '^C’ to stop it.
Adding 'eea.daviz' add-on to buildout.cfg
Edit the file 'buildout.cfg' and add, line 79:
Code PYTHON :
eea.daviz
Avoid 'gcc: error: /usr/lib/libcurl.a: No such file or directory' error during buildout
Running 'buildout' directly:
Code BASH :
./bin/buildout
will fail with the error:
Code BASH :
gcc: error: /usr/lib/libcurl.a: No such file or directory error: Setup script exited with error: command 'gcc' failed with exit status 1 An error occurred when trying to install pycurl2 7.20.0. Look above this message for any errors that were output by easy_install. While: Installing instance. Getting distribution for 'pycurl2'. Error: Couldn't install: pycurl2 7.20.0
because 'pycurl', which is (indirectly) required by 'eea.daviz'
add-on, is shipped in a too old version. So, in order to avoid this
error, check 'git' RPM is installed and get the very last version of
'pycurl2':
Code BASH :
cd ~/ mkdir git-repositories cd git-repositories git clone https://github.com/Lispython/pycurl.git
This should have created a 'pycurl' directory in 'git-repositories' directory.
Then replace 'pycurl2' shipped with Plone by the git-version:
Code BASH :
cd ~/Plone/buildout-cache/downloads/dist/ tar xfz pycurl2-7.20.0.tar.gz cd pycurl2-7.20.0/ cp -rf ~/git-repositories/pycurl/* . cd .. tar cfz pycurl2-7.20.0.tar.gz pycurl2-7.20.0
Finally run 'buildout':
Code BASH :
cd ~/Plone/zinstance ./bin/buildout
Avoid 'ImportError: No module named component.hooks' error
Edit: !!! This error doesn't arise with the recent 7.8 version of eea.daviz !!!
The following is hence useless for this version (and the later ones).
Running Plone directly:
Code BASH :
./bin/plonectl fg
will fail with the error:
Code PYTHON :
[...] ZopeXMLConfigurationError: File "/home/bitouze/Plone-not-working/buildout-cache/eggs/eea.daviz-7.7-py2.7.egg/eea/daviz/configure.zcml", line 11.2-11.32 ZopeXMLConfigurationError: File "/home/bitouze/Plone-not-working/buildout-cache/eggs/eea.daviz-7.7-py2.7.egg/eea/daviz/browser/configure.zcml", line 6.2-12.6 ImportError: No module named component.hooks
Here are the sufficient steps to avoid it:
Perform two changes in 'daviz.py' file:
Code BASH :
cd ~/Plone/buildout-cache/eggs/eea.daviz-7.7-py2.7.egg/eea/daviz/browser/app/
Edit 'daviz.py' file and replace:
- line 3:
Code PYTHON :from zope.app.component.hooks import getSite
by:
Code PYTHON :from zope.component.hooks import getSite
- line 6:
Code PYTHON :from zope.app.container.interfaces import INameChooser
by:
Code PYTHON :from zope.app.component.hooks import getSite
Perform one change in 'controlpanel.py' file
Code BASH :
cd ~/Plone/buildout-cache/eggs/eea.daviz-7.7-py2.7.egg/eea/daviz/controlpanel/
Edit 'controlpanel.py' file and replace line 7:
Code PYTHON :
from zope.app.component.hooks import getSite
by:
Code PYTHON :
from zope.component.hooks import getSite
Édité par Denis Bitouzé Le 09/10/2013 à 09h53
Denis

Denis Bitouzé Membre non connecté
-
- Voir le profil du membre Denis Bitouzé
- Inscrit le : 06/10/2013
- Site internet
- Groupes :
Denis

Aranud Membre non connecté
-
- Voir le profil du membre Aranud
- Inscrit le : 06/11/2010
- Groupes :
Sinon forum officiel : https://forums.mageia.org/en/

Denis Bitouzé Membre non connecté
-
- Voir le profil du membre Denis Bitouzé
- Inscrit le : 06/10/2013
- Site internet
- Groupes :
Aranud :
Si tu veux faire un article sur le wiki pourquoi pas en français mais un sujet comme ça sur le forum, j'en vois pas trop utilité.
Sinon forum officiel : https://forums.mageia.org/en/
Sinon forum officiel : https://forums.mageia.org/en/
OK, il est vrai que c'est peut-être plus approprié sur un Wiki, mais lequel me conseilleriez-vous : sur les pages https://wiki.mageia.org/en/Main_Page et https://wiki.mageia.org/fr/Accueil, je ne vois pas où je pourrais poster un tel article.
Denis
Répondre
Vous n'êtes pas autorisé à écrire dans cette catégorie