`
huangro
  • 浏览: 333660 次
  • 性别: Icon_minigender_1
  • 来自: 杭州
社区版块
存档分类
最新评论

Ubuntu中安装pgasync的问题

阅读更多

从http://jamwt.com/pgasync/下载该包,安装其安装的教程执行命令:sudo python setup.py install 

然而,出现一下问题: 
-------------------------------------------------------------------------------------------------------------------------------------------------------------------------
running install
running build
running build_py
creating build
creating build/lib.linux-i686-2.5
creating build/lib.linux-i686-2.5/pgasync
copying pgasync/__init__.py -> build/lib.linux-i686-2.5/pgasync
copying pgasync/pool.py -> build/lib.linux-i686-2.5/pgasync
copying pgasync/pgtypes_int.py -> build/lib.linux-i686-2.5/pgasync
copying pgasync/protocol.py -> build/lib.linux-i686-2.5/pgasync
copying pgasync/format.py -> build/lib.linux-i686-2.5/pgasync
copying pgasync/net.py -> build/lib.linux-i686-2.5/pgasync
copying pgasync/fe.py -> build/lib.linux-i686-2.5/pgasync
copying pgasync/errors.py -> build/lib.linux-i686-2.5/pgasync
copying pgasync/pgtypes.py -> build/lib.linux-i686-2.5/pgasync
running build_ext
building 'pgasync.cache' extension
creating build/temp.linux-i686-2.5
creating build/temp.linux-i686-2.5/pgasync
gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fPIC -I/usr/include/python2.5 -c pgasync/cache.c -o build/temp.linux-i686-2.5/pgasync/cache.o
pgasync/cache.c:3:20: error: Python.h: No such file or directory
pgasync/cache.c:4:26: error: structmember.h: No such file or directory
pgasync/cache.c:13: error: expected specifier-qualifier-list before ‘PyObject’
pgasync/cache.c:14: error: expected specifier-qualifier-list before ‘PyObject’
pgasync/cache.c:15: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘*’ token
pgasync/cache.c:16: error: expected ‘)’ before ‘*’ token
pgasync/cache.c:17: error: expected ‘)’ before ‘*’ token
pgasync/cache.c:19: error: expected ‘)’ before ‘*’ token
pgasync/cache.c:21: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘*’ token
pgasync/cache.c:22: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘*’ token
pgasync/cache.c:23: error: expected ‘)’ before ‘*’ token
pgasync/cache.c:24: error: expected ‘)’ before ‘*’ token
pgasync/cache.c:25: error: expected ‘)’ before ‘*’ token
pgasync/cache.c:28: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘*’ token
pgasync/cache.c:29: error: expected ‘)’ before ‘*’ token
pgasync/cache.c:30: error: expected ‘)’ before ‘*’ token
pgasync/cache.c:31: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘*’ token
pgasync/cache.c:34: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘*’ token
pgasync/cache.c:36: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘*’ token
pgasync/cache.c:37: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘*’ token
pgasync/cache.c:40: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘char’
pgasync/cache.c:46: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘PyTypeObject’
pgasync/cache.c:49: error: expected specifier-qualifier-list before ‘PyObject_HEAD’
pgasync/cache.c:55: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘*’ token
pgasync/cache.c:59: error: expected ‘)’ before ‘*’ token
pgasync/cache.c:60: error: expected ‘)’ before ‘*’ token
pgasync/cache.c:90: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘*’ token
pgasync/cache.c:91: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘*’ token
pgasync/cache.c:129: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘*’ token
pgasync/cache.c:130: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘*’ token
pgasync/cache.c:132: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘*’ token
pgasync/cache.c:134: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘*’ token
pgasync/cache.c:270: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘*’ token
pgasync/cache.c:271: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘*’ token
pgasync/cache.c:318: error: ‘__pyx_n_append’ undeclared here (not in a function)
pgasync/cache.c:318: warning: excess elements in struct initializer
pgasync/cache.c:318: warning: (near initialization for ‘__pyx_intern_tab[0]’)
pgasync/cache.c:318: warning: excess elements in struct initializer
pgasync/cache.c:318: warning: (near initialization for ‘__pyx_intern_tab[0]’)
pgasync/cache.c:319: error: ‘__pyx_n_realloc’ undeclared here (not in a function)
pgasync/cache.c:319: warning: excess elements in struct initializer
pgasync/cache.c:319: warning: (near initialization for ‘__pyx_intern_tab[1]’)
pgasync/cache.c:319: warning: excess elements in struct initializer
pgasync/cache.c:319: warning: (near initialization for ‘__pyx_intern_tab[1]’)
pgasync/cache.c:320: warning: excess elements in struct initializer
pgasync/cache.c:320: warning: (near initialization for ‘__pyx_intern_tab[2]’)
pgasync/cache.c:320: warning: excess elements in struct initializer
pgasync/cache.c:320: warning: (near initialization for ‘__pyx_intern_tab[2]’)
pgasync/cache.c:323: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘*’ token
pgasync/cache.c:333: error: expected ‘)’ before ‘*’ token
pgasync/cache.c:339: error: expected ‘)’ before ‘*’ token
pgasync/cache.c:348: error: expected ‘)’ before ‘*’ token
pgasync/cache.c:355: error: array type has incomplete element type
pgasync/cache.c:356: error: ‘PyCFunction’ undeclared here (not in a function)
pgasync/cache.c:356: error: expected ‘}’ before ‘__pyx_f_5cache_5Cache_realloc’
pgasync/cache.c:357: error: expected ‘}’ before ‘__pyx_f_5cache_5Cache_add’
pgasync/cache.c:358: error: expected ‘}’ before ‘__pyx_f_5cache_5Cache_finish’
pgasync/cache.c:362: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘__pyx_tp_as_number_Cache’
pgasync/cache.c:403: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘__pyx_tp_as_sequence_Cache’
pgasync/cache.c:416: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘__pyx_tp_as_mapping_Cache’
pgasync/cache.c:422: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘__pyx_tp_as_buffer_Cache’
pgasync/cache.c:429: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘PyTypeObject’
pgasync/cache.c:478: error: array type has incomplete element type
pgasync/cache.c:482: warning: return type defaults to ‘int’
pgasync/cache.c: In function ‘DL_EXPORT’:
pgasync/cache.c:482: error: expected declaration specifiers before ‘initcache’
pgasync/cache.c:483: error: expected declaration specifiers before ‘DL_EXPORT’
pgasync/cache.c:501: error: storage class specified for parameter ‘__pyx_filenames’
pgasync/cache.c:501: error: parameter ‘__pyx_filenames’ is initialized
pgasync/cache.c:502: warning: initialization from incompatible pointer type
pgasync/cache.c:504: error: expected declaration specifiers before ‘statichere’
pgasync/cache.c:508: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘{’ token
pgasync/cache.c:518:21: error: compile.h: No such file or directory
pgasync/cache.c:519:25: error: frameobject.h: No such file or directory
pgasync/cache.c:520:23: error: traceback.h: No such file or directory
pgasync/cache.c:522: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘{’ token
pgasync/cache.c:574: error: old-style parameter declarations in prototyped function definition
pgasync/cache.c:574: error: expected ‘{’ at end of input
error: command 'gcc' failed with exit status 1
-----------------------------------------------------------------------------------------------------------------------------------------------------------------------

Google了一把,发现是因为Ubuntu下gcc存在一些问题,并且缺失python.h文件,因此执行以下命令:

1. sudo apt-get install python-dev
从而补充python.h文件

2.sudo apt-get install build-essential
将c编译器补充完整。

再次执行开始的命令,安装虽然仍然有警告,但是成功。

分享到:
评论

相关推荐

    ERPNext安装-ubuntu安装

    Ubuntu ERPNext ubuntu安装 ubuntu安装 ubuntu安装 ubuntu安装 ubuntu安装

    ubuntu20.04安装教程-ubuntu20.04图文安装教程.pdf

    ubuntu:ubuntu20.04图文安装教程ubuntu20.04图文安装教程ubuntu20.04图文安装教程ubuntu20.04图文安装教程ubuntu20.04图文安装教程ubuntu20.04图文安装教程ubuntu20.04图文安装教程ubuntu20.04图文安装教程ubuntu...

    Ubuntu安装教程.zipUbuntu安装教程

    ubuntu20.04安装教程:Ubuntu安装教程Ubuntu安装教程Ubuntu安装教程Ubuntu安装教程Ubuntu安装教程Ubuntu安装教程Ubuntu安装教程Ubuntu安装教程Ubuntu安装教程Ubuntu安装教程Ubuntu安装教程Ubuntu安装教程Ubuntu安装...

    Ubuntu离线安装软件的方法

    到此,本地源目录就算是完成了,下面我们就可以在ubuntu中安装软件了。 当我们需要安装软件时,我们可以使用apt-get方法,但是我们需要先生成要安装的软件的下载脚本。我们可以使用File -> Generate package ...

    Ubuntu的安装-实验报告.pdf

    我们还学习到了 Ubuntu 的基本使用方法,例如,如何在 Ubuntu 中安装软件,如何使用终端等。 三、 问题与思考 在实验过程中,我们遇到了几个问题,例如,在安装 Ubuntu 时,出现了报错 "Error : You must put some...

    ubuntu16.04安装chrome浏览器(附安装步骤)

    在Ubuntu 16.04操作系统中安装Google Chrome浏览器的过程涉及几个关键步骤,因为Chrome并不在Ubuntu的默认软件仓库中。以下是一个详细的指南,帮助您完成这个任务。 首先,我们需要获取Google Chrome的.deb安装包。...

    ubuntu怎么安装tar.gz

    本文主要介绍如何在Ubuntu中安装`.tar.gz`格式的软件包,以及使用新立得软件包管理器和其他命令行方式安装软件。 首先,我们来看`.tar.gz`文件。这种文件格式在Linux中非常常见,它是一种压缩格式,通常用于分发源...

    ubuntu系统安装wireshark离线包,安装步骤详解以及遇到的问题解决方案

    本文将详细介绍如何在Ubuntu上通过离线源码安装Wireshark,包括安装步骤、可能遇到的问题以及相应的解决方案。 首先,我们需要准备以下资源: 1. Wireshark的源码包:wireshark-2.4.2.tar.xz 2. 必要的依赖库:...

    linux Ubuntu下安装 Source insight

    本文将详细介绍如何在Ubuntu下安装Source Insight,并 troubleshooting一些常见的问题。 一、安装Wine ---------------- 在Ubuntu下安装Source Insight之前,需要先安装Wine。Wine是一个开源的实现了Windows API的...

    ubuntu离线安装telnet

    ubuntu离线安装telnet,ubuntu,离线,telnet包

    ubuntu20.04安装QT.pdf

    ubuntu20.04安装QT 一、 安装cmake 二、 安装gcc和g++ 三、 下载QT 四、 安装QT 五、 故障解决

    ubuntu安装python3.9 ubuntu安装python3.9

    在Ubuntu系统中,安装Python 3.9是一个常见的需求,特别是在新版本的Ubuntu如22.04 LTS中,预装的Python版本可能是3.10,这可能不满足某些开发者对特定Python版本的需求。本教程将详细讲解如何在Ubuntu 22.04上从源...

    Ubuntu20.04安装vim出现的相关问题及解决方法

    ### Ubuntu20.04安装vim出现的相关问题及解决方法 #### 一、问题背景与概述 在Linux环境中,Vim是一款非常强大的文本编辑器,它不仅具备基本的文本编辑功能,还支持语法高亮、代码补全等多种高级特性,是开发人员...

    ubuntu中安装锐捷

    在Ubuntu系统中安装锐捷,主要是为了实现对锐捷网络客户端的支持,这通常涉及到的是Linux下的网络认证方式,特别是对于校园网或者企业网络环境。锐捷客户端是针对特定网络环境设计的,它提供了与Windows版类似的认证...

    Ubuntu的OpenMPI安装

    如果需要,可以在Ubuntu软件中心中安装OPAL库。 问题解决 如果在安装OpenMPI时遇到问题,可以尝试使用以下 Shell 命令解决问题 shell$cd ./ompi/build 配置一 shell$cd ./configure --prefix=/usr/local --...

    Ubuntu16.04安装VMtools

    本文将详细介绍如何在 Ubuntu 16.04 系统中安装 VMware Tools,包括安装前的准备、具体步骤以及可能遇到的问题及其解决方案。 #### 二、准备工作 1. **确保已经安装了 VMware Workstation**:确保您的计算机上已经...

    ubuntu下安装freeswitch步骤及遇到的问题解决办法

    ubuntu下安装freeswitch步骤及遇到的问题解决办法

    ubuntu离线安装vim

    4. 安装过程中可能会出现依赖性问题,如果提示缺少其他包,可以先用`apt-cache search`查找相关包,然后下载并安装。例如,如果缺少`libncurses`,你可以下载并安装对应的.deb文件。 5. 安装完成后,你可以通过运行...

    Ubuntu20.04安装Mininet和Ryu.pdf

    本文档介绍了在Ubuntu20.04系统中安装Mininet和Ryu的步骤,并提供了使用Mininet进行网络拓扑生成的实验指导。 Mininet的安装 在Ubuntu20.04系统中,安装Mininet可以使用以下命令: ``` sudo apt-get install ...

    Ubuntu16.04、Ubuntu18.04、或更高Ubuntu版本安装JDK7参考资料

    在Ubuntu 16.04、18.04或更高版本中安装JDK7的步骤对于开发者来说至关重要,特别是那些需要支持Android 5.1和6.0等较旧版本应用编译的用户。Oracle JDK 7的支持已经结束,但OpenJDK 7作为一个开源替代品仍然可以获取...

Global site tag (gtag.js) - Google Analytics