commit - 45ac814c8609174199cadb6f1bbb4baf7c12c94a
commit + e7ae61181c96663ca6b5620f78a0d1fdd3a93002
blob - ac9e260c2c4822c425e6479fc2f9a0eb747f2987
blob + 99f899cc154023afd44fb17d84107379ed2c1dd1
--- src/libthread/mkfile
+++ src/libthread/mkfile
OpenBSD.$O FreeBSD.$O: BSD.c
NetBSD.$O: Linux.c
-tprimes: tprimes.$O
- 9l -o $target $target.$O $PLAN9/lib/$LIB -l9 -lpthread
-tspawn: tspawn.$O
- 9l -o $target $target.$O $PLAN9/lib/$LIB -l9 -lpthread
-tspawnloop: tspawnloop.$O
- 9l -o $target $target.$O $PLAN9/lib/$LIB -l9 -lpthread
+tprimes: test/tprimes.$O
+ 9l -o $target test/$target.$O
+tspawn: test/tspawn.$O
+ 9l -o $target test/$target.$O
+tspawnloop: test/tspawnloop.$O
+ 9l -o $target test/$target.$O
%.$O: %.c
- $CC $CFLAGS -I. $stem.c
+ $CC -o $target $CFLAGS -I. $stem.c
# cannot use generic .S rule because it conflicts
# with generic .s rule in mkcommon on case-insensitive
blob - cdc1ad029312d1649a806a7804bd5313475fecb8
blob + a6836625038cc631ced9a0726aaadababd235134
--- src/libthread/sysofiles.sh
+++ src/libthread/sysofiles.sh
*-NetBSD-*)
echo ${SYSNAME}-${OBJTYPE}-asm.o $SYSNAME.o
;;
-*-Darwin-*)
+*-Darwin-[6-8].*)
echo ${SYSNAME}-${OBJTYPE}-asm.o ${SYSNAME}-${OBJTYPE}.o pthread.o
;;
+*-Darwin-*)
+ echo pthread.o
+ ;;
*-OpenBSD-*)
echo ${SYSNAME}-${OBJTYPE}-asm.o ${SYSNAME}-${OBJTYPE}.o $SYSNAME.o
;;
blob - bc18d3a4c7489ada9da5c8ddaf6f1b0d7b1266ad
blob + 3d68299a1c84d175b9a57e2be82a1003515d82cb
--- src/libthread/threadimpl.h
+++ src/libthread/threadimpl.h
extern void makecontext(ucontext_t*, void(*)(), int, ...);
#endif
-#if defined(__APPLE__)
+#if defined(__APPLE__) && !defined(__DARWIN_UNIX03)
# define mcontext libthread_mcontext
# define mcontext_t libthread_mcontext_t
# define ucontext libthread_ucontext