Bug #10302 Fails to compile with Amd64/gcc4.0
Submitted: 1 May 2005 22:26 Modified: 2 Jun 2005 3:11
Reporter: [ name withheld ] Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Administrator Severity:S3 (Non-critical)
Version:1.0.20 OS:Linux (Linux/Debian)
Assigned to: Alfredo Kojima CPU Architecture:Any

[1 May 2005 22:26] [ name withheld ]
Description:
From: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=301844

When building 'mysql-admin' on amd64/unstable with gcc-4.0,
I get the following error:

x86_64-linux-g++ -DPACKAGE_NAME=\"\" -DPACKAGE_TARNAME=\"\" -DPACKAGE_VERSION=\"\" -DPACKAGE_STRING=\"\" -DPACKAGE_BUGREPORT=\"\" -DPACKAGE=\"mysql-gui-common\" -DVERSION=\"0.5.1\" -DGTKMM_VERSION=20000  -I. -I. -DXTHREADS -I/usr/include/libxml2 -I/usr/include/libglade-2.0 -I/usr/include/gtk-2.0 -I/usr/lib/gtk-2.0/include -I/usr/X11R6/include -I/usr/include/atk-1.0 -I/usr/include/pango-1.0 -I/usr/include/freetype2 -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include   -DXTHREADS -I/usr/include/gtkmm-2.0 -I/usr/lib/gtkmm-2.0/include -I/usr/include/gtk-2.0 -I/usr/lib/sigc++-1.2/include -I/usr/include/sigc++-1.2 -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/lib/gtk-2.0/include -I/usr/X11R6/include -I/usr/include/pango-1.0 -I/usr/include/freetype2 -I/usr/include/atk-1.0   -I/usr/include/mysql -DBIG_JOINS=1 -I../../library/include -I../../library/shared_include -DDATADIRNAME=\""share"\" -DCOMMONDIRNAME=\""administrator"\"    -g -O2 -c -o MGBlobEditor.o `test -f 'MGBlobEditor.cc' || echo './'`MGBlobEditor.cc
MGBlobEditor.cc: In member function 'virtual Gtk::TreePath MGBlobListStore::get_path_vfunc(const Gtk::TreeIter&)':
MGBlobEditor.cc:79: error: cast from 'void*' to 'int' loses precision
MGBlobEditor.cc: In member function 'virtual bool MGBlobListStore::iter_next_vfunc(GtkTreeIter*)':
MGBlobEditor.cc:89: error: cast from 'void*' to 'int' loses precision
MGBlobEditor.cc:91: error: cast from 'void*' to 'int' loses precision
MGBlobEditor.cc: In member function 'virtual void MGBlobListStore::get_value_vfunc(const Gtk::TreeIter&, int, GValue*)':
MGBlobEditor.cc:121: error: cast from 'void*' to 'unsigned int' loses precision
make[3]: *** [MGBlobEditor.o] Error 1
make[3]: Leaving directory `/mysql-admin-1.0.19/mysql-gui-common/source/linux'

How to repeat:
.

Suggested fix:
Apply attached patch..
[1 May 2005 22:27] [ name withheld ]
Patch

Attachment: gcc4.patch (text/x-patch), 4.64 KiB.

[2 May 2005 4:03] Jorge del Conde
This is similar to http://bugs.mysql.com/bug.php?id=10298
[2 Jun 2005 3:11] Alfredo Kojima
Thank you for your bug report. This issue has been committed to our
source repository of that product and will be incorporated into the
next release.

If necessary, you can access the source repository and build the latest
available version, including the bugfix, yourself. More information 
about accessing the source trees is available at
    http://www.mysql.com/doc/en/Installing_source_tree.html

Additional info:

Thanks for the patch again!