1

安装opensips时遇到错误。

请帮我解决这个问题。我已经安装了 Redis 和 freeradius。

make[1]: Entering directory `/usr/local/src/opensips-1.9.0-tls/modules/aaa_radius'
make[1]: Leaving directory `/usr/local/src/opensips-1.9.0-tls/modules/aaa_radius'
make[1]: Entering directory `/usr/local/src/opensips-1.9.0-tls/modules/aaa_radius'
Compiling aaa_radius.c
Compiling rad.c
Linking aaa_radius.so
make[1]: Leaving directory `/usr/local/src/opensips-1.9.0-tls/modules/aaa_radius'


make[1]: Entering directory `/usr/local/src/opensips-1.9.0-tls/modules/cachedb_redis'
make[1]: Leaving directory `/usr/local/src/opensips-1.9.0-tls/modules/cachedb_redis'
make[1]: Entering directory `/usr/local/src/opensips-1.9.0-tls/modules/cachedb_redis'
Compiling cachedb_redis.c
In file included from cachedb_redis.c:41:
cachedb_redis_dbase.h:29:29: error: hiredis/hiredis.h: No such file or directory
In file included from cachedb_redis.c:41:
cachedb_redis_dbase.h:38: error: expected specifier-qualifier-list before ‘redisContext’
make[1]: *** [cachedb_redis.o] Error 1
make[1]: Leaving directory `/usr/local/src/opensips-1.9.0-tls/modules/cachedb_redis'
make: *** [modules] Error 2
4

2 回答 2

1

我 100% 确信可以在epel存储库 ( /etc/yum.repos.d/epel.repo) 中找到 redis 开发包:

yum install hiredis-devel.x86_64

现在,如果您真的想安装仅限 Red Hat 的软件包,您应该尝试启用尽可能多的存储库,/etc/yum.repos.d/redhat.repo直到您希望找到一个好的存储库!

于 2015-10-02T08:57:02.423 回答
0

该问题已通过安装hiredis-devel.x86_64 得到解决。

但现在我遇到了这个错误。

make[1]: Entering directory `/usr/local/src/opensips-1.9.0-tls/modules/json'
Compiling array_del.c
array_del.c:29:23: error: json/json.h: No such file or directory
array_del.c:30:38: error: json/json_object_private.h: No such file or directory
array_del.c:32: warning: ‘struct array_list’ declared inside parameter list
array_del.c:32: warning: its scope is only this definition or declaration, which is probably not what you want
array_del.c: In function ‘array_list_del_idx’:
array_del.c:36: error: dereferencing pointer to incomplete type
array_del.c:40: error: dereferencing pointer to incomplete type
array_del.c:40: error: dereferencing pointer to incomplete type
array_del.c:41: error: dereferencing pointer to incomplete type
array_del.c:43: error: dereferencing pointer to incomplete type
array_del.c:44: error: dereferencing pointer to incomplete type
array_del.c:44: error: dereferencing pointer to incomplete type
array_del.c: At top level:
array_del.c:47: warning: ‘struct json_object’ declared inside parameter list
array_del.c: In function ‘json_object_array_del’:
array_del.c:49: error: dereferencing pointer to incomplete type
make[1]: *** [array_del.o] Error 1
make[1]: Leaving directory `/usr/local/src/opensips-1.9.0-tls/modules/json'
make: *** [modules] Error 2
于 2015-10-02T11:13:24.923 回答