mirror of
https://gitlab.com/embeddable-common-lisp/ecl.git
synced 2026-01-02 15:40:55 -08:00
Remove dependency on lwp.h and add header pthread.h for several symbols (PTHREAD_MUTEX... etc) required in packages.d and threads.d
This commit is contained in:
parent
75fb4cd6b6
commit
ab542dcf4e
2 changed files with 6 additions and 2 deletions
|
|
@ -35,8 +35,7 @@ HDIR = ../ecl
|
|||
HFILES = ../ecl/config.h $(HDIR)/ecl.h $(HDIR)/ecl-cmp.h\
|
||||
$(HDIR)/object.h $(HDIR)/cs.h $(HDIR)/stacks.h\
|
||||
$(HDIR)/external.h $(HDIR)/eval.h\
|
||||
$(HDIR)/number.h $(HDIR)/page.h $(HDIR)/unify.h\
|
||||
$(HDIR)/lwp.h
|
||||
$(HDIR)/number.h $(HDIR)/page.h $(HDIR)/unify.h
|
||||
OBJS = main.o symbol.o package.o list.o\
|
||||
apply.o eval.o interpreter.o compiler.o disassembler.o \
|
||||
instance.o gfun.o reference.o character.o\
|
||||
|
|
|
|||
|
|
@ -191,6 +191,11 @@ extern void cl_write_object(cl_object x, cl_object stream);
|
|||
# define pthread_mutex_lock(x) \
|
||||
(WaitForSingleObject(*(HANDLE*)(x), INFINITE) != WAIT_OBJECT_0)
|
||||
# define pthread_mutex_unlock(x) (ReleaseMutex(*(HANDLE*)(x)) == 0)
|
||||
# else
|
||||
# include <pthread.h>
|
||||
# if defined(__APPLE__) || defined(freebsd)
|
||||
# define PTHREAD_MUTEX_ERROR_CHECK_NP PTHREAD_MUTEX_ERROR_CHECK_NP
|
||||
# endif
|
||||
# endif
|
||||
# define HASH_TABLE_LOCK(h) if ((h)->hash.lockable) if (pthread_mutex_lock(&(h)->hash.lock)) internal_error("")
|
||||
# define PACKAGE_LOCK(p) if (pthread_mutex_lock(&(p)->pack.lock)) internal_error("")
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue