Index: flint/user/flint.cpp
===================================================================
--- flint/user/flint.cpp	(revision 1124)
+++ flint/user/flint.cpp	(working copy)
@@ -523,13 +523,13 @@
     u_int32_ba(u_int32_t i = 0) :
     _bits(i),
     _rbits(_bits),
-    _sptr(0),
+    _sptr1(0),
     _eptr(31)    {}
 
     u_int32_ba  operator[](u_int32_t idx) {return range((u_int8_t)idx,(u_int8_t)idx);}
-    u_int32_ba& operator= (u_int32_t i)   {_rbits = ((i << _sptr) & mask()) | (_rbits & ~mask()); return *this;}
+    u_int32_ba& operator= (u_int32_t i)   {_rbits = ((i << _sptr1) & mask()) | (_rbits & ~mask()); return *this;}
     u_int32_t*  operator& ()              {return &_bits;}
-    operator    u_int32_t ()              {return((mask() & _rbits) >> _sptr);}
+    operator    u_int32_t ()              {return((mask() & _rbits) >> _sptr1);}
 
     u_int32_ba  range     (u_int8_t eptr, 
                            u_int8_t sptr) {return u_int32_ba(*this,eptr,sptr);}
@@ -538,14 +538,14 @@
     u_int32_ba(u_int32_ba& other, u_int8_t eptr, u_int8_t sptr) :
     _bits(other._bits),
     _rbits(other._bits),
-    _sptr(sptr),
+    _sptr1(sptr),
     _eptr(eptr) {}
 
     u_int32_t  mask       () {
         u_int32_t s_msk = (u_int32_t)-1; // start mask
         u_int32_t e_msk = (u_int32_t)-1; // end mask
 
-        s_msk = (s_msk << _sptr);
+        s_msk = (s_msk << _sptr1);
         e_msk = (_eptr >= (sizeof(_bits)*8-1)) ? e_msk : ~(e_msk << (_eptr+1));
 
         return(s_msk & e_msk);
@@ -554,7 +554,7 @@
     u_int32_t  _bits;
     u_int32_t& _rbits;
 
-    u_int8_t   _sptr;
+    u_int8_t   _sptr1;
     u_int8_t   _eptr;
 };
 
@@ -3433,8 +3433,8 @@
                 mac <<= 24;
                 mac |= (old_guids[i+1].l & 0xffffff);
 
-                old_guids[GUIDS+i].h = mac >> 32;
-                old_guids[GUIDS+i].l = mac  & 0xffffffff;
+                old_guids[GUIDS+i].h = u_int32_t(mac >> 32);
+                old_guids[GUIDS+i].l = u_int32_t(mac  & 0xffffffff);
 
                 // printf("-D- Guid " GUID_FORMAT " to MAC "MAC_FORMAT"\n", old_guids[i+1].h, old_guids[i+1].l, old_guids[i+GUIDS].h,old_guids[i+GUIDS].l  );
             }
