當我嘗試透過 yum 安裝 odoo 時,出現以下錯誤。
已完成的依賴解析套件:odoo-8.0_20150617-1.noarch (odoo-nightly) 需要:python(abi) = 2.7 安裝:python-2.6.6-52.el6.x86_64 (@base) python(abi) = 2.6可用: python-2.6.6-51.el6.x86_64 (test) python(abi) = 2.6 您可以嘗試使用 --skip-broken 來解決問題 您可以嘗試運行: rpm -Va --nofiles --nodigest
我遵循的步驟如下所述。
- 安裝了 pstgresql 9.4.4
- 將 python 2.6 更新為 2.7
- 配置的odoo儲存庫
- 嘗試使用 yum install odoo 安裝 odoo
我也更新了python。
蟒蛇——版本
Python 2.7.6
有人可以幫我解決這個問題嗎
答案1
正確的方法是建立虛擬環境。
yum -y install wget gcc zlib-devel bzip2-devel openssl-devel ncurses-devel sqlite-devel readline-devel tk-devel gdbm-devel db4-devel libffi-devel libxslt libxslt-devel libxml2 libxml2-devel openldap-devel libjpeg-turbo-devel openjpeg-devel libtiff-devel git libpng libXext libz.so.1 xorg-x11-fonts-Type1 curl cabextract
cd /usr/local/src
wget http://python.org/ftp/python/2.7.8/Python-2.7.9.tgz
tar -xzf 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
wget https://bitbucket.org/pypa/setuptools/raw/bootstrap/ez_setup.py -O - | /usr/local/bin/python2.7
/usr/local/bin/easy_install-2.7 pip virtualenv
這是 centos 6.6 上必須具備的
[root@server ~]# python --version
Python 2.6.6
[root@server ~]# yum install python
Loaded plugins: fastestmirror
Setting up Install Process
Loading mirror speeds from cached hostfile
* base: mirror1.babylon.network
* epel: mirror1.babylon.network
* extras: mirror1.babylon.network
* updates: mirror1.babylon.network
Package python-2.6.6-52.el6.x86_64 already installed and latest version
Nothing to do
[root@server ~]# cat /etc/redhat-release
CentOS release 6.6 (Final)
這是我找到的完整指南: https://odootricks.wordpress.com/2014/09/30/installing-odoo-8-on-centos-6-with-virtual-python-install/