[Home]

Summary:ASTERISK-10669: Solaris build issues
Reporter:snuffy (snuffy)Labels:
Date Opened:2007-11-01 23:13:37Date Closed:2007-11-06 12:34:04.000-0600
Priority:MinorRegression?No
Status:Closed/CompleteComponents:Core/General
Versions:Frequency of
Occurrence
Related
Issues:
Environment:Attachments:( 0) lock.h.diff
Description:I tried to build svn trunk and found solaris compile broken

This appears to be from bug ASTERISK-10647 or rev 87739


[CC] aelparse.c -> aelparse.o
In file included from /export/home/bradl/sources/asterisk/include/asterisk/utils.h:38,
                from ael.flex:71:
/export/home/bradl/sources/asterisk/include/asterisk/lock.h: In function `ast_mutex_init':
/export/home/bradl/sources/asterisk/include/asterisk/lock.h:680: error: syntax error before '{' token
/export/home/bradl/sources/asterisk/include/asterisk/lock.h:675: warning: unused variable `res'
/export/home/bradl/sources/asterisk/include/asterisk/lock.h:676: warning: unused variable `attr'
/export/home/bradl/sources/asterisk/include/asterisk/lock.h:680: warning: no return statement in function returning non-void
/export/home/bradl/sources/asterisk/include/asterisk/lock.h: At top level:
/export/home/bradl/sources/asterisk/include/asterisk/lock.h:683: error: syntax error before '&' token
/export/home/bradl/sources/asterisk/include/asterisk/lock.h:683: warning: type defaults to `int' in declaration of `pthread_mutexattr_init'
/export/home/bradl/sources/asterisk/include/asterisk/lock.h:683: warning: function declaration isn't a prototype
/export/home/bradl/sources/asterisk/include/asterisk/lock.h:683: warning: data definition has no type or storage class
/export/home/bradl/sources/asterisk/include/asterisk/lock.h:684: error: syntax error before '&' token
/export/home/bradl/sources/asterisk/include/asterisk/lock.h:684: warning: type defaults to `int' in declaration of `pthread_mutexattr_settype'
/export/home/bradl/sources/asterisk/include/asterisk/lock.h:684: warning: function declaration isn't a prototype
/export/home/bradl/sources/asterisk/include/asterisk/lock.h:684: warning: data definition has no type or storage class
/export/home/bradl/sources/asterisk/include/asterisk/lock.h:686: warning: type defaults to `int' in declaration of `res'
/export/home/bradl/sources/asterisk/include/asterisk/lock.h:686: error: `pmutex' undeclared here (not in a function)
/export/home/bradl/sources/asterisk/include/asterisk/lock.h:686: error: `attr' undeclared here (not in a function)
/export/home/bradl/sources/asterisk/include/asterisk/lock.h:686: error: initializer element is not constant
/export/home/bradl/sources/asterisk/include/asterisk/lock.h:686: warning: data definition has no type or storage class
/export/home/bradl/sources/asterisk/include/asterisk/lock.h:687: error: syntax error before '&' token
/export/home/bradl/sources/asterisk/include/asterisk/lock.h:687: warning: type defaults to `int' in declaration of `pthread_mutexattr_destroy'
/export/home/bradl/sources/asterisk/include/asterisk/lock.h:687: warning: function declaration isn't a prototype
/export/home/bradl/sources/asterisk/include/asterisk/lock.h:687: warning: data definition has no type or storage class
/export/home/bradl/sources/asterisk/include/asterisk/lock.h: In function `ast_mutex_unlock':
/export/home/bradl/sources/asterisk/include/asterisk/lock.h:697: error: syntax error before '{' token
/export/home/bradl/sources/asterisk/include/asterisk/lock.h:697: warning: no return statement in function returning non-void
/export/home/bradl/sources/asterisk/include/asterisk/lock.h: In function `ast_mutex_destroy':
/export/home/bradl/sources/asterisk/include/asterisk/lock.h:708: error: syntax error before '{' token
/export/home/bradl/sources/asterisk/include/asterisk/lock.h:708: warning: no return statement in function returning non-void
/export/home/bradl/sources/asterisk/include/asterisk/lock.h: In function `ast_mutex_lock':
/export/home/bradl/sources/asterisk/include/asterisk/lock.h:718: error: syntax error before '{' token
/export/home/bradl/sources/asterisk/include/asterisk/lock.h:718: warning: no return statement in function returning non-void
/export/home/bradl/sources/asterisk/include/asterisk/lock.h: At top level:
/export/home/bradl/sources/asterisk/include/asterisk/lock.h:721: error: syntax error before numeric constant
/export/home/bradl/sources/asterisk/include/asterisk/lock.h:721: warning: type defaults to `int' in declaration of `ast_mark'
/export/home/bradl/sources/asterisk/include/asterisk/lock.h:721: warning: function declaration isn't a prototype
/export/home/bradl/sources/asterisk/include/asterisk/lock.h:721: error: conflicting types for 'ast_mark'
/export/home/bradl/sources/asterisk/include/asterisk.h:221: error: previous declaration of 'ast_mark' was here
/export/home/bradl/sources/asterisk/include/asterisk/lock.h:721: error: conflicting types for 'ast_mark'
/export/home/bradl/sources/asterisk/include/asterisk.h:221: error: previous declaration of 'ast_mark' was here
/export/home/bradl/sources/asterisk/include/asterisk/lock.h:721: warning: data definition has no type or storage class
/export/home/bradl/sources/asterisk/include/asterisk/lock.h:721: warning: type defaults to `int' in declaration of `i'
/export/home/bradl/sources/asterisk/include/asterisk/lock.h:721: error: initializer element is not constant
/export/home/bradl/sources/asterisk/include/asterisk/lock.h:721: warning: data definition has no type or storage class
/export/home/bradl/sources/asterisk/include/asterisk/lock.h:721: error: syntax error before numeric constant
/export/home/bradl/sources/asterisk/include/asterisk/lock.h:721: warning: type defaults to `int' in declaration of `ast_mark'
/export/home/bradl/sources/asterisk/include/asterisk/lock.h:721: warning: function declaration isn't a prototype
/export/home/bradl/sources/asterisk/include/asterisk/lock.h:721: warning: data definition has no type or storage class
/export/home/bradl/sources/asterisk/include/asterisk/lock.h: In function `ast_mutex_trylock':
/export/home/bradl/sources/asterisk/include/asterisk/lock.h:728: error: syntax error before '{' token
/export/home/bradl/sources/asterisk/include/asterisk/lock.h:728: warning: no return statement in function returning non-void
/export/home/bradl/sources/asterisk/include/asterisk/lock.h: In function `ast_rwlock_init':
/export/home/bradl/sources/asterisk/include/asterisk/lock.h:1042: error: invalid operands to binary !=
/export/home/bradl/sources/asterisk/include/asterisk/lock.h: In function `ast_rwlock_destroy':
/export/home/bradl/sources/asterisk/include/asterisk/lock.h:1060: error: invalid operands to binary ==
/export/home/bradl/sources/asterisk/include/asterisk/lock.h: In function `ast_rwlock_unlock':
/export/home/bradl/sources/asterisk/include/asterisk/lock.h:1070: error: invalid operands to binary ==
/export/home/bradl/sources/asterisk/include/asterisk/lock.h: In function `ast_rwlock_rdlock':
/export/home/bradl/sources/asterisk/include/asterisk/lock.h:1082: error: invalid operands to binary ==
/export/home/bradl/sources/asterisk/include/asterisk/lock.h: In function `ast_rwlock_tryrdlock':
/export/home/bradl/sources/asterisk/include/asterisk/lock.h:1093: error: invalid operands to binary ==
/export/home/bradl/sources/asterisk/include/asterisk/lock.h: In function `ast_rwlock_wrlock':
/export/home/bradl/sources/asterisk/include/asterisk/lock.h:1104: error: invalid operands to binary ==
/export/home/bradl/sources/asterisk/include/asterisk/lock.h: In function `ast_rwlock_trywrlock':
/export/home/bradl/sources/asterisk/include/asterisk/lock.h:1115: error: invalid operands to binary ==
gmake[1]: *** [aelparse.o] Error 1
gmake: *** [utils] Error 2
(15:07)[bradl@sol-box:asterisk]$
Comments:By: snuffy (snuffy) 2007-11-01 23:18:54

I have no debug options selected

By: Yuri (ys) 2007-11-02 06:25:11

What Solaris version are You use?
How PTHREAD_MUTEX_INITIALIZER and pthread_mutex_t defined in pthread.h?

By: Yuri (ys) 2007-11-02 07:03:17

I upload patch, where remove mutex checking for Solaris.

By: Digium Subversion (svnbot) 2007-11-02 08:01:16

Repository: asterisk
Revision: 88210

U   branches/1.4/include/asterisk/lock.h

------------------------------------------------------------------------
r88210 | tilghman | 2007-11-02 08:01:15 -0500 (Fri, 02 Nov 2007) | 5 lines

Fix build on Solaris
Reported by: snuffy
Patch by: ys
Closes issue ASTERISK-10669

------------------------------------------------------------------------

By: Digium Subversion (svnbot) 2007-11-02 08:08:42

Repository: asterisk
Revision: 88211

_U  trunk/
U   trunk/include/asterisk/lock.h

------------------------------------------------------------------------
r88211 | tilghman | 2007-11-02 08:08:41 -0500 (Fri, 02 Nov 2007) | 13 lines

Merged revisions 88210 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r88210 | tilghman | 2007-11-02 08:03:03 -0500 (Fri, 02 Nov 2007) | 5 lines

