Python's Archiver

為方便港臺同胞閱覽,Python中國特別推出簡繁體內容轉換功能

spyler 发表于 2008-11-13 16:22

请教:如何在freebsd中安装psycopy2-2.08

请教:如何在freebsd中安装psycopy2-2.08
操作系统 freebsd7.0  python2.5.1系统自带
已安装postgresql8.3.5(源码编译)  django1.0
但安装 psycopy2-2.08时,总是有错误:

www# cd psycopg2-2.0.8
www# python setup.py build
running build
running build_py
running build_ext
building 'psycopg2._psycopg' extension
cc -fno-strict-aliasing -DNDEBUG -O2 -fno-strict-aliasing -pipe -D__wchar_t=wchar_t -DTHREAD_STACK_SIZE=0x20000 -fPIC -DPY_MAJOR_VERSION=2 -DPY_MINOR_VERSION=5 -DHAVE_PYBOOL=1 -DHAVE_DECIMAL=1 -DHAVE_PYDATETIME=1 -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.0.8 (dec dt ext pq3)" -DPG_MAJOR_VERSION=8 -DPG_MINOR_VERSION=3 -DPG_PATCH_VERSION=5 -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -DHAVE_PQPROTOCOL3=1 -I/usr/local/include/python2.5 -I. -I/usr/local/pgsql/include -I/usr/local/pgsql/include/server -c psycopg/psycopgmodule.c -o build/temp.freebsd-7.0-RELEASE-i386-2.5/psycopg/psycopgmodule.o
In file included from psycopg/psycopgmodule.c:26:
./psycopg/config.h:135: error: static declaration of 'round' follows non-static declaration
error: command 'cc' failed with exit status 1
www#                    


在Magiclinux 中安装 能成功安装没有此错误,
在Freebsd7.0中就是不行。请高手出手相助.

spyler 发表于 2008-11-13 21:13

自己解决了。

cd /usr/ports/databases/py-psycopg2
make install clean

会下载两个文件 :
psycopg2-2.0.6.tar.gz
egenix-mx-base-2.0.6.tar.gz

一直没找到psycopg2的ports目录,
而且还不知道对egenix有依赖关系。

页: [1]

Powered by Discuz! Archiver 6.1.0  © 2001-2007 Comsenz Inc.