Re: [Rdkit-discuss] compiling error with C++ on maverick

2016-03-19 Thread Brian Kelley
One thing we could fairly easily set up is a "companion" CMakeLists.txt for
a sample C++ project that builds a test project against a built
distribution.  It could prove useful as a basis for building C++ extensions.

Basically we would hedge our bets and just link against everything :)

Cheers,
 Brian

On Wed, Mar 16, 2016 at 8:47 AM, Yingfeng Wang  wrote:

> Riccardo,
>
> Thank you very much!
>
> Yingfeng
>
> On Wed, Mar 16, 2016 at 4:08 AM, Riccardo Vianello <
> riccardo.viane...@gmail.com> wrote:
>
>> Hi Yingfeng,
>>
>> do you use cmake to build your own project? in case you did, some cmake
>> configuration files are usually installed together with the RDKit libraries
>> and may help manage these details:
>>
>> rdkit-config.cmake
>> rdkit-config-version.cmake
>> rdkit-targets.cmake
>> rdkit-targets-release.cmake
>>
>> The location of these files (matching the libraries installation path in
>> the current RDKit version) should be passed on the cmake command line:
>>
>> $ cmake -D RDKit_DIR=/rdkit/libraries/installation/path/lib [...]
>>
>> And the CMakeLists.txt script can then use the information from these
>> files to configure the build:
>>
>> find_package(RDKit REQUIRED)
>> include_directories(${RDKit_INCLUDE_DIRS})
>> [...]
>> add_library(mylibrary [...])
>> target_link_libraries(mylibrary Descriptors Fingerprints GraphMol)
>>
>> Specifying the most direct dependencies should be usually sufficient, and
>> cmake should be able to complement this information with the target
>> dependencies originally collected during the RDKit build and then tracked
>> in the configuration files.
>>
>> Best,
>> Riccardo
>>
>>
>
>
> --
> Transform Data into Opportunity.
> Accelerate data analysis in your applications with
> Intel Data Analytics Acceleration Library.
> Click to learn more.
> http://pubads.g.doubleclick.net/gampad/clk?id=278785231=/4140
> ___
> Rdkit-discuss mailing list
> Rdkit-discuss@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/rdkit-discuss
>
>
--
Transform Data into Opportunity.
Accelerate data analysis in your applications with
Intel Data Analytics Acceleration Library.
Click to learn more.
http://pubads.g.doubleclick.net/gampad/clk?id=278785231=/4140___
Rdkit-discuss mailing list
Rdkit-discuss@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/rdkit-discuss


Re: [Rdkit-discuss] compiling error with C++ on maverick

2016-03-19 Thread Yingfeng Wang
Brian,

I think this is a good idea. Basically, I want to address the following two
situations:

1) A user wants to compile my C++ source code. I want to provide my source
code and Makefile, and remind to install RDKit first (I don't think we need
to mention boost, which is required by RDKit).

2) A user wants to use the binary file of my tool. So I want to use a
CMakeList.txt to generate a Makefile, which can compile my code into a
stand alone binary file without additional installation of boost and RDKit.
I will distribute these binary files. I don't think users will be sensitive
to sizes of these binary files, if they don't need to worry about boost and
RDKit.

Thanks.

Yingfeng



On Wed, Mar 16, 2016 at 10:03 AM, Brian Kelley  wrote:

> One thing we could fairly easily set up is a "companion" CMakeLists.txt
> for a sample C++ project that builds a test project against a built
> distribution.  It could prove useful as a basis for building C++ extensions.
>
> Basically we would hedge our bets and just link against everything :)
>
> Cheers,
>  Brian
>
> On Wed, Mar 16, 2016 at 8:47 AM, Yingfeng Wang  wrote:
>
>> Riccardo,
>>
>> Thank you very much!
>>
>> Yingfeng
>>
>> On Wed, Mar 16, 2016 at 4:08 AM, Riccardo Vianello <
>> riccardo.viane...@gmail.com> wrote:
>>
>>> Hi Yingfeng,
>>>
>>> do you use cmake to build your own project? in case you did, some cmake
>>> configuration files are usually installed together with the RDKit libraries
>>> and may help manage these details:
>>>
>>> rdkit-config.cmake
>>> rdkit-config-version.cmake
>>> rdkit-targets.cmake
>>> rdkit-targets-release.cmake
>>>
>>> The location of these files (matching the libraries installation path in
>>> the current RDKit version) should be passed on the cmake command line:
>>>
>>> $ cmake -D RDKit_DIR=/rdkit/libraries/installation/path/lib [...]
>>>
>>> And the CMakeLists.txt script can then use the information from these
>>> files to configure the build:
>>>
>>> find_package(RDKit REQUIRED)
>>> include_directories(${RDKit_INCLUDE_DIRS})
>>> [...]
>>> add_library(mylibrary [...])
>>> target_link_libraries(mylibrary Descriptors Fingerprints GraphMol)
>>>
>>> Specifying the most direct dependencies should be usually sufficient,
>>> and cmake should be able to complement this information with the target
>>> dependencies originally collected during the RDKit build and then tracked
>>> in the configuration files.
>>>
>>> Best,
>>> Riccardo
>>>
>>>
>>
>>
>> --
>> Transform Data into Opportunity.
>> Accelerate data analysis in your applications with
>> Intel Data Analytics Acceleration Library.
>> Click to learn more.
>> http://pubads.g.doubleclick.net/gampad/clk?id=278785231=/4140
>> ___
>> Rdkit-discuss mailing list
>> Rdkit-discuss@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/rdkit-discuss
>>
>>
>
--
Transform Data into Opportunity.
Accelerate data analysis in your applications with
Intel Data Analytics Acceleration Library.
Click to learn more.
http://pubads.g.doubleclick.net/gampad/clk?id=278785231=/4140___
Rdkit-discuss mailing list
Rdkit-discuss@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/rdkit-discuss


Re: [Rdkit-discuss] compiling error with C++ on maverick

2016-03-19 Thread Peter S. Shenkin
Well, it's inelegant. But as my post-doc advisor, Cy Levinthal, once said,
"Elegance is for tailors".

Cheers,
-P.

On Wed, Mar 16, 2016 at 10:38 AM, Yingfeng Wang  wrote:

> Peter,
>
> Thanks. This is a PERFECT general solution to all of this kind of
> headaches!
>
> Best,
> Yingfeng
>
> On Wed, Mar 16, 2016 at 10:27 AM, Peter S. Shenkin 
> wrote:
>
>> Yes, that's exactly what I meant. I'm not sure whether this sort of thing
>> still works in our troubled times, but it's easy enough to try.
>>
>> -P.
>>
>> On Wed, Mar 16, 2016 at 8:46 AM, Yingfeng Wang 
>> wrote:
>>
>>> Peter,
>>>
>>> Thanks. Do you mean
>>>
>>> -lLibA_static -lLibB_static -lLibC_static -lLibA_static -lLibB_static
>>> -lLibC_static
>>>
>>> ?
>>>
>>> So, by this way, we don't need to worry about the order of these three
>>> libraries.
>>>
>>> Best,
>>> Yingfeng
>>>
>>> On Wed, Mar 16, 2016 at 12:36 AM, Peter S. Shenkin 
>>> wrote:
>>>
 I'm not sure how this works with modern linkers, but "back in the old
 days", you could kludge it by putting all libraries on the link line twice,
 This also resolved circular references.

 -P.

 On Wed, Mar 16, 2016 at 12:05 AM, Greg Landrum 
 wrote:

> Though that would be useful information, I'm afraid that's not
> something I've ever put together.
>
> -greg
>
>
>
> On Tue, Mar 15, 2016 at 6:26 PM, Yingfeng Wang 
> wrote:
>
>> Greg,
>>
>> Could you please give me an order of all libraries? Say, I want to
>> link all RDKit static libraries. I know most of which could be 
>> unnecessary,
>> but I just want to make my situation easy.  So, if I cannot figure out a
>> better plan, this way at least works.
>>
>> Thanks.
>> Yingfeng
>>
>> On Mon, Mar 14, 2016 at 8:16 AM, Greg Landrum > > wrote:
>>
>>>
>>>
>>> On Sat, Mar 12, 2016 at 5:00 AM, Yingfeng Wang 
>>> wrote:
>>>
 Greg,

 Thanks. Your suggestion solves my problem. I add the following part
 in my compiling command.

 -L/Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/lib
 -lRDInchiLib  -lInChi -lGraphMol -lRDGeneral

 and the complete compiling command is

 g++ -Wall -O2 -std=c++11  -I
 /Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/Code -I
 /Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/External -I
 /usr/local/Cellar/boost/1.60.0_1/include
 -L/Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/lib 
 -lRDInchiLib
 -lInChi -lGraphMol -lRDGeneral  -o MYTEST main.cpp

 Is there a way to figure out which library I should link? Actually,
 my backup plan is to link all libraries in
 /Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/lib

>>>
>>> That's one approach, but it's kind of overkill. :-)
>>> The big thing is to know which library the functionality you are
>>> calling comes from. You can generally tell this from the header files 
>>> (i.e.
>>> if you include something from "DataStructs", then you need to include 
>>> the
>>> DataStructs library). this isn't perfect because some libraries have
>>> dependencies on others, but it often works The other approach is to 
>>> look in
>>> the RDKit source code at the CMakeLists.txt file for the libraries you 
>>> are
>>> using and look to see which extra libraries they include when building 
>>> the
>>> tests.
>>>
>>> This isn't very well documented. I think this kind of documentation
>>> is tricky to generate, so I don't want to do it unless it's going to 
>>> help a
>>> large number of people, and it's not at all clear to me how many C++ 
>>> RDKit
>>> users there are.
>>>
>>> By the way, is there a way to guarantee that users using my binary
 file (e.g. MYTEST in this case) do not need to install RDKit? I tried
 -static, but it didn't work. For example, I hope a user can run MYTEST 
 on
 another Mac without RDKit.

>>>
>>> If you link against the _static version of the libraries (i.e.
>>> -lGraphMol_static instead of -lGraphMol), then you should end up with a
>>> version that doesn't require an RDKit install to run. It can be 
>>> trickier to
>>> get these commands right because on many (all?) systems, there is an 
>>> order
>>> dependency to static linkage. So since SmilesParse_static depends on
>>> GraphMol_static, GraphMol_static needs to appear *after* 
>>> SmilesParse_static
>>> in the link line.
>>>
>>> I hope this helps,
>>> -greg
>>>
>>>
>>>
>>
>
>
> 

Re: [Rdkit-discuss] compiling error with C++ on maverick

2016-03-19 Thread Yingfeng Wang
Peter,

Thanks. Do you mean

-lLibA_static -lLibB_static -lLibC_static -lLibA_static -lLibB_static
-lLibC_static

?

So, by this way, we don't need to worry about the order of these three
libraries.

Best,
Yingfeng

On Wed, Mar 16, 2016 at 12:36 AM, Peter S. Shenkin 
wrote:

> I'm not sure how this works with modern linkers, but "back in the old
> days", you could kludge it by putting all libraries on the link line twice,
> This also resolved circular references.
>
> -P.
>
> On Wed, Mar 16, 2016 at 12:05 AM, Greg Landrum 
> wrote:
>
>> Though that would be useful information, I'm afraid that's not something
>> I've ever put together.
>>
>> -greg
>>
>>
>>
>> On Tue, Mar 15, 2016 at 6:26 PM, Yingfeng Wang 
>> wrote:
>>
>>> Greg,
>>>
>>> Could you please give me an order of all libraries? Say, I want to link
>>> all RDKit static libraries. I know most of which could be unnecessary, but
>>> I just want to make my situation easy.  So, if I cannot figure out a better
>>> plan, this way at least works.
>>>
>>> Thanks.
>>> Yingfeng
>>>
>>> On Mon, Mar 14, 2016 at 8:16 AM, Greg Landrum 
>>> wrote:
>>>


 On Sat, Mar 12, 2016 at 5:00 AM, Yingfeng Wang 
 wrote:

> Greg,
>
> Thanks. Your suggestion solves my problem. I add the following part in
> my compiling command.
>
> -L/Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/lib
> -lRDInchiLib  -lInChi -lGraphMol -lRDGeneral
>
> and the complete compiling command is
>
> g++ -Wall -O2 -std=c++11  -I
> /Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/Code -I
> /Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/External -I
> /usr/local/Cellar/boost/1.60.0_1/include
> -L/Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/lib -lRDInchiLib
> -lInChi -lGraphMol -lRDGeneral  -o MYTEST main.cpp
>
> Is there a way to figure out which library I should link? Actually, my
> backup plan is to link all libraries in
> /Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/lib
>

 That's one approach, but it's kind of overkill. :-)
 The big thing is to know which library the functionality you are
 calling comes from. You can generally tell this from the header files (i.e.
 if you include something from "DataStructs", then you need to include the
 DataStructs library). this isn't perfect because some libraries have
 dependencies on others, but it often works The other approach is to look in
 the RDKit source code at the CMakeLists.txt file for the libraries you are
 using and look to see which extra libraries they include when building the
 tests.

 This isn't very well documented. I think this kind of documentation is
 tricky to generate, so I don't want to do it unless it's going to help a
 large number of people, and it's not at all clear to me how many C++ RDKit
 users there are.

 By the way, is there a way to guarantee that users using my binary file
> (e.g. MYTEST in this case) do not need to install RDKit? I tried -static,
> but it didn't work. For example, I hope a user can run MYTEST on another
> Mac without RDKit.
>

 If you link against the _static version of the libraries (i.e.
 -lGraphMol_static instead of -lGraphMol), then you should end up with a
 version that doesn't require an RDKit install to run. It can be trickier to
 get these commands right because on many (all?) systems, there is an order
 dependency to static linkage. So since SmilesParse_static depends on
 GraphMol_static, GraphMol_static needs to appear *after* SmilesParse_static
 in the link line.

 I hope this helps,
 -greg



>>>
>>
>>
>> --
>> Transform Data into Opportunity.
>> Accelerate data analysis in your applications with
>> Intel Data Analytics Acceleration Library.
>> Click to learn more.
>> http://pubads.g.doubleclick.net/gampad/clk?id=278785231=/4140
>> ___
>> Rdkit-discuss mailing list
>> Rdkit-discuss@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/rdkit-discuss
>>
>>
>
--
Transform Data into Opportunity.
Accelerate data analysis in your applications with
Intel Data Analytics Acceleration Library.
Click to learn more.
http://pubads.g.doubleclick.net/gampad/clk?id=278785231=/4140___
Rdkit-discuss mailing list
Rdkit-discuss@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/rdkit-discuss


Re: [Rdkit-discuss] compiling error with C++ on maverick

2016-03-18 Thread Peter S. Shenkin
Yes, that's exactly what I meant. I'm not sure whether this sort of thing
still works in our troubled times, but it's easy enough to try.

-P.

On Wed, Mar 16, 2016 at 8:46 AM, Yingfeng Wang  wrote:

> Peter,
>
> Thanks. Do you mean
>
> -lLibA_static -lLibB_static -lLibC_static -lLibA_static -lLibB_static
> -lLibC_static
>
> ?
>
> So, by this way, we don't need to worry about the order of these three
> libraries.
>
> Best,
> Yingfeng
>
> On Wed, Mar 16, 2016 at 12:36 AM, Peter S. Shenkin 
> wrote:
>
>> I'm not sure how this works with modern linkers, but "back in the old
>> days", you could kludge it by putting all libraries on the link line twice,
>> This also resolved circular references.
>>
>> -P.
>>
>> On Wed, Mar 16, 2016 at 12:05 AM, Greg Landrum 
>> wrote:
>>
>>> Though that would be useful information, I'm afraid that's not something
>>> I've ever put together.
>>>
>>> -greg
>>>
>>>
>>>
>>> On Tue, Mar 15, 2016 at 6:26 PM, Yingfeng Wang 
>>> wrote:
>>>
 Greg,

 Could you please give me an order of all libraries? Say, I want to link
 all RDKit static libraries. I know most of which could be unnecessary, but
 I just want to make my situation easy.  So, if I cannot figure out a better
 plan, this way at least works.

 Thanks.
 Yingfeng

 On Mon, Mar 14, 2016 at 8:16 AM, Greg Landrum 
 wrote:

>
>
> On Sat, Mar 12, 2016 at 5:00 AM, Yingfeng Wang 
> wrote:
>
>> Greg,
>>
>> Thanks. Your suggestion solves my problem. I add the following part
>> in my compiling command.
>>
>> -L/Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/lib
>> -lRDInchiLib  -lInChi -lGraphMol -lRDGeneral
>>
>> and the complete compiling command is
>>
>> g++ -Wall -O2 -std=c++11  -I
>> /Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/Code -I
>> /Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/External -I
>> /usr/local/Cellar/boost/1.60.0_1/include
>> -L/Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/lib -lRDInchiLib
>> -lInChi -lGraphMol -lRDGeneral  -o MYTEST main.cpp
>>
>> Is there a way to figure out which library I should link? Actually,
>> my backup plan is to link all libraries in
>> /Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/lib
>>
>
> That's one approach, but it's kind of overkill. :-)
> The big thing is to know which library the functionality you are
> calling comes from. You can generally tell this from the header files 
> (i.e.
> if you include something from "DataStructs", then you need to include the
> DataStructs library). this isn't perfect because some libraries have
> dependencies on others, but it often works The other approach is to look 
> in
> the RDKit source code at the CMakeLists.txt file for the libraries you are
> using and look to see which extra libraries they include when building the
> tests.
>
> This isn't very well documented. I think this kind of documentation is
> tricky to generate, so I don't want to do it unless it's going to help a
> large number of people, and it's not at all clear to me how many C++ RDKit
> users there are.
>
> By the way, is there a way to guarantee that users using my binary
>> file (e.g. MYTEST in this case) do not need to install RDKit? I tried
>> -static, but it didn't work. For example, I hope a user can run MYTEST on
>> another Mac without RDKit.
>>
>
> If you link against the _static version of the libraries (i.e.
> -lGraphMol_static instead of -lGraphMol), then you should end up with a
> version that doesn't require an RDKit install to run. It can be trickier 
> to
> get these commands right because on many (all?) systems, there is an order
> dependency to static linkage. So since SmilesParse_static depends on
> GraphMol_static, GraphMol_static needs to appear *after* 
> SmilesParse_static
> in the link line.
>
> I hope this helps,
> -greg
>
>
>

>>>
>>>
>>> --
>>> Transform Data into Opportunity.
>>> Accelerate data analysis in your applications with
>>> Intel Data Analytics Acceleration Library.
>>> Click to learn more.
>>> http://pubads.g.doubleclick.net/gampad/clk?id=278785231=/4140
>>> ___
>>> Rdkit-discuss mailing list
>>> Rdkit-discuss@lists.sourceforge.net
>>> https://lists.sourceforge.net/lists/listinfo/rdkit-discuss
>>>
>>>
>>
>
--
Transform Data into Opportunity.
Accelerate data analysis in your applications with
Intel Data Analytics Acceleration Library.
Click to learn more.

Re: [Rdkit-discuss] compiling error with C++ on maverick

2016-03-18 Thread Yingfeng Wang
Peter,

Thanks. This is a PERFECT general solution to all of this kind of headaches!

Best,
Yingfeng

On Wed, Mar 16, 2016 at 10:27 AM, Peter S. Shenkin 
wrote:

> Yes, that's exactly what I meant. I'm not sure whether this sort of thing
> still works in our troubled times, but it's easy enough to try.
>
> -P.
>
> On Wed, Mar 16, 2016 at 8:46 AM, Yingfeng Wang  wrote:
>
>> Peter,
>>
>> Thanks. Do you mean
>>
>> -lLibA_static -lLibB_static -lLibC_static -lLibA_static -lLibB_static
>> -lLibC_static
>>
>> ?
>>
>> So, by this way, we don't need to worry about the order of these three
>> libraries.
>>
>> Best,
>> Yingfeng
>>
>> On Wed, Mar 16, 2016 at 12:36 AM, Peter S. Shenkin 
>> wrote:
>>
>>> I'm not sure how this works with modern linkers, but "back in the old
>>> days", you could kludge it by putting all libraries on the link line twice,
>>> This also resolved circular references.
>>>
>>> -P.
>>>
>>> On Wed, Mar 16, 2016 at 12:05 AM, Greg Landrum 
>>> wrote:
>>>
 Though that would be useful information, I'm afraid that's not
 something I've ever put together.

 -greg



 On Tue, Mar 15, 2016 at 6:26 PM, Yingfeng Wang 
 wrote:

> Greg,
>
> Could you please give me an order of all libraries? Say, I want to
> link all RDKit static libraries. I know most of which could be 
> unnecessary,
> but I just want to make my situation easy.  So, if I cannot figure out a
> better plan, this way at least works.
>
> Thanks.
> Yingfeng
>
> On Mon, Mar 14, 2016 at 8:16 AM, Greg Landrum 
> wrote:
>
>>
>>
>> On Sat, Mar 12, 2016 at 5:00 AM, Yingfeng Wang 
>> wrote:
>>
>>> Greg,
>>>
>>> Thanks. Your suggestion solves my problem. I add the following part
>>> in my compiling command.
>>>
>>> -L/Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/lib
>>> -lRDInchiLib  -lInChi -lGraphMol -lRDGeneral
>>>
>>> and the complete compiling command is
>>>
>>> g++ -Wall -O2 -std=c++11  -I
>>> /Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/Code -I
>>> /Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/External -I
>>> /usr/local/Cellar/boost/1.60.0_1/include
>>> -L/Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/lib 
>>> -lRDInchiLib
>>> -lInChi -lGraphMol -lRDGeneral  -o MYTEST main.cpp
>>>
>>> Is there a way to figure out which library I should link? Actually,
>>> my backup plan is to link all libraries in
>>> /Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/lib
>>>
>>
>> That's one approach, but it's kind of overkill. :-)
>> The big thing is to know which library the functionality you are
>> calling comes from. You can generally tell this from the header files 
>> (i.e.
>> if you include something from "DataStructs", then you need to include the
>> DataStructs library). this isn't perfect because some libraries have
>> dependencies on others, but it often works The other approach is to look 
>> in
>> the RDKit source code at the CMakeLists.txt file for the libraries you 
>> are
>> using and look to see which extra libraries they include when building 
>> the
>> tests.
>>
>> This isn't very well documented. I think this kind of documentation
>> is tricky to generate, so I don't want to do it unless it's going to 
>> help a
>> large number of people, and it's not at all clear to me how many C++ 
>> RDKit
>> users there are.
>>
>> By the way, is there a way to guarantee that users using my binary
>>> file (e.g. MYTEST in this case) do not need to install RDKit? I tried
>>> -static, but it didn't work. For example, I hope a user can run MYTEST 
>>> on
>>> another Mac without RDKit.
>>>
>>
>> If you link against the _static version of the libraries (i.e.
>> -lGraphMol_static instead of -lGraphMol), then you should end up with a
>> version that doesn't require an RDKit install to run. It can be trickier 
>> to
>> get these commands right because on many (all?) systems, there is an 
>> order
>> dependency to static linkage. So since SmilesParse_static depends on
>> GraphMol_static, GraphMol_static needs to appear *after* 
>> SmilesParse_static
>> in the link line.
>>
>> I hope this helps,
>> -greg
>>
>>
>>
>


 --
 Transform Data into Opportunity.
 Accelerate data analysis in your applications with
 Intel Data Analytics Acceleration Library.
 Click to learn more.
 http://pubads.g.doubleclick.net/gampad/clk?id=278785231=/4140
 ___
 