Fix build on Solaris
Reported by: snuffy
Patch by: ys
Closes issue ASTERISK-10669

........

------------------------------------------------------------------------

By: Digium Subversion (svnbot) 2007-11-02 10:22:35

Repository: asterisk
Revision: 88246

_U  team/group/CDRfix5/
U   team/group/CDRfix5/UPGRADE.txt
U   team/group/CDRfix5/apps/app_dial.c
U   team/group/CDRfix5/apps/app_exec.c
U   team/group/CDRfix5/apps/app_macro.c
U   team/group/CDRfix5/apps/app_minivm.c
U   team/group/CDRfix5/apps/app_mixmonitor.c
U   team/group/CDRfix5/apps/app_playback.c
U   team/group/CDRfix5/apps/app_queue.c
U   team/group/CDRfix5/apps/app_rpt.c
U   team/group/CDRfix5/cdr/cdr_custom.c
U   team/group/CDRfix5/cdr/cdr_manager.c
U   team/group/CDRfix5/cdr/cdr_odbc.c
U   team/group/CDRfix5/cdr/cdr_sqlite3_custom.c
U   team/group/CDRfix5/channels/chan_gtalk.c
U   team/group/CDRfix5/channels/chan_jingle.c
U   team/group/CDRfix5/configure
U   team/group/CDRfix5/configure.ac
U   team/group/CDRfix5/funcs/func_cut.c
U   team/group/CDRfix5/funcs/func_logic.c
U   team/group/CDRfix5/funcs/func_odbc.c
U   team/group/CDRfix5/funcs/func_strings.c
U   team/group/CDRfix5/include/asterisk/autoconfig.h.in
U   team/group/CDRfix5/include/asterisk/jabber.h
U   team/group/CDRfix5/include/asterisk/lock.h
U   team/group/CDRfix5/include/asterisk/pbx.h
U   team/group/CDRfix5/main/config.c
U   team/group/CDRfix5/main/logger.c
U   team/group/CDRfix5/main/pbx.c
U   team/group/CDRfix5/makeopts.in
U   team/group/CDRfix5/pbx/pbx_config.c
U   team/group/CDRfix5/pbx/pbx_dundi.c
U   team/group/CDRfix5/pbx/pbx_loopback.c
U   team/group/CDRfix5/pbx/pbx_realtime.c
U   team/group/CDRfix5/res/ael/pval.c
U   team/group/CDRfix5/res/res_agi.c
U   team/group/CDRfix5/res/res_jabber.c
U   team/group/CDRfix5/utils/extconf.c

