Hi Ted,<div><br></div><div>I'll give that a go, hopefully that works.</div><div><br></div><div>I actually tried VS2010 first - but hit a different problem altogether. I'll give it another go...</div><div><br></div>
<div>Downloading clean from the SVN, release/2.7.0, opening the /v10/ version, then building cbcExamplesSample2:</div><blockquote class="webkit-indent-blockquote" style="margin: 0 0 0 40px; border: none; padding: 0px;"><div>
<div>3>------ Build started: Project: cbcExamplesSample2, Configuration: Debug Win32 ------</div></div><div><div>3> CbcLinked.cpp</div></div><div><div>3>c:\coin\cbc\cbc\src\CbcLinked.hpp(29): error C2504: 'CbcOsiSolver' : base class undefined</div>
</div></blockquote><div><br></div><div>Which I fixed by adding CBC_BUILD to the preprocessor directives.</div><div>But then it seems to almost get to the end, before saying:</div><blockquote class="webkit-indent-blockquote" style="margin: 0 0 0 40px; border: none; padding: 0px;">
<div><div>7> Generating Code...</div></div><div><div>7>LINK : fatal error LNK1181: cannot open input file 'libCoinUtils.lib'</div></div></blockquote><div><br></div><div>Which I fixed by making "MSVisualStudio\v10\Win32\Debug" an additional library directory. It then runs fine.</div>
<div><br></div><div>Trying to build the cbc project:</div><blockquote class="webkit-indent-blockquote" style="margin: 0 0 0 40px; border: none; padding: 0px;"><div><div>4>------ Build started: Project: cbc, Configuration: Debug Win32 ------</div>
</div><div><div>4> CoinSolve.cpp</div></div><div><div>4>LINK : fatal error LNK1181: cannot open input file 'libCgl.lib'</div></div></blockquote><div><br></div><div>Which I again fixed by adding that directory. It then builds.</div>
<div><br></div><div>I did some more digging around in the options, and I think the issue is this:</div><div>Some projects output to $(SolutionDir)$(Platform)\$(Configuration)\</div><div>Other projects output to $(SolutionDir)$(Configuration)\</div>
<div><br>If I standardise to the $(Platform)\ version, it all works fine (for cbc, still need to add CBC_BUILD to get cbcExamplesSample2 working).</div><div><br></div><div>Are you able to use TortoiseSVN-generated patches? Or do you just want to fix it yourself?</div>
<div><br></div><div>Cheers,</div><div>Iain</div><div><br></div><div><br><div class="gmail_quote">On 21 July 2011 16:41, Ted Ralphs <span dir="ltr"><<a href="mailto:ted@lehigh.edu">ted@lehigh.edu</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">Hi Iain,<br>
<br>
The 2008 project files are surely out of date---I just spent several<br>
days working out the bugs in the new 2010 files and those should work<br>
fine. If possible, I would suggest you just download MSVC++ Express<br>
2010 and use that, as I'm not too keen on more wrestling with MSVC++<br>
anytime soon :). If you can't do that, I can tell you that most of the<br>
errors you are seeing will be corrected if you add<br>
<br>
XXX_BUILD<br>
<br>
to the list of preprocessor symbols defined, where "XXX" is the<br>
project acronym (in all caps). This is necessary under the new system<br>
we have adopted for configuration header files, which is used in the<br>
latest releases of COIN projects. Even for the projects that are not<br>
currently broken, you should add that symbol, as they may otherwise<br>
break in future releases. That should fix most things. If there are<br>
still errors, post another message. Also, if you want to contribute<br>
the repaired files, that would be great.<br>
<br>
Cheers,<br>
<br>
Ted<br>
<div><div></div><div class="h5"><br>
On Wed, Jul 20, 2011 at 11:59 PM, Iain Dunning <<a href="mailto:iaindunning@gmail.com">iaindunning@gmail.com</a>> wrote:<br>
> Hi,<br>
> I'm having a lot of trouble trying to build CBC with Visual Studio 2008.<br>
> This happens in 2.7 stable, 2.7.0 release, and trunk.<br>
> What I want to do is build "cbc.exe", but at the moment I'm just trying to<br>
> build the default project, cbcExamplesSample2<br>
><br>
> The errors I hit are many and varied...<br>
> I suspect some are pre-processor related, others seem more problematic.<br>
> 1. Project libOsi - all fine<br>
> 2. Project libClp<br>
> c:\coin\cbc\clp\src\clphelperfunctions.hpp(16) : fatal error C1189: #error :<br>
> "don't have header file for math"<br>
> Happens a few times.<br>
> 3. Project libCoinUtils<br>
> c:\coin\cbc\clp\src\clphelperfunctions.hpp(16) : fatal error C1189: #error :<br>
> "don't have header file for math"<br>
> 4. Project libOsiClp - all fine<br>
> 5. Project libCbcSolver<br>
> ..\..\..\src\unitTestClp.cpp(584) : error C2039: 'fastNodeDepth' : is not a<br>
> member of 'CbcModel'<br>
> c:\coin\cbc\cbc\src\CbcModel.hpp(99) : see declaration of 'CbcModel'<br>
> ..\..\..\src\unitTestClp.cpp(585) : error C2039: 'setFastNodeDepth' : is not<br>
> a member of 'CbcModel'<br>
> c:\coin\cbc\cbc\src\CbcModel.hpp(99) : see declaration of 'CbcModel'<br>
> c:\coin\cbc\cbc\src\CbcLinked.hpp(29) : error C2504: 'CbcOsiSolver' : base<br>
> class undefined<br>
> Then a lot of errors follow on from this.<br>
> 7. Project libCgl<br>
> c:\coin\cbc\cbc\src\cbcheuristic.cpp(539) : error C2039:<br>
> 'continuousPriority' : is not a member of 'CbcModel<br>
> c:\coin\cbc\cbc\src\cbcheuristic.cpp(906) : error C2039: 'setFastNodeDepth'<br>
> : is not a member of 'CbcModel'<br>
> c:\coin\cbc\cbc\src\cbcheuristic.cpp(1163) : error C2039: 'setFastNodeDepth'<br>
> : is not a member of 'CbcModel'<br>
> c:\coin\cbc\cbc\src\cbcheuristic.cpp(1164) : error C2039: 'fastNodeDepth' :<br>
> is not a member of 'CbcModel'<br>
> There seems to be issues in the "test" projects, but I don't need those.<br>
> Any idea about how I fix these issues?<br>
> Cheers,<br>
> Iain<br>
</div></div>> _______________________________________________<br>
> Cbc mailing list<br>
> <a href="mailto:Cbc@list.coin-or.org">Cbc@list.coin-or.org</a><br>
> <a href="http://list.coin-or.org/mailman/listinfo/cbc" target="_blank">http://list.coin-or.org/mailman/listinfo/cbc</a><br>
><br>
><br>
<font color="#888888"><br>
<br>
<br>
--<br>
Dr. Ted Ralphs<br>
Associate Professor, Lehigh University<br>
(610) 628-1280<br>
ted 'at' lehigh 'dot' edu<br>
<a href="http://coral.ie.lehigh.edu/~ted" target="_blank">coral.ie.lehigh.edu/~ted</a><br>
</font></blockquote></div><br><br clear="all"><br>-- <br><font face="'courier new', monospace">Iain Dunning</font><br><font face="'courier new', monospace">Email: <a href="mailto:iaindunning@gmail.com" target="_blank">iaindunning@gmail.com</a><br>
Web: <a href="http://www.iaindunning.com/" target="_blank">www.iaindunning.com</a><br></font><div><font face="'courier new', monospace">LinkedIn: <span style="font-size:13px;line-height:15px;background-color:rgb(255, 255, 255)"><a href="http://nz.linkedin.com/in/iaindunning" target="_blank">nz.linkedin.com/in/iaindunning</a></span></font></div>
<br>
</div>