Re: [HACKERS] Open portability issues

Bruce Momjian <maillist@candle.pha.pa.us>

From: Bruce Momjian <maillist@candle.pha.pa.us>
To: dz@cs.unitn.it (Massimo Dal Zotto)
Cc: hackers@postgreSQL.org, pgsql-patches@postgreSQL.org, andreas.zeugswetter@telecom.at
Date: 1998-09-09T18:32:19Z
Lists: pgsql-hackers
Patch applied.


[Charset iso-8859-1 unsupported, filtering to ASCII...]
> > 
> > 
> > Open portability issues:
> > 
> > /usr/local should be searched for lib and include for all ports if present 
> > (currently not working, I have libreadline there)
> > 
> > the stream functions on AIX need a size_t for addrlen's in fe-connect.c and pqcomm.c.
> > 
> > lock.c still has an incompatible TPRINTF(flags, args...) definition
> 
> Please apply this patch:
> 
> *** src/backend/storage/lmgr/lock.c.orig	Wed Aug 26 09:00:55 1998
> --- src/backend/storage/lmgr/lock.c	Mon Sep  7 14:44:53 1998
> *************** static int WaitOnLock(LOCKMETHOD lockmet
> *** 136,153 ****
>   		 xidentP->holders[5], \
>   		 xidentP->nHolding)
>   
> - #define LOCK_TPRINTF(lock, args...) \
> -     if (((LOCKDEBUG(LOCK_LOCKMETHOD(*(lock))) >= 1) \
> - 	     && (lock->tag.relId >= lockDebugOidMin)) \
> - 	    || (lock->tag.relId == lockDebugRelation)) \
> - 	    TPRINTF(TRACE_ALL, args)
> - 
>   #else	/* !LOCK_MGR_DEBUG */
>   #define LOCK_PRINT(where,lock,type)
>   #define LOCK_PRINT_AUX(where,lock,type)
>   #define XID_PRINT(where,xidentP)
>   #define XID_PRINT_AUX(where,xidentP)
> - #define LOCK_TPRINTF(lock, args...)
>   #endif	/* !LOCK_MGR_DEBUG */
>   
>   static char *lock_types[] = {
> --- 136,146 ----
> *************** LockRelease(LOCKMETHOD lockmethod, LOCKT
> *** 1200,1206 ****
>   	}
>   	else
>   	{
> ! 		LOCK_TPRINTF(lock, "LockRelease: no wakeup needed");
>   	}
>   
>   	SpinRelease(masterLock);
> --- 1193,1202 ----
>   	}
>   	else
>   	{
> ! 		if (((LOCKDEBUG(LOCK_LOCKMETHOD(*(lock))) >= 1) \
> ! 			 && (lock->tag.relId >= lockDebugOidMin)) \
> ! 			|| (lock->tag.relId == lockDebugRelation))
> ! 			TPRINTF(TRACE_ALL, "LockRelease: no wakeup needed");
>   	}
>   
>   	SpinRelease(masterLock);
> 
> 
> -- 
> Massimo Dal Zotto
> 
> +----------------------------------------------------------------------+
> |  Massimo Dal Zotto                email:  dz@cs.unitn.it             |
> |  Via Marconi, 141                 phone:  ++39-461-534251            |
> |  38057 Pergine Valsugana (TN)     www:  http://www.cs.unitn.it/~dz/  |
> |  Italy                            pgp:  finger dz@tango.cs.unitn.it  |
> +----------------------------------------------------------------------+
> 
> 


-- 
Bruce Momjian                          |  830 Blythe Avenue
maillist@candle.pha.pa.us              |  Drexel Hill, Pennsylvania 19026
  +  If your life is a hard drive,     |  (610) 353-9879(w)
  +  Christ can be your backup.        |  (610) 853-3000(h)