------------------------------------------------------------------------
r88246 | murf | 2007-11-02 10:22:34 -0500 (Fri, 02 Nov 2007) | 73 lines

Merged revisions 88164-88166,88182-88184,88197,88209,88211-88212 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk

................
r88164 | qwell | 2007-11-01 16:10:33 -0600 (Thu, 01 Nov 2007) | 4 lines

Switch res_jabber to use openssl rather than gnutls.

Closes issue ASTERISK-9675, patch by phsultan.  Copied from branch at http://svn.digium.com/svn/asterisk/team/phsultan/res_jabber-openssl/

................
r88165 | qwell | 2007-11-01 16:19:56 -0600 (Thu, 01 Nov 2007) | 1 line

Crap, accidentally copied the props.  Thanks for pointing this out mvanbaak.  The odds are quite high that this will break automerge on every team branch.
................
r88166 | murf | 2007-11-01 16:26:51 -0600 (Thu, 01 Nov 2007) | 1 line

This commits the performance mods that give the priority processing engine in the pbx, a 25-30peed boost. The two updates used, are, first, to merge the ast_exists_extension() and the ast_spawn_extension() where they are called sequentially in a loop in the code, into a slightly upgraded version of ast_spawn_extension(), with a few extra args; and, second, I modified the substitute_variables_helper_full, so it zeroes out the byte after the evaluated string instead of demanding you pre-zero the buffer; I also went thru the code and removed the code that zeroed this buffer before every call to the substitute_variables_helper_full. The first fix provides about a 9peedup, and the second the rest. These figures come from the 'PIPS' benchmark I describe in blogs, conf. reports, etc.
................
r88182 | tilghman | 2007-11-01 16:43:46 -0600 (Thu, 01 Nov 2007) | 3 lines

Convert cdr_odbc to use res_odbc managed connections
Closes issue ASTERISK-10209

................
r88183 | tilghman | 2007-11-01 17:26:35 -0600 (Thu, 01 Nov 2007) | 3 lines

Modify WaitExten to include an optional dialtone
Closes issue ASTERISK-10356

................
r88184 | qwell | 2007-11-01 17:26:51 -0600 (Thu, 01 Nov 2007) | 1 line

Remove traces of gnutls, since we no longer use/need it.
................
r88197 | file | 2007-11-01 21:09:02 -0600 (Thu, 01 Nov 2007) | 2 lines

Restore building under 64-bit platforms.

................
r88209 | tilghman | 2007-11-02 06:54:31 -0600 (Fri, 02 Nov 2007) | 5 lines

'h' extension doesn't execute past first priority
Reported by: dimas
Patch by: dimas
Closes bug ASTERISK-10672

................
r88211 | tilghman | 2007-11-02 07:10:29 -0600 (Fri, 02 Nov 2007) | 13 lines

Merged revisions 88210 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r88210 | tilghman | 2007-11-02 08:03:03 -0500 (Fri, 02 Nov 2007) | 5 lines

Fix build on Solaris
Reported by: snuffy
Patch by: ys
Closes issue ASTERISK-10669

........

................
r88212 | tilghman | 2007-11-02 07:17:48 -0600 (Fri, 02 Nov 2007) | 5 lines

Don't re-cache the filename, but check to see if it already exists
Reported by: jamesgolovich
Patch by: jamesgolovich
Closes issue ASTERISK-10670

................

------------------------------------------------------------------------

By: Olle Johansson (oej) 2007-11-05 10:34:17.000-0600

