mirror of
https://github.com/signalwire/freeswitch.git
synced 2025-04-20 02:04:54 +00:00
working nspr slimmed down build
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@4914 d0543943-73ff-0310-b7d9-9358b9ac24b2
This commit is contained in:
parent
fcd2da0d39
commit
f4820a6b31
@ -46,7 +46,7 @@ include $(MOD_DEPTH)/config/autoconf.mk
|
||||
|
||||
include $(topsrcdir)/config/config.mk
|
||||
|
||||
DIRS = io linking malloc md memory misc threads
|
||||
DIRS = io malloc md memory misc threads
|
||||
|
||||
# For VAC++ 4 geticcdata rule in config/OS2.mk
|
||||
ifeq ($(MOZ_OS2_TOOLS),VACPP)
|
||||
@ -62,7 +62,7 @@ ifeq ($(USE_BTHREADS), 1)
|
||||
endif
|
||||
|
||||
ifeq ($(USE_CPLUS), 1)
|
||||
DIRS += cplus
|
||||
# DIRS += cplus
|
||||
endif
|
||||
|
||||
#
|
||||
@ -222,45 +222,24 @@ OBJS = \
|
||||
$(OBJDIR)/prvrsion.$(OBJ_SUFFIX) \
|
||||
io/$(OBJDIR)/prfdcach.$(OBJ_SUFFIX) \
|
||||
io/$(OBJDIR)/prmwait.$(OBJ_SUFFIX) \
|
||||
# io/$(OBJDIR)/prmapopt.$(OBJ_SUFFIX) \
|
||||
io/$(OBJDIR)/priometh.$(OBJ_SUFFIX) \
|
||||
# io/$(OBJDIR)/pripv6.$(OBJ_SUFFIX) \
|
||||
io/$(OBJDIR)/prmapopt.$(OBJ_SUFFIX) \
|
||||
io/$(OBJDIR)/prlayer.$(OBJ_SUFFIX) \
|
||||
io/$(OBJDIR)/prlog.$(OBJ_SUFFIX) \
|
||||
io/$(OBJDIR)/prmmap.$(OBJ_SUFFIX) \
|
||||
# io/$(OBJDIR)/prpolevt.$(OBJ_SUFFIX) \
|
||||
io/$(OBJDIR)/pripv6.$(OBJ_SUFFIX) \
|
||||
io/$(OBJDIR)/prprf.$(OBJ_SUFFIX) \
|
||||
# io/$(OBJDIR)/prscanf.$(OBJ_SUFFIX) \
|
||||
# io/$(OBJDIR)/prstdio.$(OBJ_SUFFIX) \
|
||||
# threads/$(OBJDIR)/prcmon.$(OBJ_SUFFIX) \
|
||||
# threads/$(OBJDIR)/prrwlock.$(OBJ_SUFFIX) \
|
||||
threads/$(OBJDIR)/prtpd.$(OBJ_SUFFIX) \
|
||||
# linking/$(OBJDIR)/prlink.$(OBJ_SUFFIX) \
|
||||
malloc/$(OBJDIR)/prmem.$(OBJ_SUFFIX) \
|
||||
md/$(OBJDIR)/prosdep.$(OBJ_SUFFIX) \
|
||||
# memory/$(OBJDIR)/prshm.$(OBJ_SUFFIX) \
|
||||
# memory/$(OBJDIR)/prshma.$(OBJ_SUFFIX) \
|
||||
memory/$(OBJDIR)/prseg.$(OBJ_SUFFIX) \
|
||||
# misc/$(OBJDIR)/pralarm.$(OBJ_SUFFIX) \
|
||||
misc/$(OBJDIR)/prnetdb.$(OBJ_SUFFIX) \
|
||||
misc/$(OBJDIR)/pratom.$(OBJ_SUFFIX) \
|
||||
# misc/$(OBJDIR)/prcountr.$(OBJ_SUFFIX) \
|
||||
# misc/$(OBJDIR)/prdtoa.$(OBJ_SUFFIX) \
|
||||
# misc/$(OBJDIR)/prenv.$(OBJ_SUFFIX) \
|
||||
# misc/$(OBJDIR)/prerr.$(OBJ_SUFFIX) \
|
||||
misc/$(OBJDIR)/prerror.$(OBJ_SUFFIX) \
|
||||
# misc/$(OBJDIR)/prerrortable.$(OBJ_SUFFIX) \
|
||||
misc/$(OBJDIR)/prinit.$(OBJ_SUFFIX) \
|
||||
misc/$(OBJDIR)/pripc.$(OBJ_SUFFIX) \
|
||||
misc/$(OBJDIR)/prinrval.$(OBJ_SUFFIX) \
|
||||
# misc/$(OBJDIR)/pripc.$(OBJ_SUFFIX) \
|
||||
# misc/$(OBJDIR)/prlog2.$(OBJ_SUFFIX) \
|
||||
# misc/$(OBJDIR)/prlong.$(OBJ_SUFFIX) \
|
||||
# misc/$(OBJDIR)/prnetdb.$(OBJ_SUFFIX) \
|
||||
misc/$(OBJDIR)/prolock.$(OBJ_SUFFIX) \
|
||||
# misc/$(OBJDIR)/prrng.$(OBJ_SUFFIX) \
|
||||
# misc/$(OBJDIR)/prsystem.$(OBJ_SUFFIX) \
|
||||
# misc/$(OBJDIR)/prthinfo.$(OBJ_SUFFIX) \
|
||||
# misc/$(OBJDIR)/prtpool.$(OBJ_SUFFIX) \
|
||||
# misc/$(OBJDIR)/prtrace.$(OBJ_SUFFIX) \
|
||||
misc/$(OBJDIR)/prtime.$(OBJ_SUFFIX)
|
||||
|
||||
# ilib now rejects empty objects
|
||||
@ -278,16 +257,12 @@ else
|
||||
OBJS += \
|
||||
io/$(OBJDIR)/prdir.$(OBJ_SUFFIX) \
|
||||
io/$(OBJDIR)/prfile.$(OBJ_SUFFIX) \
|
||||
io/$(OBJDIR)/prio.$(OBJ_SUFFIX) \
|
||||
# io/$(OBJDIR)/prsocket.$(OBJ_SUFFIX) \
|
||||
# misc/$(OBJDIR)/pripcsem.$(OBJ_SUFFIX)
|
||||
io/$(OBJDIR)/prio.$(OBJ_SUFFIX)
|
||||
|
||||
|
||||
ifndef USE_BTHREADS
|
||||
OBJS += \
|
||||
threads/$(OBJDIR)/prcthr.$(OBJ_SUFFIX) \
|
||||
# threads/$(OBJDIR)/prdump.$(OBJ_SUFFIX) \
|
||||
# threads/$(OBJDIR)/prmon.$(OBJ_SUFFIX) \
|
||||
# threads/$(OBJDIR)/prsem.$(OBJ_SUFFIX) \
|
||||
threads/combined/$(OBJDIR)/prucpu.$(OBJ_SUFFIX) \
|
||||
threads/combined/$(OBJDIR)/prucv.$(OBJ_SUFFIX) \
|
||||
threads/combined/$(OBJDIR)/prulock.$(OBJ_SUFFIX) \
|
||||
|
@ -58,14 +58,11 @@ CSRCS = \
|
||||
prmwait.c \
|
||||
priometh.c \
|
||||
pripv6.c \
|
||||
prmapopt.c \
|
||||
prmapopt.c \
|
||||
prlayer.c \
|
||||
prlog.c \
|
||||
prmmap.c \
|
||||
prpolevt.c \
|
||||
prprf.c \
|
||||
prscanf.c \
|
||||
prstdio.c \
|
||||
$(NULL)
|
||||
|
||||
ifndef USE_PTHREADS
|
||||
@ -73,7 +70,6 @@ ifndef USE_PTHREADS
|
||||
prdir.c \
|
||||
prfile.c \
|
||||
prio.c \
|
||||
prsocket.c \
|
||||
$(NULL)
|
||||
endif
|
||||
|
||||
|
@ -279,7 +279,6 @@ static PRInt32 PR_CALLBACK Ipv6ToIpv4SocketRecvFrom(PRFileDesc *fd, void *buf,
|
||||
|
||||
#if defined(_PR_INET6_PROBE)
|
||||
PRBool _pr_ipv6_is_present;
|
||||
extern PRBool _pr_test_ipv6_socket(void);
|
||||
|
||||
#if !defined(_PR_INET6) && defined(_PR_HAVE_GETIPNODEBYNAME)
|
||||
extern PRStatus _pr_find_getipnodebyname(void);
|
||||
@ -292,17 +291,7 @@ extern PRStatus _pr_find_getaddrinfo(void);
|
||||
static PRBool
|
||||
_pr_probe_ipv6_presence(void)
|
||||
{
|
||||
#if !defined(_PR_INET6) && defined(_PR_HAVE_GETIPNODEBYNAME)
|
||||
if (_pr_find_getipnodebyname() != PR_SUCCESS)
|
||||
return PR_FALSE;
|
||||
#endif
|
||||
|
||||
#if !defined(_PR_INET6) && defined(_PR_HAVE_GETADDRINFO)
|
||||
if (_pr_find_getaddrinfo() != PR_SUCCESS)
|
||||
return PR_FALSE;
|
||||
#endif
|
||||
|
||||
return _pr_test_ipv6_socket();
|
||||
}
|
||||
#endif /* _PR_INET6_PROBE */
|
||||
|
||||
|
@ -59,7 +59,7 @@ INCLUDES = -I$(dist_includedir) -I$(topsrcdir)/pr/include -I$(topsrcdir)/pr/incl
|
||||
|
||||
DEFINES += -D_NSPR_BUILD_
|
||||
|
||||
CSRCS = prmalloc.c prmem.c
|
||||
CSRCS = prmem.c
|
||||
|
||||
include $(topsrcdir)/config/rules.mk
|
||||
|
||||
|
@ -210,25 +210,6 @@ loser:
|
||||
return;
|
||||
}
|
||||
|
||||
PR_IMPLEMENT(void)
|
||||
PR_FPrintZoneStats(PRFileDesc *debug_out)
|
||||
{
|
||||
int i, j;
|
||||
|
||||
for (j = 0; j < THREAD_POOLS; j++) {
|
||||
for (i = 0; i < MEM_ZONES; i++) {
|
||||
MemoryZone *mz = &zones[i][j];
|
||||
MemoryZone zone = *mz;
|
||||
if (zone.elements || zone.misses || zone.hits) {
|
||||
PR_fprintf(debug_out,
|
||||
"pool: %d, zone: %d, size: %d, free: %d, hit: %d, miss: %d, contend: %d\n",
|
||||
j, i, zone.blockSize, zone.elements,
|
||||
zone.hits, zone.misses, zone.contention);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
static void *
|
||||
pr_ZoneMalloc(PRUint32 size)
|
||||
{
|
||||
|
@ -49,8 +49,6 @@ CSRCS = \
|
||||
unix.c \
|
||||
unix_errors.c \
|
||||
uxproces.c \
|
||||
uxrng.c \
|
||||
uxshm.c \
|
||||
uxwrap.c \
|
||||
$(NULL)
|
||||
|
||||
|
@ -42,8 +42,6 @@ CSRCS = \
|
||||
unix.c \
|
||||
unix_errors.c \
|
||||
uxproces.c \
|
||||
uxrng.c \
|
||||
uxshm.c \
|
||||
uxwrap.c \
|
||||
$(NULL)
|
||||
|
||||
|
@ -46,7 +46,7 @@ include $(MOD_DEPTH)/config/autoconf.mk
|
||||
|
||||
include $(topsrcdir)/config/config.mk
|
||||
|
||||
CSRCS = prseg.c prshm.c prshma.c
|
||||
CSRCS = prseg.c
|
||||
|
||||
ifdef GC_LEAK_DETECTOR
|
||||
CSRCS += prgcleak.c
|
||||
|
@ -47,35 +47,16 @@ include $(MOD_DEPTH)/config/autoconf.mk
|
||||
include $(topsrcdir)/config/config.mk
|
||||
|
||||
CSRCS = \
|
||||
pralarm.c \
|
||||
pratom.c \
|
||||
prcountr.c \
|
||||
prdtoa.c \
|
||||
prenv.c \
|
||||
prerr.c \
|
||||
prerror.c \
|
||||
prerrortable.c \
|
||||
pripc.c \
|
||||
prinit.c \
|
||||
prnetdb.c \
|
||||
prinrval.c \
|
||||
pripc.c \
|
||||
prlog2.c \
|
||||
prlong.c \
|
||||
prnetdb.c \
|
||||
prolock.c \
|
||||
prrng.c \
|
||||
prsystem.c \
|
||||
prtime.c \
|
||||
prthinfo.c \
|
||||
prtpool.c \
|
||||
prtrace.c \
|
||||
$(NULL)
|
||||
|
||||
ifndef USE_PTHREADS
|
||||
CSRCS += \
|
||||
pripcsem.c \
|
||||
$(NULL)
|
||||
endif
|
||||
|
||||
TARGETS = $(OBJS)
|
||||
|
||||
INCLUDES = -I$(dist_includedir) -I$(topsrcdir)/pr/include -I$(topsrcdir)/pr/include/private
|
||||
|
@ -55,8 +55,8 @@ endif
|
||||
endif
|
||||
|
||||
CSRCS = \
|
||||
ptsynch.c \
|
||||
ptio.c \
|
||||
ptsynch.c \
|
||||
ptthread.c \
|
||||
ptmisc.c \
|
||||
$(NULL)
|
||||
|
@ -374,46 +374,13 @@ struct pt_Continuation
|
||||
|
||||
PTDebug pt_debug; /* this is shared between several modules */
|
||||
|
||||
PR_IMPLEMENT(void) PT_FPrintStats(PRFileDesc *debug_out, const char *msg)
|
||||
{
|
||||
PTDebug stats;
|
||||
char buffer[100];
|
||||
PRExplodedTime tod;
|
||||
PRInt64 elapsed, aMil;
|
||||
stats = pt_debug; /* a copy */
|
||||
PR_ExplodeTime(stats.timeStarted, PR_LocalTimeParameters, &tod);
|
||||
(void)PR_FormatTime(buffer, sizeof(buffer), "%T", &tod);
|
||||
|
||||
LL_SUB(elapsed, PR_Now(), stats.timeStarted);
|
||||
LL_I2L(aMil, 1000000);
|
||||
LL_DIV(elapsed, elapsed, aMil);
|
||||
|
||||
if (NULL != msg) PR_fprintf(debug_out, "%s", msg);
|
||||
PR_fprintf(
|
||||
debug_out, "\tstarted: %s[%lld]\n", buffer, elapsed);
|
||||
PR_fprintf(
|
||||
debug_out, "\tlocks [created: %u, destroyed: %u]\n",
|
||||
stats.locks_created, stats.locks_destroyed);
|
||||
PR_fprintf(
|
||||
debug_out, "\tlocks [acquired: %u, released: %u]\n",
|
||||
stats.locks_acquired, stats.locks_released);
|
||||
PR_fprintf(
|
||||
debug_out, "\tcvars [created: %u, destroyed: %u]\n",
|
||||
stats.cvars_created, stats.cvars_destroyed);
|
||||
PR_fprintf(
|
||||
debug_out, "\tcvars [notified: %u, delayed_delete: %u]\n",
|
||||
stats.cvars_notified, stats.delayed_cv_deletes);
|
||||
} /* PT_FPrintStats */
|
||||
|
||||
#else
|
||||
#endif /* DEBUG */
|
||||
|
||||
PR_IMPLEMENT(void) PT_FPrintStats(PRFileDesc *debug_out, const char *msg)
|
||||
{
|
||||
/* do nothing */
|
||||
} /* PT_FPrintStats */
|
||||
|
||||
#endif /* DEBUG */
|
||||
|
||||
#if defined(_PR_POLL_WITH_SELECT)
|
||||
/*
|
||||
* OSF1 and HPUX report the POLLHUP event for a socket when the
|
||||
@ -3374,6 +3341,8 @@ failed:
|
||||
return fd;
|
||||
} /* PR_AllocFileDesc */
|
||||
|
||||
#if 0
|
||||
|
||||
#if !defined(_PR_INET6) || defined(_PR_INET6_PROBE)
|
||||
PR_EXTERN(PRStatus) _pr_push_ipv6toipv4_layer(PRFileDesc *fd);
|
||||
#if defined(_PR_INET6_PROBE)
|
||||
@ -3484,7 +3453,7 @@ PR_IMPLEMENT(PRFileDesc*) PR_Socket(PRInt32 domain, PRInt32 type, PRInt32 proto)
|
||||
#endif
|
||||
return fd;
|
||||
} /* PR_Socket */
|
||||
|
||||
#endif
|
||||
/*****************************************************************************/
|
||||
/****************************** I/O public methods ***************************/
|
||||
/*****************************************************************************/
|
||||
@ -4312,6 +4281,7 @@ PR_IMPLEMENT(PRDirEntry*) PR_ReadDir(PRDir *dir, PRDirFlags flags)
|
||||
return &dir->d;
|
||||
} /* PR_ReadDir */
|
||||
|
||||
#if 0
|
||||
PR_IMPLEMENT(PRFileDesc*) PR_NewUDPSocket(void)
|
||||
{
|
||||
PRIntn domain = PF_INET;
|
||||
@ -4336,6 +4306,8 @@ PR_IMPLEMENT(PRFileDesc*) PR_OpenTCPSocket(PRIntn af)
|
||||
return PR_Socket(af, SOCK_STREAM, 0);
|
||||
} /* PR_NewTCPSocket */
|
||||
|
||||
#endif
|
||||
|
||||
PR_IMPLEMENT(PRStatus) PR_NewTCPSocketPair(PRFileDesc *fds[2])
|
||||
{
|
||||
PRInt32 osfd[2];
|
||||
|
@ -938,9 +938,9 @@ PR_IMPLEMENT(PRStatus) PR_Cleanup(void)
|
||||
PR_Unlock(pt_book.ml);
|
||||
|
||||
_PR_CleanupMW();
|
||||
_PR_CleanupDtoa();
|
||||
//_PR_CleanupDtoa();
|
||||
_PR_CleanupCallOnce();
|
||||
_PR_ShutdownLinker();
|
||||
//_PR_ShutdownLinker();
|
||||
_PR_LogCleanup();
|
||||
_PR_CleanupNet();
|
||||
/* Close all the fd's before calling _PR_CleanupIO */
|
||||
@ -963,7 +963,7 @@ PR_IMPLEMENT(PRStatus) PR_Cleanup(void)
|
||||
PR_DestroyLock(_pr_sleeplock);
|
||||
_pr_sleeplock = NULL;
|
||||
_PR_CleanupLayerCache();
|
||||
_PR_CleanupEnv();
|
||||
//_PR_CleanupEnv();
|
||||
#ifdef _PR_ZONE_ALLOCATOR
|
||||
_PR_DestroyZones();
|
||||
#endif
|
||||
|
@ -58,24 +58,15 @@ endif
|
||||
|
||||
ifdef USE_PTHREADS
|
||||
CSRCS = \
|
||||
prcmon.c \
|
||||
prrwlock.c \
|
||||
prtpd.c \
|
||||
$(NULL)
|
||||
else
|
||||
ifdef USE_BTHREADS
|
||||
CSRCS = \
|
||||
prcmon.c \
|
||||
prrwlock.c \
|
||||
prtpd.c \
|
||||
$(NULL)
|
||||
else
|
||||
CSRCS = \
|
||||
prcmon.c \
|
||||
prdump.c \
|
||||
prmon.c \
|
||||
prsem.c \
|
||||
prrwlock.c \
|
||||
prcthr.c \
|
||||
prtpd.c \
|
||||
$(NULL)
|
||||
|
Loading…
x
Reference in New Issue
Block a user