Re: [Rdkit-discuss] compiling error with C++ on maverick

2016-03-16 Thread Riccardo Vianello
Hi Yingfeng,

do you use cmake to build your own project? in case you did, some cmake
configuration files are usually installed together with the RDKit libraries
and may help manage these details:

rdkit-config.cmake
rdkit-config-version.cmake
rdkit-targets.cmake
rdkit-targets-release.cmake

The location of these files (matching the libraries installation path in
the current RDKit version) should be passed on the cmake command line:

$ cmake -D RDKit_DIR=/rdkit/libraries/installation/path/lib [...]

And the CMakeLists.txt script can then use the information from these files
to configure the build:

find_package(RDKit REQUIRED)
include_directories(${RDKit_INCLUDE_DIRS})
[...]
add_library(mylibrary [...])
target_link_libraries(mylibrary Descriptors Fingerprints GraphMol)

Specifying the most direct dependencies should be usually sufficient, and
cmake should be able to complement this information with the target
dependencies originally collected during the RDKit build and then tracked
in the configuration files.

Best,
Riccardo
--
Transform Data into Opportunity.
Accelerate data analysis in your applications with
Intel Data Analytics Acceleration Library.
Click to learn more.
http://pubads.g.doubleclick.net/gampad/clk?id=278785231=/4140___
Rdkit-discuss mailing list
Rdkit-discuss@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/rdkit-discuss


Re: [Rdkit-discuss] compiling error with C++ on maverick

2016-03-15 Thread Peter S. Shenkin
I'm not sure how this works with modern linkers, but "back in the old
days", you could kludge it by putting all libraries on the link line twice,
This also resolved circular references.

-P.

On Wed, Mar 16, 2016 at 12:05 AM, Greg Landrum 
wrote:

> Though that would be useful information, I'm afraid that's not something
> I've ever put together.
>
> -greg
>
>
>
> On Tue, Mar 15, 2016 at 6:26 PM, Yingfeng Wang  wrote:
>
>> Greg,
>>
>> Could you please give me an order of all libraries? Say, I want to link
>> all RDKit static libraries. I know most of which could be unnecessary, but
>> I just want to make my situation easy.  So, if I cannot figure out a better
>> plan, this way at least works.
>>
>> Thanks.
>> Yingfeng
>>
>> On Mon, Mar 14, 2016 at 8:16 AM, Greg Landrum 
>> wrote:
>>
>>>
>>>
>>> On Sat, Mar 12, 2016 at 5:00 AM, Yingfeng Wang 
>>> wrote:
>>>
 Greg,

 Thanks. Your suggestion solves my problem. I add the following part in
 my compiling command.

 -L/Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/lib
 -lRDInchiLib  -lInChi -lGraphMol -lRDGeneral

 and the complete compiling command is

 g++ -Wall -O2 -std=c++11  -I
 /Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/Code -I
 /Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/External -I
 /usr/local/Cellar/boost/1.60.0_1/include
 -L/Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/lib -lRDInchiLib
 -lInChi -lGraphMol -lRDGeneral  -o MYTEST main.cpp

 Is there a way to figure out which library I should link? Actually, my
 backup plan is to link all libraries in
 /Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/lib

>>>
>>> That's one approach, but it's kind of overkill. :-)
>>> The big thing is to know which library the functionality you are calling
>>> comes from. You can generally tell this from the header files (i.e. if you
>>> include something from "DataStructs", then you need to include the
>>> DataStructs library). this isn't perfect because some libraries have
>>> dependencies on others, but it often works The other approach is to look in
>>> the RDKit source code at the CMakeLists.txt file for the libraries you are
>>> using and look to see which extra libraries they include when building the
>>> tests.
>>>
>>> This isn't very well documented. I think this kind of documentation is
>>> tricky to generate, so I don't want to do it unless it's going to help a
>>> large number of people, and it's not at all clear to me how many C++ RDKit
>>> users there are.
>>>
>>> By the way, is there a way to guarantee that users using my binary file
 (e.g. MYTEST in this case) do not need to install RDKit? I tried -static,
 but it didn't work. For example, I hope a user can run MYTEST on another
 Mac without RDKit.

>>>
>>> If you link against the _static version of the libraries (i.e.
>>> -lGraphMol_static instead of -lGraphMol), then you should end up with a
>>> version that doesn't require an RDKit install to run. It can be trickier to
>>> get these commands right because on many (all?) systems, there is an order
>>> dependency to static linkage. So since SmilesParse_static depends on
>>> GraphMol_static, GraphMol_static needs to appear *after* SmilesParse_static
>>> in the link line.
>>>
>>> I hope this helps,
>>> -greg
>>>
>>>
>>>
>>
>
>
> --
> Transform Data into Opportunity.
> Accelerate data analysis in your applications with
> Intel Data Analytics Acceleration Library.
> Click to learn more.
> http://pubads.g.doubleclick.net/gampad/clk?id=278785231=/4140
> ___
> Rdkit-discuss mailing list
> Rdkit-discuss@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/rdkit-discuss
>
>
--
Transform Data into Opportunity.
Accelerate data analysis in your applications with
Intel Data Analytics Acceleration Library.
Click to learn more.
http://pubads.g.doubleclick.net/gampad/clk?id=278785231=/4140___
Rdkit-discuss mailing list
Rdkit-discuss@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/rdkit-discuss


Re: [Rdkit-discuss] compiling error with C++ on maverick

2016-03-15 Thread Greg Landrum
Though that would be useful information, I'm afraid that's not something
I've ever put together.

-greg



On Tue, Mar 15, 2016 at 6:26 PM, Yingfeng Wang  wrote:

