Skip to content

Compiling examples #31

@mcpzi

Description

@mcpzi

Hello !

I've been trying to compile the protein surface example following your step by step instructions. To get rid of the first compilation errors I had to add some Boost related entries in the CMakeLists :
find_package(Boost COMPONENTS iostreams filesystem system REQUIRED)
target_link_libraries(protein-surface-area ${CHEMKIT_LIBRARIES} ${Boost_LIBRARIES})

Errors are still showing up at linking :

[100%] Building CXX object CMakeFiles/protein-surface-area.dir/protein-surface-area.cpp.o
Linking CXX executable protein-surface-area
CMakeFiles/protein-surface-area.dir/protein-surface-area.cpp.o: In function `main':
protein-surface-area.cpp:(.text+0x4e): undefined reference to `chemkit::PolymerFile::PolymerFile(std::string const&)'
protein-surface-area.cpp:(.text+0xe3): undefined reference to `chemkit::PolymerFile::polymer(unsigned long) const'
protein-surface-area.cpp:(.text+0x25c): undefined reference to `chemkit::PolymerFile::~PolymerFile()'
protein-surface-area.cpp:(.text+0x2cb): undefined reference to `chemkit::PolymerFile::~PolymerFile()'
CMakeFiles/protein-surface-area.dir/protein-surface-area.cpp.o: In function `chemkit::GenericFile::read(std::istream&)':
protein-surface-area.cpp:(.text._ZN7chemkit11GenericFileINS_11PolymerFileENS_17PolymerFileFormatEE4readERSi[_ZN7chemkit11GenericFileINS_11PolymerFileENS_17PolymerFileFormatEE4readERSi]+0x20a): undefined reference to `chemkit::PolymerFileFormat::errorString() const'
collect2: error: ld returned 1 exit status
make[2]: *** [protein-surface-area] Error 1
make[1]: *** [CMakeFiles/protein-surface-area.dir/all] Error 2
make: *** [all] Error 2

I've tried both the stable version and latest git codes but I can't get past this error ...

Any idea ?

Thanks

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions