<html><div style='background-color:'><DIV>
<P><BR>Hai Pinky,</P>
<P>I have tried to compile the examples using Visual studio 6.0 I was able to compile all the examples. The common thing you should remember to do for the examples is:</P>
<P>1) In project -> Settings -> C/C++ : add /TP in Project Options<BR>2) In project -> Settings -> C/C++->c++ language : check enable RTTI box<BR>3)In project->settings->link : add ga.lib (or the library you have generated) in object/ library modules<BR>4) In tools-> options->directories : choose Include files and include the path where your header files can be found. example: c:/galib245/ga and/or c:/galib245<BR>5) IN tools->options->directoreis: choose libraries and include the directory(path) where your ga library is located ex: if you ga.lib is found in ga directory the u should iunclude c:/galib245/ga.<BR>6) In the examples instead of <iostream.h> i.e. old std header files include the new ones llike <iostream>, <fstream>, <string>. However <math.h> and <stdlib.h> should be left as such.<BR><BR>now i think it should work.</P>
<P>regards</P>
<P>chandy</P>
<P> </P></DIV>
<DIV></DIV>
<DIV></DIV>>From: Pinky "ΊΡ" <PINKYLIU@YAHOO.COM>
<DIV></DIV>>To: galib@mit.edu
<DIV></DIV>>Subject: Compilation Error --- binary '<<'
<DIV></DIV>>Date: Thu, 13 Feb 2003 07:50:21 -0800 (PST)
<DIV></DIV>>
<DIV></DIV>>Hi,
<DIV></DIV>>
<DIV></DIV>>When I tried to compile the sample exercise, there are
<DIV></DIV>>error as below:
<DIV></DIV>>
<DIV></DIV>>ex1.c(71) : error C2679: binary '<<' : no operator
<DIV></DIV>>defined which takes a right-hand operand of type
<DIV></DIV>>'const class GAGenome' (or there is no acceptable
<DIV></DIV>>conversion)
<DIV></DIV>>Error executing cl.exe.
<DIV></DIV>>
<DIV></DIV>>The error occurs on the cout statement,
<DIV></DIV>>eg. cout << "The GA found:\n" <<
<DIV></DIV>>ga.statistics().bestIndividual() << "\n";
<DIV></DIV>>
<DIV></DIV>>I have tried to add "#define NO_STREAMS" in
<DIV></DIV>>gaconfig.h, but it still have this error.
<DIV></DIV>>
<DIV></DIV>>Can you help me?
<DIV></DIV>>
<DIV></DIV>>Pinky Liu
<DIV></DIV>>
<DIV></DIV>>__________________________________________________
<DIV></DIV>>Do you Yahoo!?
<DIV></DIV>>Yahoo! Shopping - Send Flowers for Valentine's Day
<DIV></DIV>>http://shopping.yahoo.com
<DIV></DIV>>_______________________________________________
<DIV></DIV>>galib mailing list
<DIV></DIV>>galib@mit.edu
<DIV></DIV>>http://lancet.mit.edu/mailman/listinfo/galib
<DIV></DIV></div><br clear=all><hr>Add photos to your messages with <a href="http://g.msn.com/8HMJENUS/2749">MSN 8. </a> Get 2 months FREE*.</html>