[Home]

Summary:ASTERISK-15626: [patch] DEBUG_THREADS - Compile errors on OS/X Snow Leopard
Reporter:Olle Johansson (oej)Labels:
Date Opened:2010-02-15 13:07:30.000-0600Date Closed:2010-04-01 13:21:32
Priority:MinorRegression?No
Status:Closed/CompleteComponents:Utilities/aelparse
Versions:Frequency of
Occurrence
Related
Issues:
Environment:Attachments:( 0) 20100331__issue16828.diff.txt
Description:Aelparse.c fails to compile on OS/X

I have enabled debug threads and locks

$ gcc --version
i686-apple-darwin10-gcc-4.2.1 (GCC) 4.2.1 (Apple Inc. build 5646) (dot 1)
Copyright (C) 2007 Free Software Foundation, Inc.

$uname -a
Darwin agave.local 10.2.0 Darwin Kernel Version 10.2.0: Tue Nov  3 10:37:10 PST 2009; root:xnu-1486.2.11~1/RELEASE_I386 i386


****** ADDITIONAL INFORMATION ******

 [CC] aelparse.c -> aelparse.o
In file included from /usr/local/src/asterisk.svn/asterisk-1.4/include/asterisk/utils.h:38,
                from ael.flex:85:
/usr/local/src/asterisk.svn/asterisk-1.4/include/asterisk/lock.h: In function '__ast_pthread_mutex_init':
/usr/local/src/asterisk.svn/asterisk-1.4/include/asterisk/lock.h:265: error: invalid operands to binary != (have 'pthread_mutex_t' and 'pthread_mutex_t')
/usr/local/src/asterisk.svn/asterisk-1.4/include/asterisk/lock.h: In function '__ast_pthread_mutex_destroy':
/usr/local/src/asterisk.svn/asterisk-1.4/include/asterisk/lock.h:300: error: invalid operands to binary == (have 'pthread_mutex_t' and 'pthread_mutex_t')
/usr/local/src/asterisk.svn/asterisk-1.4/include/asterisk/lock.h:337: error: expected expression before '{' token
/usr/local/src/asterisk.svn/asterisk-1.4/include/asterisk/lock.h: In function '__ast_pthread_mutex_lock':
/usr/local/src/asterisk.svn/asterisk-1.4/include/asterisk/lock.h:358: error: invalid operands to binary == (have 'pthread_mutex_t' and 'pthread_mutex_t')
/usr/local/src/asterisk.svn/asterisk-1.4/include/asterisk/lock.h:364: error: invalid operands to binary == (have 'pthread_mutex_t' and 'pthread_mutex_t')
/usr/local/src/asterisk.svn/asterisk-1.4/include/asterisk/lock.h: In function '__ast_pthread_mutex_trylock':
/usr/local/src/asterisk.svn/asterisk-1.4/include/asterisk/lock.h:446: error: invalid operands to binary == (have 'pthread_mutex_t' and 'pthread_mutex_t')
/usr/local/src/asterisk.svn/asterisk-1.4/include/asterisk/lock.h:452: error: invalid operands to binary == (have 'pthread_mutex_t' and 'pthread_mutex_t')
/usr/local/src/asterisk.svn/asterisk-1.4/include/asterisk/lock.h: In function '__ast_pthread_mutex_unlock':
/usr/local/src/asterisk.svn/asterisk-1.4/include/asterisk/lock.h:492: error: invalid operands to binary == (have 'pthread_mutex_t' and 'pthread_mutex_t')
/usr/local/src/asterisk.svn/asterisk-1.4/include/asterisk/lock.h:496: error: invalid operands to binary == (have 'pthread_mutex_t' and 'pthread_mutex_t')
/usr/local/src/asterisk.svn/asterisk-1.4/include/asterisk/lock.h: In function '__ast_cond_wait':
/usr/local/src/asterisk.svn/asterisk-1.4/include/asterisk/lock.h:571: error: invalid operands to binary == (have 'pthread_mutex_t' and 'pthread_mutex_t')
/usr/local/src/asterisk.svn/asterisk-1.4/include/asterisk/lock.h:575: error: invalid operands to binary == (have 'pthread_mutex_t' and 'pthread_mutex_t')
/usr/local/src/asterisk.svn/asterisk-1.4/include/asterisk/lock.h: In function '__ast_cond_timedwait':
/usr/local/src/asterisk.svn/asterisk-1.4/include/asterisk/lock.h:642: error: invalid operands to binary == (have 'pthread_mutex_t' and 'pthread_mutex_t')
/usr/local/src/asterisk.svn/asterisk-1.4/include/asterisk/lock.h:646: error: invalid operands to binary == (have 'pthread_mutex_t' and 'pthread_mutex_t')
/usr/local/src/asterisk.svn/asterisk-1.4/include/asterisk/lock.h: In function '__ast_rwlock_init':
/usr/local/src/asterisk.svn/asterisk-1.4/include/asterisk/lock.h:868: error: invalid operands to binary != (have 'ast_rwlock_t' and 'ast_rwlock_t')
/usr/local/src/asterisk.svn/asterisk-1.4/include/asterisk/lock.h: In function '__ast_rwlock_destroy':
/usr/local/src/asterisk.svn/asterisk-1.4/include/asterisk/lock.h:893: error: invalid operands to binary == (have 'ast_rwlock_t' and 'ast_rwlock_t')
/usr/local/src/asterisk.svn/asterisk-1.4/include/asterisk/lock.h: In function '_ast_rwlock_unlock':
/usr/local/src/asterisk.svn/asterisk-1.4/include/asterisk/lock.h:917: error: invalid operands to binary == (have 'ast_rwlock_t' and 'ast_rwlock_t')
/usr/local/src/asterisk.svn/asterisk-1.4/include/asterisk/lock.h:921: error: invalid operands to binary == (have 'ast_rwlock_t' and 'ast_rwlock_t')
/usr/local/src/asterisk.svn/asterisk-1.4/include/asterisk/lock.h: In function '_ast_rwlock_rdlock':
/usr/local/src/asterisk.svn/asterisk-1.4/include/asterisk/lock.h:944: error: invalid operands to binary == (have 'ast_rwlock_t' and 'ast_rwlock_t')
/usr/local/src/asterisk.svn/asterisk-1.4/include/asterisk/lock.h:950: error: invalid operands to binary == (have 'ast_rwlock_t' and 'ast_rwlock_t')
/usr/local/src/asterisk.svn/asterisk-1.4/include/asterisk/lock.h: In function '_ast_rwlock_wrlock':
/usr/local/src/asterisk.svn/asterisk-1.4/include/asterisk/lock.h:977: error: invalid operands to binary == (have 'ast_rwlock_t' and 'ast_rwlock_t')
/usr/local/src/asterisk.svn/asterisk-1.4/include/asterisk/lock.h:983: error: invalid operands to binary == (have 'ast_rwlock_t' and 'ast_rwlock_t')
/usr/local/src/asterisk.svn/asterisk-1.4/include/asterisk/lock.h: In function '_ast_rwlock_timedrdlock':
/usr/local/src/asterisk.svn/asterisk-1.4/include/asterisk/lock.h:1010: error: invalid operands to binary == (have 'ast_rwlock_t' and 'ast_rwlock_t')
/usr/local/src/asterisk.svn/asterisk-1.4/include/asterisk/lock.h:1016: error: invalid operands to binary == (have 'ast_rwlock_t' and 'ast_rwlock_t')
/usr/local/src/asterisk.svn/asterisk-1.4/include/asterisk/lock.h: In function '_ast_rwlock_timedwrlock':
/usr/local/src/asterisk.svn/asterisk-1.4/include/asterisk/lock.h:1059: error: invalid operands to binary == (have 'ast_rwlock_t' and 'ast_rwlock_t')
/usr/local/src/asterisk.svn/asterisk-1.4/include/asterisk/lock.h:1065: error: invalid operands to binary == (have 'ast_rwlock_t' and 'ast_rwlock_t')
/usr/local/src/asterisk.svn/asterisk-1.4/include/asterisk/lock.h: In function '_ast_rwlock_tryrdlock':
/usr/local/src/asterisk.svn/asterisk-1.4/include/asterisk/lock.h:1108: error: invalid operands to binary == (have 'ast_rwlock_t' and 'ast_rwlock_t')
/usr/local/src/asterisk.svn/asterisk-1.4/include/asterisk/lock.h:1114: error: invalid operands to binary == (have 'ast_rwlock_t' and 'ast_rwlock_t')
/usr/local/src/asterisk.svn/asterisk-1.4/include/asterisk/lock.h: In function '_ast_rwlock_trywrlock':
/usr/local/src/asterisk.svn/asterisk-1.4/include/asterisk/lock.h:1141: error: invalid operands to binary == (have 'ast_rwlock_t' and 'ast_rwlock_t')
/usr/local/src/asterisk.svn/asterisk-1.4/include/asterisk/lock.h:1147: error: invalid operands to binary == (have 'ast_rwlock_t' and 'ast_rwlock_t')
make[1]: *** [aelparse.o] Error 1
make: *** [utils] Error 2
Comments:By: Olle Johansson (oej) 2010-02-15 13:08:47.000-0600

