[gecode-users] How to compile the examples in Xcode

Guido Tack tack at ps.uni-sb.de
Mon May 18 02:01:10 CEST 2009


serge lemouton wrote:
> I am not able to compile the examples included from the Gecode 3.0.2
> Macintosh binary distribution.
> I have installed Gecode with the "Install Gecode 3.0.2.pkg", (after
> having desinstalled the oldest frameworks with the uninstall script)
> created an Xcode project with the latest version of Xcode and GCC 4.2
> (and put the "-framework gecode" option in the Linker Flags)
> When  compiling any examples in the "C++ examples" folder of the disk
> image, I get the following errors :
>
> collect2: ld returned 1 exit status
> symbol(s) not found
> __ZTV7Options$non_lazy_ptr in money.o
> "vtable for Options", referenced from:
> Options::~Options()in money.o
> etc .... (all the errors seems related to Options)

You have to compile and link the files examples/support/example.cpp  
and examples/support/options.cpp in addition to the actual example you  
want to try.  In the upcoming 3.1.0 release, these files have been  
moved to their own library so that this step won't be necessary any  
longer.

Cheers,
	Guido





More information about the gecode-users mailing list