Bug #18392 myx_gc_base.cpp (myx_gc_datatypes.h) compile fails
Submitted: 21 Mar 2006 14:42 Modified: 23 Mar 2006 16:57
Reporter: John Yodsnukis (Basic Quality Contributor) Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Workbench Preview Severity:S2 (Serious)
Version:1.0.5beta svn revision 1217 OS:Linux (Linux (Gentoo on PPC))
Assigned to: Mike Lischke CPU Architecture:Any

[21 Mar 2006 14:42] John Yodsnukis
Description:
make[3]: Entering directory `wb/mysql-gui-common/library_gc/source'
if g++ -DHAVE_CONFIG_H -I. -I. -I../.. -Wall -Wsign-compare -Wno-switch -I../ftgl/include -I../include -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/libxml2   -I/usr/include/freetype2 -I../auto_arrange/include -DUSE_FONTCONFIG    -g  -MT myx_gc_base.o -MD -MP -MF ".deps/myx_gc_base.Tpo" -c -o myx_gc_base.o myx_gc_base.cpp; \
then mv -f ".deps/myx_gc_base.Tpo" ".deps/myx_gc_base.Po"; else rm -f ".deps/myx_gc_base.Tpo"; exit 1; fi
In file included from ../include/myx_gc_base.h:28,
                 from myx_gc_base.cpp:23:
../include/myx_gc_datatypes.h: In member function `tagVertex tagVertex::operator+(const tagVertex&)':
../include/myx_gc_datatypes.h:99: error: `TVertex' was not declared in this scope
../include/myx_gc_datatypes.h:99: error: expected `;' before "result"
../include/myx_gc_datatypes.h:100: error: `result' was not declared in this scope
../include/myx_gc_datatypes.h:99: warning: unused variable 'TVertex'
../include/myx_gc_datatypes.h: In member function `tagVertex tagVertex::operator-(const tagVertex&)':
../include/myx_gc_datatypes.h:108: error: `TVertex' was not declared in this scope
../include/myx_gc_datatypes.h:108: error: expected `;' before "result"
../include/myx_gc_datatypes.h:109: error: `result' was not declared in this scope
../include/myx_gc_datatypes.h:108: warning: unused variable 'TVertex'
make[3]: *** [myx_gc_base.o] Error 1
make[3]: Leaving directory `wb/mysql-gui-common/library_gc/source'

How to repeat:
svn checkout --revision 1217 http://svn.mysql.com/svnpublic/mysql-gui-common
cd ./mysql-gui-common
sh autogen.sh --enable-grt --enable-canvas --disable-java-modules
make

Suggested fix:
Index: mysql-gui-common/library_gc/include/myx_gc_datatypes.h
===================================================================
--- mysql-gui-common/library_gc/include/myx_gc_datatypes.h      (revision 1217)
+++ mysql-gui-common/library_gc/include/myx_gc_datatypes.h      (working copy)
@@ -94,9 +94,11 @@
     z = 0;
     w = 1;
   };
+
   tagVertex operator +(const tagVertex& other)
   {
-    TVertex result = other;
+//  TVertex result = other;
+    tagVertex result = other;
     result.x = other.x / other.w + x / w;
     result.y = other.y / other.w + y / w;
     result.z = other.z / other.w + z / w;
@@ -105,13 +107,15 @@
   };
   tagVertex operator -(const tagVertex& other)
   {
-    TVertex result = other;
+//  TVertex result = other;
+    tagVertex result = other;
     result.x = x / w - other.x / other.w;
     result.y = y / w - other.y / other.w;
     result.z = z / w - other.z / other.w;
     result.w = w;
     return result;
   };
+
 } TVertex;

 typedef vector<TVertex> CText;
[21 Mar 2006 16:09] Mike Lischke
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
[23 Mar 2006 16:57] John Yodsnukis
This link talks about bitkeeper?

"To obtain our most recent development source tree, first download and install the BitKeeper free client if you do not have it. The client can be obtained from http://www.bitmover.com/bk-client.shar."

The source is svn now, yes?