linux pjsip 编译_在Linux中构建pjsip时出错

I am getting following error while building pjsip as mentioned in this link.

When I run the make command:

In file included from /usr/lib/gcc/x86_64-linux-gnu/5/include/errno.h:28:0,

from ../include/pj/compat/socket.h:131,

from ../src/pj/ioqueue_select.c:38:

../src/pj/ioqueue_common_abs.c: In function ‘pj_ioqueue_recv’:

../include/pj/compat/os_auto.h:149:31: error: ‘EAGAIN’ undeclared (first use in this function)

#define PJ_BLOCKING_ERROR_VAL EAGAIN

^

Edit:

OS Name: Ubuntu 16.04 LTS && 64 bit

Build Command:

cd pjproject-2.7.2/

chmod 777 configure

chmod 777 aconfigure

./configure

make dep

make

And downloaded the source code from this link

解决方案

Ubuntu 16.04 - amd64

git clone https://github.com/svn2github/pjsip.git ... or pjproject-2.7.2.tar.bz2 : Both will build OK here, with gcc version 4.8 → sudo apt install g++-4.8

export CC=gcc-4.8 CXX=g++-4.8 && ./configure --enable-shared --disable-static --enable-memalign-hack

make dep && make

Interesting is that pjsip can be built with gcc, g++ v. 7.3 on an rpm based OS. But then again, the Ubuntu gcc´s have a very different patching.

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值