add detailed changelogs and 'genlog'--the script which generates them
[p5sagit/p5-mst-13.2.git] / win32 / makedef.pl
index fcccdcc..059fc49 100644 (file)
@@ -27,17 +27,24 @@ open(CFG,'config.h') || die "Cannot open config.h:$!";
 while (<CFG>)
  {
   $define{$1} = 1 if /^\s*#\s*define\s+(MYMALLOC)\b/;
+  $define{$1} = 1 if /^\s*#\s*define\s+(USE_THREADS)\b/;
  }
 close(CFG);
 
 warn join(' ',keys %define)."\n";
 
+if ($define{PERL_OBJECT}) {
+    print "LIBRARY PerlCore\n";
+    print "DESCRIPTION 'Perl interpreter'\n";
+    print "EXPORTS\n";
+    output_symbol("perl_alloc");
+    exit(0);
+}
+
 if ($CCTYPE ne 'GCC') 
  {
   print "LIBRARY Perl\n";
   print "DESCRIPTION 'Perl interpreter, export autogenerated'\n";
-  print "CODE LOADONCALL\n";
-  print "DATA LOADONCALL NONSHARED MULTIPLE\n";
  }
 else
  {
@@ -103,7 +110,6 @@ Perl_dump_packsubs
 Perl_dump_pm
 Perl_dump_sub
 Perl_expectterm
-Perl_error_no
 Perl_extralen
 Perl_fetch_gv
 Perl_fetch_io
@@ -165,7 +171,7 @@ Perl_regmystartp
 Perl_regnarrate
 Perl_regnaughty
 Perl_regnpar
-Perl_regparse
+Perl_regcomp_parse
 Perl_regprecomp
 Perl_regprev
 Perl_regprogram
@@ -176,7 +182,7 @@ Perl_regsize
 Perl_regstartp
 Perl_regtill
 Perl_regxend
-Perl_rx
+Perl_regcomp_rx
 Perl_same_dirent
 Perl_saw_return
 Perl_scan_const
@@ -245,9 +251,12 @@ if ($define{'MYMALLOC'})
 unless ($define{'USE_THREADS'})
  {
   skip_symbols [qw(
+Perl_getTHR
+Perl_setTHR
 Perl_condpair_magic
 Perl_thr_key
 Perl_sv_mutex
+Perl_svref_mutex
 Perl_malloc_mutex
 Perl_eval_mutex
 Perl_eval_cond
@@ -309,6 +318,8 @@ if ($define{'PERL_GLOBAL_STRUCT'})
  {
   my $global = readvar("../perlvars.h");
   skip_symbols $global;
+  emit_symbols [qw(Perl_GetVars)];
+  emit_symbols [qw(Perl_Vars Perl_VarsPtr)] unless $CCTYPE eq 'GCC';
  } 
 
 unless ($define{'DEBUGGING'})
@@ -349,11 +360,7 @@ close(GLOBAL);
 # doesn't hurt to include them anyway.
 # these don't have Perl prefix
 
-if ($define{'PERL_GLOBAL_STRUCT'})
- {
-  emit_symbol( ($CCTYPE eq 'GCC') ? 'Perl_GetVars' : 'Perl_VarsPtr')
- }
-else
+unless ($define{'PERL_GLOBAL_STRUCT'})
  {
   my $glob = readvar("../perlvars.h");
   emit_symbols $glob;
@@ -384,25 +391,7 @@ while (<DATA>) {
 
 foreach my $symbol (sort keys %export)
  {
-       if ($CCTYPE eq "BORLAND") {
-               # workaround Borland quirk by exporting both the straight
-               # name and a name with leading underscore.  Note the
-               # alias *must* come after the symbol itself, if both
-               # are to be exported. (Linker bug?)
-               print "\t_$symbol\n";
-               print "\t$symbol = _$symbol\n";
-       }
-        elsif ($CCTYPE eq 'GCC') {
-                # Symbols have leading _ whole process is $%£"% slow
-                # so skip aliases for now
-               print "\t$symbol\n";
-        }
-       else {
-               # for binary coexistence, export both the symbol and
-               # alias with leading underscore
-               print "\t$symbol\n";
-               print "\t_$symbol = $symbol\n";
-       }
+   output_symbol($symbol);
  }
 
 sub emit_symbol {
@@ -411,12 +400,36 @@ sub emit_symbol {
        $export{$symbol} = 1;
 }
 
+sub output_symbol {
+    my $symbol = shift;
+    if ($CCTYPE eq "BORLAND") {
+           # workaround Borland quirk by exporting both the straight
+           # name and a name with leading underscore.  Note the
+           # alias *must* come after the symbol itself, if both
+           # are to be exported. (Linker bug?)
+           print "\t_$symbol\n";
+           print "\t$symbol = _$symbol\n";
+    }
+    elsif ($CCTYPE eq 'GCC') {
+           # Symbols have leading _ whole process is $%£"% slow
+           # so skip aliases for now
+           print "\t$symbol\n";
+    }
+    else {
+           # for binary coexistence, export both the symbol and
+           # alias with leading underscore
+           print "\t$symbol\n";
+           print "\t_$symbol = $symbol\n";
+    }
+}
+
 1;
 __DATA__
 # extra globals not included above.
 perl_init_i18nl10n
 perl_init_ext
 perl_alloc
+perl_atexit
 perl_construct
 perl_destruct
 perl_free
@@ -433,6 +446,11 @@ perl_call_sv
 perl_require_pv
 perl_eval_pv
 perl_eval_sv
+perl_new_ctype
+perl_new_collate
+perl_new_numeric
+perl_set_numeric_standard
+perl_set_numeric_local
 boot_DynaLoader
 Perl_thread_create
 win32_errno
@@ -487,6 +505,7 @@ win32_mkdir
 win32_rmdir
 win32_chdir
 win32_flock
+win32_execv
 win32_execvp
 win32_htons
 win32_ntohs
@@ -556,6 +575,8 @@ win32_get_osfhandle
 win32_ioctl
 win32_utime
 win32_wait
+win32_waitpid
+win32_kill
 win32_str_os_error
 Perl_win32_init
 Perl_init_os_extras