> Greg,
>
> Could you please give me an order of all libraries? Say, I want to link
> all RDKit static libraries. I know most of which could be unnecessary, but
> I just want to make my situation easy.  So, if I cannot figure out a better
> plan, this way at least works.
>
> Thanks.
> Yingfeng
>
> On Mon, Mar 14, 2016 at 8:16 AM, Greg Landrum 
> wrote:
>
>>
>>
>> On Sat, Mar 12, 2016 at 5:00 AM, Yingfeng Wang 
>> wrote:
>>
>>> Greg,
>>>
>>> Thanks. Your suggestion solves my problem. I add the following part in
>>> my compiling command.
>>>
>>> -L/Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/lib
>>> -lRDInchiLib  -lInChi -lGraphMol -lRDGeneral
>>>
>>> and the complete compiling command is
>>>
>>> g++ -Wall -O2 -std=c++11  -I
>>> /Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/Code -I
>>> /Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/External -I
>>> /usr/local/Cellar/boost/1.60.0_1/include
>>> -L/Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/lib -lRDInchiLib
>>> -lInChi -lGraphMol -lRDGeneral  -o MYTEST main.cpp
>>>
>>> Is there a way to figure out which library I should link? Actually, my
>>> backup plan is to link all libraries in
>>> /Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/lib
>>>
>>
>> That's one approach, but it's kind of overkill. :-)
>> The big thing is to know which library the functionality you are calling
>> comes from. You can generally tell this from the header files (i.e. if you
>> include something from "DataStructs", then you need to include the
>> DataStructs library). this isn't perfect because some libraries have
>> dependencies on others, but it often works The other approach is to look in
>> the RDKit source code at the CMakeLists.txt file for the libraries you are
>> using and look to see which extra libraries they include when building the
>> tests.
>>
>> This isn't very well documented. I think this kind of documentation is
>> tricky to generate, so I don't want to do it unless it's going to help a
>> large number of people, and it's not at all clear to me how many C++ RDKit
>> users there are.
>>
>> By the way, is there a way to guarantee that users using my binary file
>>> (e.g. MYTEST in this case) do not need to install RDKit? I tried -static,
>>> but it didn't work. For example, I hope a user can run MYTEST on another
>>> Mac without RDKit.
>>>
>>
>> If you link against the _static version of the libraries (i.e.
>> -lGraphMol_static instead of -lGraphMol), then you should end up with a
>> version that doesn't require an RDKit install to run. It can be trickier to
>> get these commands right because on many (all?) systems, there is an order
>> dependency to static linkage. So since SmilesParse_static depends on
>> GraphMol_static, GraphMol_static needs to appear *after* SmilesParse_static
>> in the link line.
>>
>> I hope this helps,
>> -greg
>>
>>
>>
>
--
Transform Data into Opportunity.
Accelerate data analysis in your applications with
Intel Data Analytics Acceleration Library.
Click to learn more.
http://pubads.g.doubleclick.net/gampad/clk?id=278785231=/4140___
Rdkit-discuss mailing list
Rdkit-discuss@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/rdkit-discuss


Re: [Rdkit-discuss] compiling error with C++ on maverick

2016-03-15 Thread Yingfeng Wang
Greg,

Could you please give me an order of all libraries? Say, I want to link all
RDKit static libraries. I know most of which could be unnecessary, but I
just want to make my situation easy.  So, if I cannot figure out a better
plan, this way at least works.

Thanks.
Yingfeng

On Mon, Mar 14, 2016 at 8:16 AM, Greg Landrum 
wrote:

>
>
> On Sat, Mar 12, 2016 at 5:00 AM, Yingfeng Wang  wrote:
>
>> Greg,
>>
>> Thanks. Your suggestion solves my problem. I add the following part in my
>> compiling command.
>>
>> -L/Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/lib
>> -lRDInchiLib  -lInChi -lGraphMol -lRDGeneral
>>
>> and the complete compiling command is
>>
>> g++ -Wall -O2 -std=c++11  -I
>> /Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/Code -I
>> /Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/External -I
>> /usr/local/Cellar/boost/1.60.0_1/include
>> -L/Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/lib -lRDInchiLib
>> -lInChi -lGraphMol -lRDGeneral  -o MYTEST main.cpp
>>
>> Is there a way to figure out which library I should link? Actually, my
>> backup plan is to link all libraries in
>> /Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/lib
>>
>
> That's one approach, but it's kind of overkill. :-)
> The big thing is to know which library the functionality you are calling
> comes from. You can generally tell this from the header files (i.e. if you
> include something from "DataStructs", then you need to include the
> DataStructs library). this isn't perfect because some libraries have
> dependencies on others, but it often works The other approach is to look in
> the RDKit source code at the CMakeLists.txt file for the libraries you are
> using and look to see which extra libraries they include when building the
> tests.
>
> This isn't very well documented. I think this kind of documentation is
> tricky to generate, so I don't want to do it unless it's going to help a
> large number of people, and it's not at all clear to me how many C++ RDKit
> users there are.
>
> By the way, is there a way to guarantee that users using my binary file
>> (e.g. MYTEST in this case) do not need to install RDKit? I tried -static,
>> but it didn't work. For example, I hope a user can run MYTEST on another
>> Mac without RDKit.
>>
>
> If you link against the _static version of the libraries (i.e.
> -lGraphMol_static instead of -lGraphMol), then you should end up with a
> version that doesn't require an RDKit install to run. It can be trickier to
> get these commands right because on many (all?) systems, there is an order
> dependency to static linkage. So since SmilesParse_static depends on
> GraphMol_static, GraphMol_static needs to appear *after* SmilesParse_static
> in the link line.
>
> I hope this helps,
> -greg
>
>
>
--
Transform Data into Opportunity.
Accelerate data analysis in your applications with
Intel Data Analytics Acceleration Library.
Click to learn more.
http://pubads.g.doubleclick.net/gampad/clk?id=278785231=/4140___
Rdkit-discuss mailing list
Rdkit-discuss@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/rdkit-discuss


