diff -pru perl5.004_56/global.sym perl5.004_56.thr/global.sym
--- perl5.004_56/global.sym	Wed Dec 10 02:35:44 1997
+++ perl5.004_56.thr/global.sym	Sat Dec 20 21:26:44 1997
@@ -15,6 +15,7 @@ bool__amg
 bor_amg
 bxor_amg
 check
+compcv
 compl_amg
 concat_amg
 concat_ass_amg
@@ -37,6 +38,7 @@ get_op_descs
 get_op_names
 ge_amg
 gt_amg
+hexdigit
 init_thread_intern
 inc_amg
 io_close
@@ -46,10 +48,12 @@ log_amg
 lshift_amg
 lshift_ass_amg
 lt_amg
+maxo
 mod_amg
 mod_ass_amg
 mult_amg
 mult_ass_amg
+na
 ncmp_amg
 ne_amg
 neg_amg
@@ -71,6 +75,7 @@ nomem
 nomethod_amg
 not_amg
 numer_amg
+numeric_local
 op_desc
 op_name
 opargs
@@ -103,6 +108,9 @@ slt_amg
 sne_amg
 sqrt_amg
 string_amg
+sv_no
+sv_undef
+sv_yes
 subtr_amg
 subtr_ass_amg
 varies
@@ -286,6 +294,7 @@ do_sprintf
 do_sysseek
 do_tell
 do_trans
+do_undump
 do_vecset
 do_vop
 dofindlabel
diff -pru perl5.004_56/Makefile.SH perl5.004_56.thr/Makefile.SH
--- perl5.004_56/Makefile.SH	Wed Dec 17 05:30:38 1997
+++ perl5.004_56.thr/Makefile.SH	Sat Dec 20 20:55:34 1997
@@ -501,7 +501,7 @@ $(FIRSTMAKEFILE):	README $(MAKEDEPEND)
 config.h: config_h.SH config.sh
 	$(SHELL) config_h.SH
 
-perl.exp: perl_exp.SH config.sh
+perl.exp: perl_exp.SH config.sh global.sym
 	$(SHELL) perl_exp.SH
 
 # When done, touch perlmain.c so that it doesn't get remade each time.
diff -pru perl5.004_56/os2/Makefile.SHs perl5.004_56.thr/os2/Makefile.SHs
--- perl5.004_56/os2/Makefile.SHs	Wed Dec 17 03:15:30 1997
+++ perl5.004_56.thr/os2/Makefile.SHs	Sat Dec 20 21:18:00 1997
@@ -6,6 +6,11 @@
 # Additional rules supported: perl_, aout_test, aout_install, use them
 # for a.out style perl (which may fork).
 
+case "$archname" in
+ *-thread)	dll_post=_thr;;
+ *)		dll_post='' ;;
+esac
+
 $spitshell >>Makefile <<!GROK!THIS!
 
 AOUT_OPTIMIZE = $optimize
@@ -22,13 +27,16 @@ AOUT_CLDFLAGS_DLL	= -Zexe -Zmt -Zcrtdll
 
 LD_OPT		= $optimize
 
+PERL_DLL_BASE	= perl$dll_post
+PERL_DLL	= \$(PERL_DLL_BASE)\$(DLSUFFIX)
+
 !GROK!THIS!
 
 $spitshell >>Makefile <<'!NO!SUBS!'
-$(LIBPERL): perl.imp perl.dll perl5.def
+$(LIBPERL): perl.imp $(PERL_DLL) perl5.def
 	emximp -o $(LIBPERL) perl.imp
 
-$(AOUT_LIBPERL_DLL): perl.imp perl.dll perl5.def
+$(AOUT_LIBPERL_DLL): perl.imp $(PERL_DLL) perl5.def
 	emximp -o $(AOUT_LIBPERL_DLL) perl.imp
 
 perl.imp: perl5.def
@@ -38,11 +46,11 @@ perl.imp: perl5.def
 	echo	'emx_malloc		emxlibcm	402	?' >> $@
 	echo	'emx_realloc		emxlibcm	403	?' >> $@
 
-perl.dll: $(obj) perl5.def perl$(OBJ_EXT)
+$(PERL_DLL): $(obj) perl5.def perl$(OBJ_EXT)
 	$(LD) $(LD_OPT) $(LDDLFLAGS) -o $@ perl$(OBJ_EXT) $(obj) $(libs) perl5.def
 
 perl5.def: perl.linkexp
