Re: [Rdkit-devel] "symbol(s) not found" on Mac OS X 10.7.3
Open-Source Cheminformatics and Machine Learning
Brought to you by:
glandrum
|
From: Greg L. <gre...@gm...> - 2012-08-24 04:08:43
|
Hi James, On Fri, Aug 24, 2012 at 1:24 AM, James Swetnam <jsw...@gm...> wrote: > Ironically, I just ran into this same issue with our internal gcc build > today. I've attached a patch that removes the platform-specific -O0 flag > for Dict.cpp and replaces the force_types() method with the following, which > is somewhat more C++ standard-compliant and portable: > > #define ANY_FORCE(T) template T Dict::fromany<T>(const boost::any& arg) > const; \ > template boost::any Dict::toany<T>(T arg) const; > ANY_FORCE(int); > ANY_FORCE(bool); > ANY_FORCE(unsigned int); > ANY_FORCE(double); > ANY_FORCE(std::string); > ANY_FORCE(std::vector<int>); > ANY_FORCE(std::vector<unsigned int>); > ... > etc. > > You can read up on what's going on here (it's not pretty, nothing with c++ > template programming is) here: > http://www.parashift.com/c++-faq-lite/separate-template-fn-defn-from-decl.html > > Feel free to use the patch or not. Thanks! Thanks for the patch! I checked the changes in this morning after testing on my windows build machine and an up-to-date version of linux. I'm guessing this isn't going to cause any problems with older gcc versions, but I'll verify that in the next couple days. -greg |