зеркало из https://github.com/mozilla/pjs.git
Make gc/boehm compile under linux. Compiles but doesn't necessarily run programs. Bug #31287
This commit is contained in:
Родитель
57978e5c23
Коммит
c07d3c345c
|
@ -27,17 +27,27 @@ include $(DEPTH)/config/autoconf.mk
|
|||
MODULE=boehm
|
||||
LIBRARY_NAME=boehm
|
||||
|
||||
DEFINES += -DATOMIC_UNCOLLECTABLE -DNO_SIGNALS -DNO_EXECUTE_PERMISSION -DALL_INTERIOR_POINTERS -DSILENT
|
||||
DEFINES += -DATOMIC_UNCOLLECTABLE -DNO_SIGNALS -DNO_EXECUTE_PERMISSION -DALL_INTERIOR_POINTERS -DSILENT -DLARGE_CONFIG
|
||||
|
||||
DEFINES += -DREDIRECT_MALLOC=GC_malloc
|
||||
|
||||
# linux-specific stuff
|
||||
ifeq ($(OS_ARCH),Linux)
|
||||
DEFINES += -DLINUX_THREADS -D_REENTRANT
|
||||
endif
|
||||
ifdef ($(OS_ARCH)$(OS_RELEASE),SUNOS5)
|
||||
DEFINES += -DSOLARIS_THREADS -D_SOLARIS_PTHREADS -D_REENTRANT
|
||||
endif
|
||||
ifdef ($(OS_ARCH),IRIX)
|
||||
DEFINES += -DIRIX_THREADS
|
||||
endif
|
||||
|
||||
|
||||
EXPORTS = gc.h \
|
||||
generic_threads.h \
|
||||
$(NULL)
|
||||
|
||||
#EXPORTS := $(addprefix $(srcdir)/, $(EXPORTS))
|
||||
|
||||
CSRCS= allchblk.c \
|
||||
alloc.c \
|
||||
blacklst.c \
|
||||
|
@ -68,11 +78,9 @@ CSRCS= allchblk.c \
|
|||
generic_threads.c \
|
||||
$(NULL)
|
||||
|
||||
CPPSRCS = gc_cpp.cc
|
||||
|
||||
EXTRA_DSO_LDOPTS += \
|
||||
-lpthread \
|
||||
$(NULL)
|
||||
|
||||
LCPPSRCS = gc_cpp.cc
|
||||
LOBJS := $(LCPPSRCS:.cc=.$(OBJ_SUFFIX))
|
||||
|
||||
include $(topsrcdir)/config/rules.mk
|
||||
|
||||
|
||||
|
|
|
@ -58,7 +58,7 @@ void GC_generic_init_threads(GC_generic_mark_all_stacks_proc mark_all_stacks,
|
|||
// GC_set_max_heap_size(20L * 1024L * 1024L);
|
||||
}
|
||||
|
||||
#ifndef WIN32_THREADS
|
||||
#if !defined(WIN32_THREADS) && !defined(LINUX_THREADS)
|
||||
void GC_push_all_stacks()
|
||||
{
|
||||
GC_generic_mark_all_stacks(&mark_range);
|
||||
|
|
|
@ -624,7 +624,7 @@ out:
|
|||
|
||||
#endif
|
||||
|
||||
#if defined(OS2) || defined(MACOS)
|
||||
#if defined(OS2) || defined(MACOS) || defined(linux)
|
||||
FILE * GC_stdout = NULL;
|
||||
FILE * GC_stderr = NULL;
|
||||
int GC_tmp; /* Should really be local ... */
|
||||
|
@ -640,7 +640,7 @@ int GC_tmp; /* Should really be local ... */
|
|||
}
|
||||
#endif
|
||||
|
||||
#if !defined(OS2) && !defined(MACOS) && !defined(MSWIN32)
|
||||
#if !defined(OS2) && !defined(MACOS) && !defined(MSWIN32) && !defined(linux)
|
||||
int GC_stdout = 1;
|
||||
int GC_stderr = 2;
|
||||
# if !defined(AMIGA)
|
||||
|
@ -677,7 +677,7 @@ size_t len;
|
|||
(len), &GC_junk, NULL),\
|
||||
(GC_tmp? 1 : -1))
|
||||
#else
|
||||
# if defined(OS2) || defined(MACOS)
|
||||
# if defined(OS2) || defined(MACOS) || defined(linux)
|
||||
# define WRITE(f, buf, len) (GC_set_files(), \
|
||||
GC_tmp = fwrite((buf), 1, (len), (f)), \
|
||||
fflush(f), GC_tmp)
|
||||
|
|
Загрузка…
Ссылка в новой задаче