Re: [Rdkit-discuss] compiling error with C++ on maverick

2016-03-14 Thread Greg Landrum
On Sat, Mar 12, 2016 at 5:00 AM, Yingfeng Wang  wrote:

> Greg,
>
> Thanks. Your suggestion solves my problem. I add the following part in my
> compiling command.
>
> -L/Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/lib -lRDInchiLib
> -lInChi -lGraphMol -lRDGeneral
>
> and the complete compiling command is
>
> g++ -Wall -O2 -std=c++11  -I
> /Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/Code -I
> /Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/External -I
> /usr/local/Cellar/boost/1.60.0_1/include
> -L/Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/lib -lRDInchiLib
> -lInChi -lGraphMol -lRDGeneral  -o MYTEST main.cpp
>
> Is there a way to figure out which library I should link? Actually, my
> backup plan is to link all libraries in
> /Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/lib
>

That's one approach, but it's kind of overkill. :-)
The big thing is to know which library the functionality you are calling
comes from. You can generally tell this from the header files (i.e. if you
include something from "DataStructs", then you need to include the
DataStructs library). this isn't perfect because some libraries have
dependencies on others, but it often works The other approach is to look in
the RDKit source code at the CMakeLists.txt file for the libraries you are
using and look to see which extra libraries they include when building the
tests.

This isn't very well documented. I think this kind of documentation is
tricky to generate, so I don't want to do it unless it's going to help a
large number of people, and it's not at all clear to me how many C++ RDKit
users there are.

By the way, is there a way to guarantee that users using my binary file
> (e.g. MYTEST in this case) do not need to install RDKit? I tried -static,
> but it didn't work. For example, I hope a user can run MYTEST on another
> Mac without RDKit.
>

If you link against the _static version of the libraries (i.e.
-lGraphMol_static instead of -lGraphMol), then you should end up with a
version that doesn't require an RDKit install to run. It can be trickier to
get these commands right because on many (all?) systems, there is an order
dependency to static linkage. So since SmilesParse_static depends on
GraphMol_static, GraphMol_static needs to appear *after* SmilesParse_static
in the link line.

I hope this helps,
-greg
--
Transform Data into Opportunity.
Accelerate data analysis in your applications with
Intel Data Analytics Acceleration Library.
Click to learn more.
http://pubads.g.doubleclick.net/gampad/clk?id=278785231=/4140___
Rdkit-discuss mailing list
Rdkit-discuss@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/rdkit-discuss


Re: [Rdkit-discuss] compiling error with C++ on maverick

2016-03-12 Thread Yingfeng Wang
Greg,

Thanks. Your suggestion solves my problem. I add the following part in my
compiling command.

-L/Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/lib -lRDInchiLib
-lInChi -lGraphMol -lRDGeneral

and the complete compiling command is

g++ -Wall -O2 -std=c++11  -I
/Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/Code -I
/Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/External -I
/usr/local/Cellar/boost/1.60.0_1/include
-L/Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/lib -lRDInchiLib
-lInChi -lGraphMol -lRDGeneral  -o MYTEST main.cpp

Is there a way to figure out which library I should link? Actually, my
backup plan is to link all libraries in
/Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/lib

By the way, is there a way to guarantee that users using my binary file
(e.g. MYTEST in this case) do not need to install RDKit? I tried -static,
but it didn't work. For example, I hope a user can run MYTEST on another
Mac without RDKit.

Again, thank you very much for your help!

Yingfeng

On Fri, Mar 11, 2016 at 11:48 PM, Greg Landrum 
wrote:

> Yingfeng,
>
> you have forgotten to link against the rdkit libraries. If you are using
> the InChI code, you need to link against: RDInchiLib, InChi, GraphMol, and
> RDGeneral. There may be a few others as well.
>
> -greg
>
>
>
>
>
> On Sat, Mar 12, 2016 at 5:13 AM, Yingfeng Wang  wrote:
>
>> After installing RDKit, I try to compile the following code in main.cpp,
>>
>> #include 
>> #include 
>>
>> using namespace RDKit;
>> using namespace std;
>>
>> int main(int argc, const char * argv[]) {
>> string curInchi =
>> "InChI=1S/C10H9N3O/c1-7-11-10(14)9(13-12-7)8-5-3-2-4-6-8/h2-6H,1H3,(H,11,12,14)";
>> InchiToInchiKey(curInchi);
>> //cout << "Hello, World!" << endl;
>> return 0;
>> }
>>
>> with the following command,
>>
>> g++ -Wall -O2 -std=c++11 -I
>> /Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/Code -I
>> /Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/External -I
>> /usr/local/Cellar/boost/1.60.0_1/include -o MYTEST main.cpp
>>
>> on my maverick Macbook. The RDKit has been installed at
>>
>> /Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/
>>
>> while boost is at
>> /usr/local/Cellar/boost/1.60.0_1/
>>
>> The compiler information is
>>
>> g++ -v
>> Configured with: --prefix=/Applications/Xcode.app/Contents/Developer/usr
>> --with-gxx-include-dir=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk/usr/include/c++/4.2.1
>> Apple LLVM version 6.0 (clang-600.0.57) (based on LLVM 3.5svn)
>> Target: x86_64-apple-darwin13.4.0
>> Thread model: posix
>>
>> However, I got the following the error message.
>>
>> Undefined symbols for architecture x86_64:
>>   "RDKit::InchiToInchiKey(std::__1::basic_string> std::__1::char_traits, std::__1::allocator > const&)",
>> referenced from:
>>   _main in main-dd8650.o
>> ld: symbol(s) not found for architecture x86_64
>> clang: error: linker command failed with exit code 1 (use -v to see
>> invocation)
>>
>> I am very sure inchi.h and inchi.cpp are available at
>> /Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/External/INCHI-API/
>>
>> and function
>> std::string InchiToInchiKey(const std::string )
>>
>> is defined in inchi.cpp.
>>
>> Could you please give me some hints for solving this problem?
>>
>> Thanks.
>>
>> Yingfeng
>>
>>
>> --
>> Transform Data into Opportunity.
>> Accelerate data analysis in your applications with
>> Intel Data Analytics Acceleration Library.
>> Click to learn more.
>> http://pubads.g.doubleclick.net/gampad/clk?id=278785111=/4140
>> ___
>> Rdkit-discuss mailing list
>> Rdkit-discuss@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/rdkit-discuss
>>
>>
>
--
Transform Data into Opportunity.
Accelerate data analysis in your applications with
Intel Data Analytics Acceleration Library.
Click to learn more.
http://pubads.g.doubleclick.net/gampad/clk?id=278785111=/4140___
Rdkit-discuss mailing list
Rdkit-discuss@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/rdkit-discuss


