Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Tiago Peixoto
graph-tool
Commits
c3cdcdd9
Commit
c3cdcdd9
authored
Jan 03, 2014
by
Tiago Peixoto
Browse files
Improve inclusion of sparsehash when directory prefix is nonstandard
parent
4323e370
Changes
6
Hide whitespace changes
Inline
Side-by-side
configure.ac
View file @
c3cdcdd9
...
...
@@ -318,18 +318,23 @@ if test "$USING_CAIRO" = "yes"; then
fi
dnl sparsehash
[SPARSEHASH_PREFIX=sparsehash]
AC_ARG_WITH([sparsehash-prefix], [AS_HELP_STRING([--with-sparsehash-prefix=prefix],
[include directory prefix for sparsehash
[default=sparsehash] ])],
[SPARSEHASH_PREFIX=$withval])
if test "$USING_SPARSEHASH" = "yes"; then
PKG_CHECK_MODULES(SPARSEHASH, [libsparsehash], AC_DEFINE([HAVE_SPARSEHASH], [1],
[Using google's sparsehash]), [])
[SPARSEHASH_CFLAGS="${SPARSEHASH_CFLAGS} -DSPARSEHASH_PREFIX=${SPARSEHASH_PREFIX}"]
AC_SUBST(SPARSEHASH_CFLAGS)
[OLD_CXXFLAGS="${CXXFLAGS}"]
[OLD_CPPFLAGS="${CPPFLAGS}"]
AC_DEFINE_UNQUOTED([SPARSEHASH_INCLUDE(f)], [<${SPARSEHASH_PREFIX}/f>],
[Sparsehash include macro])
[CXXFLAGS="${CXXFLAGS} ${SPARSEHASH_CFLAGS}"]
[CPPFLAGS="${CPPFLAGS} ${SPARSEHASH_CFLAGS}"]
AC_CHECK_HEADER([
sparsehash
/dense_hash_set], [],
AC_CHECK_HEADER([
${SPARSEHASH_PREFIX}
/dense_hash_set], [],
[AC_MSG_ERROR([sparsehash headers not found])])
[CXXFLAGS="${OLD_CXXFLAGS}"]
[CPPFLAGS="${OLD_CPPFLAGS}"]
fi
dnl Checks for typedefs, structures, and compiler characteristics.
...
...
src/graph/clustering/graph_clustering.hh
View file @
c3cdcdd9
...
...
@@ -24,7 +24,7 @@
#include <boost/mpl/if.hpp>
#ifdef HAVE_SPARSEHASH
#include
<sparsehash/
dense_hash_set
>
#include
SPARSEHASH_INCLUDE(
dense_hash_set
)
#endif
#ifndef __clang__
...
...
src/graph/community/graph_blockmodel.hh
View file @
c3cdcdd9
...
...
@@ -28,8 +28,8 @@
#include <tuple>
#ifdef HAVE_SPARSEHASH
#include
<sparsehash/
dense_hash_set
>
#include
<sparsehash/
dense_hash_map
>
#include
SPARSEHASH_INCLUDE(
dense_hash_set
)
#include
SPARSEHASH_INCLUDE(
dense_hash_map
)
#endif
#include "../generation/sampler.hh"
...
...
src/graph/community/graph_community_network.hh
View file @
c3cdcdd9
...
...
@@ -21,7 +21,7 @@
#include <unordered_map>
#ifdef HAVE_SPARSEHASH
#include
<sparsehash/
dense_hash_map
>
#include
SPARSEHASH_INCLUDE(
dense_hash_map
)
#endif
#include <iostream>
...
...
src/graph/generation/graph_rewiring.hh
View file @
c3cdcdd9
...
...
@@ -33,7 +33,7 @@
#include "random.hh"
#ifdef HAVE_SPARSEHASH
#include
<sparsehash/
dense_hash_map
>
#include
SPARSEHASH_INCLUDE(
dense_hash_map
)
#endif
namespace
graph_tool
...
...
src/graph/stats/graph_parallel.hh
View file @
c3cdcdd9
...
...
@@ -19,7 +19,7 @@
#include <unordered_map>
#ifdef HAVE_SPARSEHASH
#include
<sparsehash/
dense_hash_map
>
#include
SPARSEHASH_INCLUDE(
dense_hash_map
)
#endif
#include "graph_util.hh"
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment