cvsuser     03/11/25 08:23:11

  Modified:    config/gen/platform win32.c win32.h
               lib/Parrot/Configure Step.pm
               src      global_setup.c
  Log:
  Added an optional platform init code function to global setup.
  
  Added in an actual platform init code function to the windows
  version of Parrot to disable the damn "Your program has crashed!" dialog
  box.
  
  Revision  Changes    Path
  1.9       +6 -0      parrot/config/gen/platform/win32.c
  
  Index: win32.c
  ===================================================================
  RCS file: /cvs/public/parrot/config/gen/platform/win32.c,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -w -r1.8 -r1.9
  --- win32.c   16 Aug 2003 13:21:45 -0000      1.8
  +++ win32.c   25 Nov 2003 16:23:06 -0000      1.9
  @@ -22,6 +22,12 @@
   ** Parrot_floatval_time()
   */
   
  +void
  +Parrot_platform_init_code(void)
  +{
  + SetErrorMode(SEM_NOGPFAULTERRORBOX); 
  +}
  +
   FLOATVAL
   Parrot_floatval_time(void)
   {
  
  
  
  1.9       +4 -0      parrot/config/gen/platform/win32.h
  
  Index: win32.h
  ===================================================================
  RCS file: /cvs/public/parrot/config/gen/platform/win32.h,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -w -r1.8 -r1.9
  --- win32.h   6 Jun 2003 08:29:44 -0000       1.8
  +++ win32.h   25 Nov 2003 16:23:06 -0000      1.9
  @@ -16,6 +16,10 @@
   #  define S_ISREG(m) ((m & S_IFMT) == S_IFREG)
   #endif
   
  +#define PARROT_HAS_PLATFORM_INIT_CODE
  +
  +void Parrot_platform_init_code(void);
  +
   /* These disable certain Level 4 Warnings */
   #pragma warning( disable: 4100 ) /* disables 'unreferenced formal parameter'
                                     * warnings */
  
  
  
  1.17      +3 -2      parrot/lib/Parrot/Configure/Step.pm
  
  Index: Step.pm
  ===================================================================
  RCS file: /cvs/public/parrot/lib/Parrot/Configure/Step.pm,v
  retrieving revision 1.16
  retrieving revision 1.17
  diff -u -w -r1.16 -r1.17
  --- Step.pm   2 Oct 2003 12:01:27 -0000       1.16
  +++ Step.pm   25 Nov 2003 16:23:09 -0000      1.17
  @@ -2,6 +2,7 @@
   
   use strict;
   use Exporter;
  +use Carp;
   use File::Copy ();
   use vars qw(@ISA @EXPORT @EXPORT_OK %EXPORT_TAGS);
   
  @@ -176,9 +177,9 @@
        my($cc, $ccflags, $ldout, $o, $link, $linkflags, $cc_exe_out, $exe, $libs)=
                Configure::Data->get( qw(cc ccflags ld_out o link linkflags cc_exe_out 
exe libs) );
   
  -     system("$cc $ccflags -I./include -c test.c >test.cco $redir_err") and die "C 
compiler failed (see test.cco)";
  +     system("$cc $ccflags -I./include -c test.c >test.cco $redir_err") and confess 
"C compiler failed (see test.cco)";
   
  -     system("$link $linkflags test$o ${cc_exe_out}test$exe $libs >test.ldo 
$redir_err") and die "Linker failed (see test.ldo)";
  +     system("$link $linkflags test$o ${cc_exe_out}test$exe $libs >test.ldo 
$redir_err") and confess "Linker failed (see test.ldo)";
   }
   
   sub cc_run {
  
  
  
  1.47      +5 -1      parrot/src/global_setup.c
  
  Index: global_setup.c
  ===================================================================
  RCS file: /cvs/public/parrot/src/global_setup.c,v
  retrieving revision 1.46
  retrieving revision 1.47
  diff -u -w -r1.46 -r1.47
  --- global_setup.c    23 Oct 2003 17:48:59 -0000      1.46
  +++ global_setup.c    25 Nov 2003 16:23:11 -0000      1.47
  @@ -1,7 +1,7 @@
   /* global_setup.c
    *  Copyright: 2001-2003 The Perl Foundation.  All Rights Reserved.
    *  CVS Info
  - *     $Id: global_setup.c,v 1.46 2003/10/23 17:48:59 robert Exp $
  + *     $Id: global_setup.c,v 1.47 2003/11/25 16:23:11 dan Exp $
    *  Overview:
    *      Performs all the global setting up of things. This includes the
    *      (very few) global variables that Parrot totes around
  @@ -26,6 +26,10 @@
       PMC *iglobals;
       PMC *classname_hash;
       PMC *self;
  +
  +#ifdef PARROT_HAS_PLATFORM_INIT_CODE
  +    Parrot_platform_init_code();
  +#endif
   
       string_init();              /* Set up the string subsystem */
   
  
  
  

Reply via email to