diff -ur fltk-1.3.x-r9285-orig/FL/Fl_Menu_Item.H fltk-1.3.x-r9285/FL/Fl_Menu_Item.H
--- fltk-1.3.x-r9285-orig/FL/Fl_Menu_Item.H	2011-07-18 23:49:30.000000000 -0500
+++ fltk-1.3.x-r9285/FL/Fl_Menu_Item.H	2012-03-22 10:54:43.823252233 -0500
@@ -240,7 +240,7 @@
     for the menu item's callback function.
     \see Fl_Callback_p Fl_MenuItem::callback() const
    */
-  void callback(Fl_Callback1*c, long p=0) {callback_=(Fl_Callback*)c; user_data_=(void*)p;}
+  void callback(Fl_Callback1*c, long p=0) {callback_=(Fl_Callback*)c; user_data_=(void*)(fl_intptr_t)p;}
 
   /**
     Gets the user_data() argument that is sent to the callback function.
@@ -264,7 +264,7 @@
     and stores it in the menu item's userdata() member.
     This may not be portable to some machines.
   */
-  void argument(long v) {user_data_ = (void*)v;}
+  void argument(long v) {user_data_ = (void*)(fl_intptr_t)v;}
 
   /** Gets what key combination shortcut will trigger the menu item. */
   int shortcut() const {return shortcut_;}
@@ -388,7 +388,7 @@
     the callback.
     You must first check that callback() is non-zero before calling this.
   */
-  void do_callback(Fl_Widget* o,long arg) const {callback_(o, (void*)arg);}
+  void do_callback(Fl_Widget* o,long arg) const {callback_(o, (void*)(fl_intptr_t)arg);}
 
   // back-compatibility, do not use:
 
diff -ur fltk-1.3.x-r9285-orig/FL/Fl_Widget.H fltk-1.3.x-r9285/FL/Fl_Widget.H
--- fltk-1.3.x-r9285-orig/FL/Fl_Widget.H	2011-10-04 08:10:55.000000000 -0500
+++ fltk-1.3.x-r9285/FL/Fl_Widget.H	2012-03-22 10:53:40.221856503 -0500
@@ -571,7 +571,7 @@
       \param[in] cb new callback
       \param[in] p user data
    */
-  void callback(Fl_Callback1*cb, long p=0) {callback_=(Fl_Callback*)cb; user_data_=(void*)p;}
+  void callback(Fl_Callback1*cb, long p=0) {callback_=(Fl_Callback*)cb; user_data_=(void*)(fl_intptr_t)p;}
 
   /** Gets the user data for this widget.
       Gets the current user data (void *) argument that is passed to the callback function.
@@ -593,7 +593,7 @@
       \todo The user data value must be implemented using \em intptr_t or similar
       to avoid 64-bit machine incompatibilities.
    */
-  void argument(long v) {user_data_ = (void*)v;}
+  void argument(long v) {user_data_ = (void*)(fl_intptr_t)v;}
 
   /** Returns the conditions under which the callback is called.
 
@@ -831,7 +831,7 @@
       \param[in] arg call the callback with \p arg as the user data argument
       \see callback()
    */
-  void do_callback(Fl_Widget* o,long arg) {do_callback(o,(void*)arg);}
+  void do_callback(Fl_Widget* o,long arg) {do_callback(o,(void*)(fl_intptr_t)arg);}
 
   // Causes a widget to invoke its callback function with arbitrary arguments.
   // Documentation and implementation in Fl_Widget.cxx
diff -ur fltk-1.3.x-r9285-orig/FL/glut.H fltk-1.3.x-r9285/FL/glut.H
--- fltk-1.3.x-r9285-orig/FL/glut.H	2011-07-18 23:49:30.000000000 -0500
+++ fltk-1.3.x-r9285/FL/glut.H	2012-03-22 10:54:43.867253938 -0500
@@ -233,7 +233,7 @@
 
 // Warning: this cast may not work on all machines:
 inline void glutTimerFunc(unsigned int msec, void (*f)(int), int value) {
-  Fl::add_timeout(msec*.001, (void (*)(void *))f, (void *)value);
+  Fl::add_timeout(msec*.001, (void (*)(void *))f, (void *)(fl_intptr_t)value);
 }
 
 inline void glutMenuStateFunc(void (*f)(int state)) {
diff -ur fltk-1.3.x-r9285-orig/fluid/Fl_Menu_Type.cxx fltk-1.3.x-r9285/fluid/Fl_Menu_Type.cxx
--- fltk-1.3.x-r9285-orig/fluid/Fl_Menu_Type.cxx	2011-09-28 15:43:05.000000000 -0500
+++ fltk-1.3.x-r9285/fluid/Fl_Menu_Type.cxx	2012-03-22 10:22:19.686639182 -0500
@@ -281,14 +281,14 @@
 
 void Fl_Menu_Item_Type::write_item() {
   static const char * const labeltypes[] = {
-    "FL_NORMAL_LABEL",
-    "FL_NO_LABEL",
-    "FL_SHADOW_LABEL",
-    "FL_ENGRAVED_LABEL",
-    "FL_EMBOSSED_LABEL",
-    "FL_MULTI_LABEL",
-    "FL_ICON_LABEL",
-    "FL_IMAGE_LABEL"
+    "(uchar)FL_NORMAL_LABEL",
+    "(uchar)FL_NO_LABEL",
+    "(uchar)FL_SHADOW_LABEL",
+    "(uchar)FL_ENGRAVED_LABEL",
+    "(uchar)FL_EMBOSSED_LABEL",
+    "(uchar)FL_MULTI_LABEL",
+    "(uchar)FL_ICON_LABEL",
+    "(uchar)FL_IMAGE_LABEL"
   };
 
   write_c(" {");
diff -ur fltk-1.3.x-r9285-orig/src/Fl_Color_Chooser.cxx fltk-1.3.x-r9285/src/Fl_Color_Chooser.cxx
--- fltk-1.3.x-r9285-orig/src/Fl_Color_Chooser.cxx	2011-07-18 23:49:30.000000000 -0500
+++ fltk-1.3.x-r9285/src/Fl_Color_Chooser.cxx	2012-03-22 09:52:52.272597439 -0500
@@ -251,7 +251,7 @@
   for (int x = X; x < X+W; x++) {
     double Xf = double(x)/iw;
     double H,S; tohs(Xf,Yf,H,S);
-    double r,g,b;
+    double r = 0, g = 0, b = 0;
     Fl_Color_Chooser::hsv2rgb(H,S,V,r,g,b);
     *buf++ = uchar(255*r+.5);
     *buf++ = uchar(255*g+.5);
diff -ur fltk-1.3.x-r9285-orig/src/Fl_Preferences.cxx fltk-1.3.x-r9285/src/Fl_Preferences.cxx
--- fltk-1.3.x-r9285-orig/src/Fl_Preferences.cxx	2012-01-18 05:39:57.000000000 -0600
+++ fltk-1.3.x-r9285/src/Fl_Preferences.cxx	2012-03-22 09:52:52.327600824 -0500
@@ -1317,7 +1317,7 @@
 	for ( cnt = 0; cnt < 80; cnt++ )
 	  if ( src[cnt]==0 ) break;
         fputc( '+', f );
-	written = fwrite( src, cnt, 1, f );
+	written += fwrite( src, cnt, 1, f );
         fputc( '\n', f );
 	src += cnt;
       }
diff -ur fltk-1.3.x-r9285-orig/src/Fl_Text_Display.cxx fltk-1.3.x-r9285/src/Fl_Text_Display.cxx
--- fltk-1.3.x-r9285-orig/src/Fl_Text_Display.cxx	2011-10-18 17:18:39.000000000 -0500
+++ fltk-1.3.x-r9285/src/Fl_Text_Display.cxx	2012-03-22 09:52:52.393604887 -0500
@@ -3468,7 +3468,7 @@
                  text_area.w+LEFT_MARGIN+RIGHT_MARGIN,
                  text_area.h);
 
-    int X, Y;
+    int X = 0, Y = 0;
     if (position_to_xy(mCursorPos, &X, &Y)) draw_cursor(X, Y);
     //    else puts("position_to_xy() failed - unable to draw cursor!");
     //printf("drew cursor at pos: %d (%d,%d)\n", mCursorPos, X, Y);
diff -ur fltk-1.3.x-r9285-orig/src/fl_ask.cxx fltk-1.3.x-r9285/src/fl_ask.cxx
--- fltk-1.3.x-r9285-orig/src/fl_ask.cxx	2011-09-27 22:39:23.000000000 -0500
+++ fltk-1.3.x-r9285/src/fl_ask.cxx	2012-03-22 10:55:45.902715613 -0500
@@ -98,7 +98,7 @@
    else
      button[b] = new Fl_Button(x, 70, 90, 23);
    button[b]->align(FL_ALIGN_INSIDE|FL_ALIGN_WRAP);
-   button[b]->callback(button_cb,(void *)b);
+   button[b]->callback(button_cb,(void *)(fl_intptr_t)b);
  }
  button[0]->shortcut(FL_Escape);
  // add the buttons (left to right)
diff -ur fltk-1.3.x-r9285-orig/src/fl_dnd_win32.cxx fltk-1.3.x-r9285/src/fl_dnd_win32.cxx
--- fltk-1.3.x-r9285-orig/src/fl_dnd_win32.cxx	2011-07-18 23:49:30.000000000 -0500
+++ fltk-1.3.x-r9285/src/fl_dnd_win32.cxx	2012-03-22 09:52:44.538121425 -0500
@@ -59,6 +59,7 @@
   int px, py;
 public:
   FLDropTarget() : m_cRefCount(0) { } // initialize
+  virtual ~FLDropTarget() { }
   HRESULT STDMETHODCALLTYPE QueryInterface( REFIID riid, LPVOID *ppvObject ) {
     if (IID_IUnknown==riid || IID_IDropTarget==riid)
     {
@@ -314,6 +315,7 @@
   DWORD m_cRefCount;
 public:
   FLDropSource() { m_cRefCount = 0; }
+  virtual ~FLDropSource() { }
   HRESULT STDMETHODCALLTYPE QueryInterface( REFIID riid, LPVOID *ppvObject ) {
     if (IID_IUnknown==riid || IID_IDropSource==riid)
     {
@@ -424,6 +426,7 @@
   FLEnum *m_EnumF;
 public:
   FLDataObject() { m_cRefCount = 1; }// m_EnumF = new FLEnum();}
+  virtual ~FLDataObject() { }
   HRESULT STDMETHODCALLTYPE QueryInterface( REFIID riid, LPVOID *ppvObject ) {
     if (IID_IUnknown==riid || IID_IDataObject==riid)
     {
diff -ur fltk-1.3.x-r9285-orig/src/fl_draw_image_win32.cxx fltk-1.3.x-r9285/src/fl_draw_image_win32.cxx
--- fltk-1.3.x-r9285-orig/src/fl_draw_image_win32.cxx	2011-07-18 23:49:30.000000000 -0500
+++ fltk-1.3.x-r9285/src/fl_draw_image_win32.cxx	2012-03-22 10:38:44.961918781 -0500
@@ -143,11 +143,12 @@
   } else
 #endif
   if (depth<3) {
+    RGBQUAD *colors = bmi.bmiColors;
     for (int i=0; i<256; i++) {
-      bmi.bmiColors[i].rgbBlue = (uchar)i;
-      bmi.bmiColors[i].rgbGreen = (uchar)i;
-      bmi.bmiColors[i].rgbRed = (uchar)i;
-      bmi.bmiColors[i].rgbReserved = (uchar)0; // must be zero
+      colors[i].rgbBlue = (uchar)i;
+      colors[i].rgbGreen = (uchar)i;
+      colors[i].rgbRed = (uchar)i;
+      colors[i].rgbReserved = (uchar)0; // must be zero
     }
   }
   bmi.bmiHeader.biWidth = w;
diff -ur fltk-1.3.x-r9285-orig/src/glut_compatability.cxx fltk-1.3.x-r9285/src/glut_compatability.cxx
--- fltk-1.3.x-r9285-orig/src/glut_compatability.cxx	2011-07-18 23:49:30.000000000 -0500
+++ fltk-1.3.x-r9285/src/glut_compatability.cxx	2012-03-22 10:54:43.748249304 -0500
@@ -333,7 +333,7 @@
   Fl_Menu_Item* i = additem(m);
   i->text = label;
   i->callback_ = (Fl_Callback*)(m->cb);
-  i->user_data_ = (void *)value;
+  i->user_data_ = (void *)(fl_intptr_t)value;
 }
 
 void glutAddSubMenu(char *label, int submenu) {
@@ -350,7 +350,7 @@
   Fl_Menu_Item* i = &m->m[item-1];
   i->text = label;
   i->callback_ = (Fl_Callback*)(m->cb);
-  i->user_data_ = (void *)value;
+  i->user_data_ = (void *)(fl_intptr_t)value;
   i->flags = 0;
 }
 
diff -ur fltk-1.3.x-r9285-orig/test/arc.cxx fltk-1.3.x-r9285/test/arc.cxx
--- fltk-1.3.x-r9285-orig/test/arc.cxx	2011-07-18 23:49:30.000000000 -0500
+++ fltk-1.3.x-r9285/test/arc.cxx	2012-03-22 10:57:53.122119546 -0500
@@ -75,7 +75,7 @@
     s->step(1);
     s->value(args[n]);
     s->align(FL_ALIGN_LEFT);
-    s->callback(slider_cb, (void*)n);
+    s->callback(slider_cb, (void*)(fl_intptr_t)n);
   }
 
   window.end();
diff -ur fltk-1.3.x-r9285-orig/test/curve.cxx fltk-1.3.x-r9285/test/curve.cxx
--- fltk-1.3.x-r9285-orig/test/curve.cxx	2011-07-18 23:49:30.000000000 -0500
+++ fltk-1.3.x-r9285/test/curve.cxx	2012-03-22 10:57:44.734749706 -0500
@@ -91,7 +91,7 @@
     s->step(1);
     s->value(args[n]);
     s->align(FL_ALIGN_LEFT);
-    s->callback(slider_cb, (void*)n);
+    s->callback(slider_cb, (void*)(fl_intptr_t)n);
   }
   Fl_Toggle_Button but(50,y,50,25,"points");
   but.callback(points_cb);
diff -ur fltk-1.3.x-r9285-orig/test/forms.cxx fltk-1.3.x-r9285/test/forms.cxx
--- fltk-1.3.x-r9285-orig/test/forms.cxx	2011-07-18 23:49:30.000000000 -0500
+++ fltk-1.3.x-r9285/test/forms.cxx	2012-03-22 10:19:22.854142701 -0500
@@ -38,26 +38,26 @@
 
 static VN_struct btypes[]=
 {
-   {FL_NO_BOX,"no box"},
-   {FL_UP_BOX, "up box"},
-   {FL_DOWN_BOX,"down box"},
-   {FL_BORDER_BOX,"border box"},
-   {FL_SHADOW_BOX,"shadow box"},
-   {FL_FLAT_BOX,"flat box"},
-   {FL_FRAME_BOX,"frame box"},
-   {FL_EMBOSSED_BOX,"embossed box"},
-   {FL_ROUNDED_BOX,"rounded box"},
-   {FL_RFLAT_BOX,"rflat box"},
-   {FL_RSHADOW_BOX,"rshadow box"}, // renamed for fltk
-   {FL_OVAL_BOX,"oval box"},
-   {FL_ROUNDED3D_UPBOX,"rounded3d upbox"},
-   {FL_ROUNDED3D_DOWNBOX,"rounded3d downbox"},
-   {FL_OVAL3D_UPBOX,"oval3d upbox"},
-   {FL_OVAL3D_DOWNBOX,"oval3d downbox"},
-   {FL_PLASTIC_UP_BOX,"plastic upbox"},
-   {FL_PLASTIC_DOWN_BOX,"plastic downbox"},
-   {FL_GTK_UP_BOX,"GTK up box"},
-   {FL_GTK_ROUND_UP_BOX,"GTK round up box"},
+   {(int)FL_NO_BOX,"no box"},
+   {(int)FL_UP_BOX, "up box"},
+   {(int)FL_DOWN_BOX,"down box"},
+   {(int)FL_BORDER_BOX,"border box"},
+   {(int)FL_SHADOW_BOX,"shadow box"},
+   {(int)FL_FLAT_BOX,"flat box"},
+   {(int)FL_FRAME_BOX,"frame box"},
+   {(int)FL_EMBOSSED_BOX,"embossed box"},
+   {(int)FL_ROUNDED_BOX,"rounded box"},
+   {(int)FL_RFLAT_BOX,"rflat box"},
+   {(int)FL_RSHADOW_BOX,"rshadow box"}, // renamed for fltk
+   {(int)FL_OVAL_BOX,"oval box"},
+   {(int)FL_ROUNDED3D_UPBOX,"rounded3d upbox"},
+   {(int)FL_ROUNDED3D_DOWNBOX,"rounded3d downbox"},
+   {(int)FL_OVAL3D_UPBOX,"oval3d upbox"},
+   {(int)FL_OVAL3D_DOWNBOX,"oval3d downbox"},
+   {(int)FL_PLASTIC_UP_BOX,"plastic upbox"},
+   {(int)FL_PLASTIC_DOWN_BOX,"plastic downbox"},
+   {(int)FL_GTK_UP_BOX,"GTK up box"},
+   {(int)FL_GTK_ROUND_UP_BOX,"GTK round up box"},
    /* sentinel */
    {-1}
 };
diff -ur fltk-1.3.x-r9285-orig/test/menubar.cxx fltk-1.3.x-r9285/test/menubar.cxx
--- fltk-1.3.x-r9285-orig/test/menubar.cxx	2012-02-18 02:29:30.000000000 -0600
+++ fltk-1.3.x-r9285/test/menubar.cxx	2012-03-22 10:17:41.625755259 -0500
@@ -127,10 +127,10 @@
     {"Italic",	0, 0, 0, 0, 0, FL_ITALIC, 14},
     {"BoldItalic",0,0,0, 0, 0, FL_BOLD+FL_ITALIC, 14},
     {"Small",	0, 0, 0, 0, 0, FL_BOLD+FL_ITALIC, 10},
-    {"Emboss",	0, 0, 0, 0, FL_EMBOSSED_LABEL},
-    {"Engrave",	0, 0, 0, 0, FL_ENGRAVED_LABEL},
-    {"Shadow",	0, 0, 0, 0, FL_SHADOW_LABEL},
-    {"@->",	0, 0, 0, 0, FL_SYMBOL_LABEL},
+    {"Emboss",	0, 0, 0, 0, (uchar)FL_EMBOSSED_LABEL},
+    {"Engrave",	0, 0, 0, 0, (uchar)FL_ENGRAVED_LABEL},
+    {"Shadow",	0, 0, 0, 0, (uchar)FL_SHADOW_LABEL},
+    {"@->",	0, 0, 0, 0, (uchar)FL_SYMBOL_LABEL},
     {0},
   {"&International",0,0,0,FL_SUBMENU},
     {"Sharp Ess",0x0000df},
