As a slight addition: first, our thanks to Jan Kelbel, for helping us to reproduce and analyze the bug.
Then, in 3.0 Gecode will use auto-linking with MSVC: so it is sufficient to give the library directory. The respective libraries will be found automatically by the linker. Christian -- Christian Schulte, www.ict.kth.se/~cschulte/ -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Guido Tack Sent: Tuesday, September 02, 2008 4:46 PM To: gecode users list Subject: [gecode-users] Linking to Gecode with Microsoft Visual C++ Hi everyone! We had a bit of trouble trying to link to the binary Gecode distribution from a Microsoft Visual Studio C++ project. First of all, here's what you have to set up in the properties dialog of your "Solution": * Configuration Properties, C++, General, set the Additional Include Directories to <Program Files>\Gecode * Configuration Properties, Linker, General, set the Additional Library Directories to <Program Files>\Gecode\lib * Configuration Properties, Linker, Input, set the Additional Dependencies to GecodeSupport.lib GecodeKernel.lib GecodeSearch.lib etc. (all the Gecode libraries that you want to link against) That should do the trick, except that only a release build works properly at the moment. If you build your project using a Debug configuration instead, your program will crash with "bad alloc" errors. Apparently, inlining doesn't work too well when linking against different libraries (i.e., linking Gecode with /MD while linking your program with /MDd). So, for the time being, you will have to compile your program as a Release build, or compile your own version of Gecode with debug turned on. We're looking into this issue, and we'll try to produce (optimized) libraries that can be used in a Debug build for the next version of Gecode. Cheers, Guido _______________________________________________ Gecode users mailing list [EMAIL PROTECTED] https://www.gecode.org/mailman/listinfo/gecode-users _______________________________________________ Gecode users mailing list [EMAIL PROTECTED] https://www.gecode.org/mailman/listinfo/gecode-users