From: sof Date: Wed, 3 Mar 1999 19:20:42 +0000 (+0000) Subject: [project @ 1999-03-03 19:20:41 by sof] X-Git-Tag: Approximately_9120_patches~6426 X-Git-Url: http://git.megacz.com/?a=commitdiff_plain;h=680f2ac449315085d849d9c52af8ef0cc6ebc86c;p=ghc-hetmet.git [project @ 1999-03-03 19:20:41 by sof] Win32 DLL tweaks --- diff --git a/ghc/rts/Main.c b/ghc/rts/Main.c index 9f2c9c1..1b7bcba 100644 --- a/ghc/rts/Main.c +++ b/ghc/rts/Main.c @@ -1,5 +1,5 @@ /* ----------------------------------------------------------------------------- - * $Id: Main.c,v 1.5 1999/02/26 16:46:50 simonm Exp $ + * $Id: Main.c,v 1.6 1999/03/03 19:20:42 sof Exp $ * * (c) The GHC Team 1998-1999 * @@ -7,6 +7,8 @@ * * ---------------------------------------------------------------------------*/ +#define COMPILING_RTS_MAIN + #include "Rts.h" #include "RtsAPI.h" #include "RtsFlags.h" @@ -14,7 +16,6 @@ #include "RtsUtils.h" #ifdef DEBUG -#include "RtsFlags.h" /* for debugging flags */ #include "Printer.h" /* for printing */ #endif diff --git a/ghc/rts/RtsFlags.h b/ghc/rts/RtsFlags.h index 562202b..9c0de8f 100644 --- a/ghc/rts/RtsFlags.h +++ b/ghc/rts/RtsFlags.h @@ -1,5 +1,5 @@ /* ----------------------------------------------------------------------------- - * $Id: RtsFlags.h,v 1.10 1999/02/18 13:00:28 sewardj Exp $ + * $Id: RtsFlags.h,v 1.11 1999/03/03 19:20:41 sof Exp $ * * (c) The GHC Team, 1998-1999 * @@ -249,7 +249,11 @@ struct RTS_FLAGS { #endif }; +#ifdef COMPILING_RTS_MAIN +extern DLLIMPORT struct RTS_FLAGS RtsFlags; +#else extern struct RTS_FLAGS RtsFlags; +#endif /* Routines that operate-on/to-do-with RTS flags: */ @@ -276,8 +280,11 @@ void setupRtsFlags(int *argc, char *argv[], int *rts_argc, char *rts_argv[]); #define TIME_FILENAME_FMT "%0.122s.time" #define TIME_FILENAME_FMT_GUM "%0.118s.%03d.time" -extern int prog_argc; /* an "int" so as to match normal "argc" */ +/* an "int" so as to match normal "argc" */ +/* Now defined in Stg.h (lib/std/cbits need these too.) +extern int prog_argc; extern char **prog_argv; +*/ extern int rts_argc; /* ditto */ extern char *rts_argv[];