After disabling all utils, I realize that this applies to res_adsi.c too. I guess something is wrong with debug_locks on OS/X.

By: Olle Johansson (oej) 2010-02-15 13:39:18.000-0600

Wonder if this is about DEBUG_THREADS. The previous was on CEntos 5.4.

MENUSELECT_CFLAGS=DONT_OPTIMIZE DEBUG_THREADS LOADABLE_MODULES

By: Olle Johansson (oej) 2010-02-15 13:52:09.000-0600

Removed the centos note, my mistake. Back to OS/X

By: Tilghman Lesher (tilghman) 2010-03-04 10:28:44.000-0600

Is there a reason why you think we ought to support a version of OS X that is this old?  I think supporting Tiger (10.4) ought to be our minimal version.

By: Olle Johansson (oej) 2010-03-04 10:49:52.000-0600

I'm running snow leopard on this machine. Apple -> About says Mac Os/X version 10.6.2, but uname -a says other things.

By: Jason Parker (jparker) 2010-03-04 12:40:14.000-0600

This code is being reworked a bit, and this may not be an issue anymore with https://origsvn.digium.com/svn/asterisk/team/qwell/compiler-flag-abi

By: Tilghman Lesher (tilghman) 2010-03-31 17:58:14

Patch uploaded that should fix this issue.

