Installing graph tool in cygwin

I am trying to install graph-tool on windows in the cygwin environment. I
have managed to install all of the dependencies and successfully run the
configuration script, but when I make, I get this:

$ make
make all-recursive
make[1]: Entering directory '/home/mcintima/graph-tool-2.2.43'
Making all in src
make[2]: Entering directory '/home/mcintima/graph-tool-2.2.43/src'
Making all in graph
make[3]: Entering directory '/home/mcintima/graph-tool-2.2.43/src/graph'
Making all in centrality
make[4]: Entering directory
'/home/mcintima/graph-tool-2.2.43/src/graph/centrality'
   CXX graph_betweenness.lo
   CXX graph_centrality_bind.lo
   CXX graph_closeness.lo
   CXX graph_eigentrust.lo
   CXX graph_eigenvector.lo
   CXX graph_hits.lo
   CXX graph_katz.lo
   CXX graph_pagerank.lo
   CXX graph_trust_transitivity.lo
   CXXLD libgraph_tool_centrality.la
/usr/lib/gcc/x86_64-pc-cygwin/4.9.2/../../../../x86_64-pc-cygwin/bin/ld:
warning: --export-dynamic is not supported for PE+ targets, did you mean
--export-all-symbols?
.libs/graph_betweenness.o:graph_betweenness.cc:(.text+0x2449): undefined
reference to `graph_tool::GraphInterface::GetNumberOfVertices(bool)'
.libs/graph_betweenness.o:graph_betweenness.cc:(.text+0x2449): relocation
truncated to fit: R_X86_64_PC32 against undefined symbol
`graph_tool::GraphInterface::GetNumberOfVertices(bool)'
.libs/graph_betweenness.o:graph_betweenness.cc:(.text+0x2659): undefined
reference to `graph_tool::GraphInterface::GetNumberOfVertices(bool)'
.libs/graph_betweenness.o:graph_betweenness.cc:(.text+0x2659): relocation
truncated to fit: R_X86_64_PC32 against undefined symbol
`graph_tool::GraphInterface::GetNumberOfVertices(bool)'
.libs/graph_betweenness.o:graph_betweenness.cc:(.text+0x2709): undefined
reference to `graph_tool::ValueException::ValueException(std::string
const&)'
.libs/graph_betweenness.o:graph_betweenness.cc:(.text+0x2709): relocation
truncated to fit: R_X86_64_PC32 against undefined symbol
`graph_tool::ValueException::ValueException(std::string const&)'
.libs/graph_betweenness.o:graph_betweenness.cc:(.text+0x2726): undefined
reference to `graph_tool::ValueException::~ValueException()'
.libs/graph_betweenness.o:graph_betweenness.cc:(.text+0x2726): relocation
truncated to fit: R_X86_64_PC32 against undefined symbol
`graph_tool::ValueException::~ValueException()'
.libs/graph_betweenness.o:graph_betweenness.cc:(.text+0x275f): undefined
reference to `graph_tool::ValueException::ValueException(std::string
const&)'
.libs/graph_betweenness.o:graph_betweenness.cc:(.text+0x275f): relocation
truncated to fit: R_X86_64_PC32 against undefined symbol
`graph_tool::ValueException::ValueException(std::string const&)'
.libs/graph_betweenness.o:graph_betweenness.cc:(.text$_ZN10graph_tool14ActionNotFoundD1Ev[_ZN10graph_tool14ActionNotFoundD1Ev]+0x3c):
undefined reference to `graph_tool::GraphException::~GraphException()'
.libs/graph_betweenness.o:graph_betweenness.cc:(.text$_ZN10graph_tool14ActionNotFoundD1Ev[_ZN10graph_tool14ActionNotFoundD1Ev]+0x3c):
relocation truncated to fit: R_X86_64_PC32 against undefined symbol
`graph_tool::GraphException::~GraphException()'

...and so on. I tried replacing --export-dynamic with --export-all-symbols
in configure.ac, which just led to the same error. I also tried replacing
all instances of --export-dynamic in the graph-tool folder, which just
caused the compilation to crash sooner. Any help would be greatly
appreciated.

Thanks,

Matthew McIntire

attachment.html (7.43 KB)

The shared library model on windows is very different than typical
unixes, even under cygwin. The way that graph-tool works is that each
submodule has its own shared library. Each one may have undefined
symbols that get dynamically resolved when they are all loaded. If I'm
not mistaken, in windows these must all be resolved during compilation
time (as this error shows). This means that the submodules must
explicitly include libgraph_tool_core.a (which is redundant and wasteful
in e.g. GNU/Linux).

There was a thread about this a little while ago (but without Cygwin):

      http://lists.skewed.de/pipermail/graph-tool/2015-May/001972.html

The build process needs be significantly modified. I'll see if I find
the time to do this, but it is rather difficult since I cannot test this
myself.

Best,
Tiago