[Asterisk-Users] Rate Engine Compile Error

Kevin Walsh kevin at cursor.biz
Wed Jul 28 07:38:52 MST 2004


Deon Rodden [drodden at webunited.net] wrote:
> I've tried to compile rate-engine 0.5.2 on Fedora Core 1, Redhat 9 and
> OpenNA Linux 1.0 and all give me an "Error 1" after typing "make" but with
> no real reason given. Just a few standard/non-critical warning messages,
> and then suddenly "Error 1" 
> 
> rate_engine.c:60: error:
> `__use_AST_MUTEX_DEFINE_STATIC_rather_than_AST_MUTEX_INITIALIZER__'
> undeclared here (not in a function)
>
The above doesn't look like a standard/non-critical warning to me.

Perhaps there's an update for the source you have.  I don't have that
code myself, so I don't know.  You could try contacting the author.

If you have no joy there then search the code for lines like the
following:

    static ast_mutex_t foo = AST_MUTEX_INITIALIZER;

and change to:

    AST_MUTEX_DEFINE_STATIC(foo);

I.e. do as the error message suggests and use AST_MUTEX_DEFINE_STATIC
rather than AST_MUTEX_INITIALIZER.  You should also correct those other
"standard/non-critical warnings" while you're in there.  If the code
is GPLed then please submit your changes back to the author for
inclusion in the next release.

-- 
   _/   _/  _/_/_/_/  _/    _/  _/_/_/  _/    _/
  _/_/_/   _/_/      _/    _/    _/    _/_/  _/   K e v i n   W a l s h
 _/ _/    _/          _/ _/     _/    _/  _/_/    kevin at cursor.biz
_/   _/  _/_/_/_/      _/    _/_/_/  _/    _/




More information about the asterisk-users mailing list