Re: [Rdkit-discuss] compiling error with C++ on maverick

2016-03-11 Thread Greg Landrum
Yingfeng,

you have forgotten to link against the rdkit libraries. If you are using
the InChI code, you need to link against: RDInchiLib, InChi, GraphMol, and
RDGeneral. There may be a few others as well.

-greg





On Sat, Mar 12, 2016 at 5:13 AM, Yingfeng Wang  wrote:

> After installing RDKit, I try to compile the following code in main.cpp,
>
> #include 
> #include 
>
> using namespace RDKit;
> using namespace std;
>
> int main(int argc, const char * argv[]) {
> string curInchi =
> "InChI=1S/C10H9N3O/c1-7-11-10(14)9(13-12-7)8-5-3-2-4-6-8/h2-6H,1H3,(H,11,12,14)";
> InchiToInchiKey(curInchi);
> //cout << "Hello, World!" << endl;
> return 0;
> }
>
> with the following command,
>
> g++ -Wall -O2 -std=c++11 -I
> /Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/Code -I
> /Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/External -I
> /usr/local/Cellar/boost/1.60.0_1/include -o MYTEST main.cpp
>
> on my maverick Macbook. The RDKit has been installed at
>
> /Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/
>
> while boost is at
> /usr/local/Cellar/boost/1.60.0_1/
>
> The compiler information is
>
> g++ -v
> Configured with: --prefix=/Applications/Xcode.app/Contents/Developer/usr
> --with-gxx-include-dir=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk/usr/include/c++/4.2.1
> Apple LLVM version 6.0 (clang-600.0.57) (based on LLVM 3.5svn)
> Target: x86_64-apple-darwin13.4.0
> Thread model: posix
>
> However, I got the following the error message.
>
> Undefined symbols for architecture x86_64:
>   "RDKit::InchiToInchiKey(std::__1::basic_string std::__1::char_traits, std::__1::allocator > const&)",
> referenced from:
>   _main in main-dd8650.o
> ld: symbol(s) not found for architecture x86_64
> clang: error: linker command failed with exit code 1 (use -v to see
> invocation)
>
> I am very sure inchi.h and inchi.cpp are available at
> /Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/External/INCHI-API/
>
> and function
> std::string InchiToInchiKey(const std::string )
>
> is defined in inchi.cpp.
>
> Could you please give me some hints for solving this problem?
>
> Thanks.
>
> Yingfeng
>
>
> --
> Transform Data into Opportunity.
> Accelerate data analysis in your applications with
> Intel Data Analytics Acceleration Library.
> Click to learn more.
> http://pubads.g.doubleclick.net/gampad/clk?id=278785111=/4140
> ___
> Rdkit-discuss mailing list
> Rdkit-discuss@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/rdkit-discuss
>
>
--
Transform Data into Opportunity.
Accelerate data analysis in your applications with
Intel Data Analytics Acceleration Library.
Click to learn more.
http://pubads.g.doubleclick.net/gampad/clk?id=278785111=/4140___
Rdkit-discuss mailing list
Rdkit-discuss@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/rdkit-discuss


[Rdkit-discuss] compiling error with C++ on maverick

2016-03-11 Thread Yingfeng Wang
After installing RDKit, I try to compile the following code in main.cpp,

#include 
#include 

using namespace RDKit;
using namespace std;

int main(int argc, const char * argv[]) {
string curInchi =
"InChI=1S/C10H9N3O/c1-7-11-10(14)9(13-12-7)8-5-3-2-4-6-8/h2-6H,1H3,(H,11,12,14)";
InchiToInchiKey(curInchi);
//cout << "Hello, World!" << endl;
return 0;
}

with the following command,

g++ -Wall -O2 -std=c++11 -I
/Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/Code -I
/Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/External -I
/usr/local/Cellar/boost/1.60.0_1/include -o MYTEST main.cpp

on my maverick Macbook. The RDKit has been installed at

/Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/

while boost is at
/usr/local/Cellar/boost/1.60.0_1/

The compiler information is

g++ -v
Configured with: --prefix=/Applications/Xcode.app/Contents/Developer/usr
--with-gxx-include-dir=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk/usr/include/c++/4.2.1
Apple LLVM version 6.0 (clang-600.0.57) (based on LLVM 3.5svn)
Target: x86_64-apple-darwin13.4.0
Thread model: posix

However, I got the following the error message.

Undefined symbols for architecture x86_64:
  "RDKit::InchiToInchiKey(std::__1::basic_string const&)",
referenced from:
  _main in main-dd8650.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see
invocation)

I am very sure inchi.h and inchi.cpp are available at
/Users/yingfeng/software/RDKit/rdkit-Release_2015_03_1/External/INCHI-API/

and function
std::string InchiToInchiKey(const std::string )

is defined in inchi.cpp.

Could you please give me some hints for solving this problem?

Thanks.

Yingfeng
--
Transform Data into Opportunity.
Accelerate data analysis in your applications with
Intel Data Analytics Acceleration Library.
Click to learn more.
http://pubads.g.doubleclick.net/gampad/clk?id=278785111=/4140___
Rdkit-discuss mailing list
Rdkit-discuss@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/rdkit-discuss