@@ -3724,7 +3724,7 @@
 
         switch (tagId) {
         case II_FwVersion:
-            info->fwVer[0] = __be32_to_cpu(*(p+1)) >> 16;
+            info->fwVer[0] = (u_int16_t)(__be32_to_cpu(*(p+1)) >> 16);
             tmp = __be32_to_cpu(*(p+2));
             info->fwVer[1] = tmp >> 16;
             info->fwVer[2] = tmp & 0xffff;
Index: flint/user/SOURCES
===================================================================
--- flint/user/SOURCES	(revision 1124)
+++ flint/user/SOURCES	(working copy)
@@ -2,6 +2,8 @@
 TARGETTYPE=PROGRAM
 UMTYPE=console
 USE_MSVCRT=1
+USE_STL=1
+USE_NATIVE_EH=1
 
 TRUNK=..\..\..
 !if !defined(EXTERNAL_TOOLS)
@@ -17,11 +19,6 @@
 
 # TODO: Define free and checked.
 TARGETLIBS=\
-!if $(FREEBUILD)
-	$(CRT_LIB_PATH)\msvcprt.lib \
-!else
-	$(CRT_LIB_PATH)\msvcprt.lib \
-!endif	
     $(TARGETPATH)\*\mtcr.lib \
     $(SDK_LIB_PATH)\Ws2_32.lib
 
@@ -34,7 +31,7 @@
 #!endif
 
 		
-SOURCES=..\mflash.c ..\flint.cpp
+SOURCES=mflash.c flint.cpp
 
 INCLUDES=  \
         ..; \
@@ -44,7 +41,7 @@
 	..\..\mtcr\user
 	
 # Could be any special flag needed for this project
-USER_C_FLAGS=$(USER_C_FLAGS) /MD /EHsc
+USER_C_FLAGS=$(USER_C_FLAGS) /MD 
 
 C_DEFINES=$(C_DEFINES) -DWIN32 -D__WIN__ -D__i386__ -DNO_ZLIB
 !if !$(FREEBUILD)
Index: spark/user/SOURCES
===================================================================
--- spark/user/SOURCES	(revision 1124)
+++ spark/user/SOURCES	(working copy)
@@ -3,6 +3,7 @@
 UMTYPE=console
 USE_MSVCRT=1
 USE_STL=1
+USE_NATIVE_EH=1
 
 !if !defined(WINIBHOME)
 WINIBHOME=..\..\..
@@ -30,7 +31,7 @@
 			$(TARGETPATH)\*\mtcr.lib
 !endif
 
-USER_C_FLAGS=$(USER_C_FLAGS) /Ze /EHsc
+USER_C_FLAGS=$(USER_C_FLAGS)  
 
 # TODO:Should I define the __WIN__ manually
 C_DEFINES=$(C_DEFINES) -D__WIN__
Index: spark/user/spark.cpp
===================================================================
--- spark/user/spark.cpp	(revision 1124)
+++ spark/user/spark.cpp	(working copy)
@@ -2590,8 +2590,8 @@
             f.data.clear();
             f.data.resize(8,0);
             
-            ::PatchImgBytes(&f.data[0], guid >> 32);
-            ::PatchImgBytes(&f.data[4], guid & 0xffffffff);
+            ::PatchImgBytes(&f.data[0], (u_int32_t)(guid >> 32));
+            ::PatchImgBytes(&f.data[4], (u_int32_t)(guid & 0xffffffff));
         }
         break;
 
@@ -3610,7 +3610,7 @@
             else if (!strcmp(av[i], "-is3_i2c")) {
                 NEXT("-is3_i2c");
                 char* ep;
-                is3I2cSlave = strtoul(av[i], &ep, 16);
+                is3I2cSlave = (u_int8_t)strtoul(av[i], &ep, 16);
                 if (*ep) {
                     SETERR(("Bad argument for %s flag (%s). Expecting a hexadecimal integer.", av[i-1], av[i]));
                 }
@@ -3618,7 +3618,7 @@
             else if (!strcmp(av[i], "-pe_i2c") || !strcmp(av[i], "-pe")) {
                 NEXT("-pe_i2c");
                 char* ep;
-                userPrimaryI2cAddr = strtoul(av[i], &ep, 16);
+                userPrimaryI2cAddr = (u_int8_t)strtoul(av[i], &ep, 16);
                 if (*ep) {
                     SETERR(("Bad argument for %s flag (%s). Expecting a hexadecimal integer.", av[i-1], av[i]));
                 }
@@ -3626,7 +3626,7 @@
             else if (!strcmp(av[i], "-se_i2c") || !strcmp(av[i], "-se") ) {
                 NEXT(av[i]);
                 char* ep;
-                userSecondaryI2cAddr = strtoul(av[i], &ep, 16);
+                userSecondaryI2cAddr = (u_int8_t)strtoul(av[i], &ep, 16);
                 if (*ep) {
                     SETERR(("Bad argument for %s flag (%s). Expecting a hexadecimal integer.", av[i-1], av[i]));
                 }