This patch breaks compilation on OS/X

By: Olle Johansson (oej) 2007-11-05 10:34:39.000-0600

[CC] aelparse.c -> aelparse.o
In file included from /usr/local/src/asterisk.svn/sip_session_timers/include/asterisk/utils.h:38,
                from ael.flex:71:
/usr/local/src/asterisk.svn/sip_session_timers/include/asterisk/lock.h: In function 'ast_mutex_init':
/usr/local/src/asterisk.svn/sip_session_timers/include/asterisk/lock.h:680: error: invalid operands to binary !=
/usr/local/src/asterisk.svn/sip_session_timers/include/asterisk/lock.h: In function 'ast_mutex_unlock':
/usr/local/src/asterisk.svn/sip_session_timers/include/asterisk/lock.h:697: error: invalid operands to binary ==
/usr/local/src/asterisk.svn/sip_session_timers/include/asterisk/lock.h: In function 'ast_mutex_destroy':
/usr/local/src/asterisk.svn/sip_session_timers/include/asterisk/lock.h:708: error: invalid operands to binary ==
/usr/local/src/asterisk.svn/sip_session_timers/include/asterisk/lock.h: In function 'ast_mutex_lock':
/usr/local/src/asterisk.svn/sip_session_timers/include/asterisk/lock.h:718: error: invalid operands to binary ==
/usr/local/src/asterisk.svn/sip_session_timers/include/asterisk/lock.h: In function 'ast_mutex_trylock':
/usr/local/src/asterisk.svn/sip_session_timers/include/asterisk/lock.h:728: error: invalid operands to binary ==
/usr/local/src/asterisk.svn/sip_session_timers/include/asterisk/lock.h: In function 'ast_rwlock_init':
/usr/local/src/asterisk.svn/sip_session_timers/include/asterisk/lock.h:1042: error: invalid operands to binary !=
/usr/local/src/asterisk.svn/sip_session_timers/include/asterisk/lock.h: In function 'ast_rwlock_destroy':
/usr/local/src/asterisk.svn/sip_session_timers/include/asterisk/lock.h:1060: error: invalid operands to binary ==
/usr/local/src/asterisk.svn/sip_session_timers/include/asterisk/lock.h: In function 'ast_rwlock_unlock':
/usr/local/src/asterisk.svn/sip_session_timers/include/asterisk/lock.h:1070: error: invalid operands to binary ==
/usr/local/src/asterisk.svn/sip_session_timers/include/asterisk/lock.h: In function 'ast_rwlock_rdlock':
/usr/local/src/asterisk.svn/sip_session_timers/include/asterisk/lock.h:1082: error: invalid operands to binary ==
/usr/local/src/asterisk.svn/sip_session_timers/include/asterisk/lock.h: In function 'ast_rwlock_tryrdlock':
/usr/local/src/asterisk.svn/sip_session_timers/include/asterisk/lock.h:1093: error: invalid operands to binary ==
/usr/local/src/asterisk.svn/sip_session_timers/include/asterisk/lock.h: In function 'ast_rwlock_wrlock':
/usr/local/src/asterisk.svn/sip_session_timers/include/asterisk/lock.h:1104: error: invalid operands to binary ==
/usr/local/src/asterisk.svn/sip_session_timers/include/asterisk/lock.h: In function 'ast_rwlock_trywrlock':
/usr/local/src/asterisk.svn/sip_session_timers/include/asterisk/lock.h:1115: error: invalid operands to binary ==
make[1]: *** [aelparse.o] Error 1
make: *** [utils] Error 2

By: Yuri (ys) 2007-11-06 08:12:15.000-0600

Can You compile asterisk with DEBUG_THREADS option?
In Solaris and OS/X.

And print compilation error here.

By: Jason Parker (jparker) 2007-11-06 12:18:21.000-0600

Should we close this, since 11116 has been reverted and reopened?

By: Yuri (ys) 2007-11-06 12:33:01.000-0600

I think - "Yes"