By: Digium Subversion (svnbot) 2010-04-01 13:16:38

Repository: asterisk
Revision: 255796

U   trunk/include/asterisk/lock.h

------------------------------------------------------------------------
r255796 | tilghman | 2010-04-01 13:16:37 -0500 (Thu, 01 Apr 2010) | 7 lines

Fix DEBUG_THREADS build on Darwin.

(closes issue ASTERISK-15626)
Reported by: oej
Patches:
      20100331__issue16828.diff.txt uploaded by tilghman (license 14)

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

http://svn.digium.com/view/asterisk?view=rev&revision=255796

By: Digium Subversion (svnbot) 2010-04-01 13:21:15

Repository: asterisk
Revision: 255813

_U  branches/1.6.0/
U   branches/1.6.0/include/asterisk/lock.h

------------------------------------------------------------------------
r255813 | tilghman | 2010-04-01 13:21:15 -0500 (Thu, 01 Apr 2010) | 14 lines

Merged revisions 255796 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk

........
 r255796 | tilghman | 2010-04-01 13:16:37 -0500 (Thu, 01 Apr 2010) | 7 lines
 
 Fix DEBUG_THREADS build on Darwin.
 
 (closes issue ASTERISK-15626)
  Reported by: oej
  Patches:
        20100331__issue16828.diff.txt uploaded by tilghman (license 14)
........

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

http://svn.digium.com/view/asterisk?view=rev&revision=255813

By: Digium Subversion (svnbot) 2010-04-01 13:21:24

Repository: asterisk
Revision: 255815

_U  branches/1.6.1/
U   branches/1.6.1/include/asterisk/lock.h

------------------------------------------------------------------------
r255815 | tilghman | 2010-04-01 13:21:24 -0500 (Thu, 01 Apr 2010) | 14 lines

Merged revisions 255796 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk

........
 r255796 | tilghman | 2010-04-01 13:16:37 -0500 (Thu, 01 Apr 2010) | 7 lines
 
 Fix DEBUG_THREADS build on Darwin.
 
 (closes issue ASTERISK-15626)
  Reported by: oej
  Patches:
        20100331__issue16828.diff.txt uploaded by tilghman (license 14)
........

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

http://svn.digium.com/view/asterisk?view=rev&revision=255815

By: Digium Subversion (svnbot) 2010-04-01 13:21:32

Repository: asterisk
Revision: 255816

_U  branches/1.6.2/
U   branches/1.6.2/include/asterisk/lock.h

------------------------------------------------------------------------
r255816 | tilghman | 2010-04-01 13:21:31 -0500 (Thu, 01 Apr 2010) | 14 lines

Merged revisions 255796 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk

........
 r255796 | tilghman | 2010-04-01 13:16:37 -0500 (Thu, 01 Apr 2010) | 7 lines
 
 Fix DEBUG_THREADS build on Darwin.
 
 (closes issue ASTERISK-15626)
  Reported by: oej
  Patches:
        20100331__issue16828.diff.txt uploaded by tilghman (license 14)
........

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

http://svn.digium.com/view/asterisk?view=rev&revision=255816