-	echo "LIBRARY 'Perl' INITINSTANCE TERMINSTANCE"	> $@
+	echo "LIBRARY '$(PERL_DLL_BASE)' INITINSTANCE TERMINSTANCE"	> $@
 	echo DESCRIPTION "'Perl interpreter, export autogenerated'"	>>$@
 	echo STACKSIZE 32768				>>$@
 	echo CODE LOADONCALL				>>$@
@@ -68,7 +76,7 @@ perl.exports: perl.exp EXTERN.h perl.h
 		$(CC) -DEMBED  -E - | \
 		awk '{if ($$2 == "") print $$1}' | sort | uniq > $@
 
-perl.linkexp: perl.exports perl.map
+perl.linkexp: perl.exports perl.map  os2/os2.sym
 	cat perl.exports os2/os2.sym perl.map | sort | uniq -d | sed -e 's/\w\+/  "\0"/' > perl.linkexp
 
 # We link miniperl statically, since .DLL depends on $(DYNALOADER) 
diff -pru perl5.004_56/os2/os2.c perl5.004_56.thr/os2/os2.c
--- perl5.004_56/os2/os2.c	Wed Dec 17 03:15:30 1997
+++ perl5.004_56.thr/os2/os2.c	Sat Dec 20 20:24:52 1997
@@ -40,16 +40,16 @@ const char *pthreads_states[] = {
 
 typedef struct {
     void *status;
-    pthread_cond_t cond;
+    perl_cond cond;
     enum pthreads_state state;
 } thread_join_t;
 
 thread_join_t *thread_join_data;
 int thread_join_count;
-pthread_mutex_t start_thread_mutex;
+perl_mutex start_thread_mutex;
 
 int
-pthread_join(pthread_t tid, void **status)
+pthread_join(perl_os_thread tid, void **status)
 {
     MUTEX_LOCK(&start_thread_mutex);
     switch (thread_join_data[tid].state) {
@@ -117,7 +117,7 @@ pthread_startit(void *arg)
 }
 
 int
-pthread_create(pthread_t *tid, const pthread_attr_t *attr, 
+pthread_create(perl_os_thread *tid, const pthread_attr_t *attr, 
 	       void *(*start_routine)(void*), void *arg)
 {
     void *args[2];
@@ -134,7 +134,7 @@ pthread_create(pthread_t *tid, const pth
 }
 
 int 
-pthread_detach(pthread_t tid)
+pthread_detach(perl_os_thread tid)
 {
     MUTEX_LOCK(&start_thread_mutex);
     switch (thread_join_data[tid].state) {
@@ -157,7 +157,7 @@ pthread_detach(pthread_t tid)
 
 /* This is a very bastardized version: */
 int
-os2_cond_wait(pthread_cond_t *c, pthread_mutex_t *m)
+os2_cond_wait(perl_cond *c, perl_mutex *m)
 {						
     int rc;
     if ((rc = DosResetEventSem(*c,&na)) && (rc != ERROR_ALREADY_RESET))
diff -pru perl5.004_56/os2/os2.sym perl5.004_56.thr/os2/os2.sym
--- perl5.004_56/os2/os2.sym	Wed Dec 17 03:56:40 1997
+++ perl5.004_56.thr/os2/os2.sym	Sat Dec 20 21:10:30 1997
@@ -8,10 +8,11 @@ dlerror
 my_tmpfile
 my_tmpnam
 my_flock
-malloc_mutex
-threads_mutex
-nthreads
-nthreads_cond
+Perl_malloc_mutex
+Perl_nthreads
+Perl_nthreads_cond
+Perl_sighandlerp
+Perl_threads_mutex
 os2_cond_wait
 pthread_join
 pthread_create
diff -pru perl5.004_56/os2/os2thread.h perl5.004_56.thr/os2/os2thread.h
--- perl5.004_56/os2/os2thread.h	Wed Dec 17 03:58:56 1997
+++ perl5.004_56.thr/os2/os2thread.h	Sat Dec 20 20:16:36 1997
@@ -1,10 +1,10 @@
 #include <sys/builtin.h>
 #include <sys/fmutex.h>
 #include <sys/rmutex.h>
-typedef int pthread_t;
-typedef _rmutex pthread_mutex_t;
+typedef int perl_os_thread;
+typedef _rmutex perl_mutex;
 /*typedef HEV pthread_cond_t;*/
-typedef unsigned long pthread_cond_t;
-typedef int pthread_key_t;
+typedef unsigned long perl_cond;
+typedef int perl_key;
 typedef unsigned long pthread_attr_t;
 #define PTHREADS_INCLUDED
