summaryrefslogtreecommitdiffstats
path: root/libglusterfs/src/gfdb
diff options
context:
space:
mode:
authorNiels de Vos <ndevos@redhat.com>2015-04-03 18:14:13 +0200
committerVijay Bellur <vbellur@redhat.com>2015-04-10 11:39:52 +0000
commit6eb27480b6559103e4437facd7aecbcd373479c9 (patch)
tree946b5531baddce4387ac7786f7230c3d52dd1161 /libglusterfs/src/gfdb
parent26cbd3bdf5dad190559afbdf0ac125262c4e90a6 (diff)
build: make contrib/uuid dependency optional
On Linux systems we should use the libuuid from the distribution and not bundle and statically link the contrib/uuid/ bits. libglusterfs/src/compat-uuid.h has been introduced and should become an abstraction layer for different UUID APIs. Non-Linux operating systems should implement their compatibility layer there. Once all operating systems have an implementation in compat-uuid.h, we can remove contrib/uuid/ from the repository completely. Change-Id: I345e5357644be2521685e00358bb8c83c4ea0577 BUG: 1206587 Signed-off-by: Niels de Vos <ndevos@redhat.com> Reviewed-on: http://review.gluster.org/10129 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Vijay Bellur <vbellur@redhat.com>
Diffstat (limited to 'libglusterfs/src/gfdb')
-rw-r--r--libglusterfs/src/gfdb/Makefile.am17
-rw-r--r--libglusterfs/src/gfdb/gfdb_data_store_types.h1
2 files changed, 5 insertions, 13 deletions
diff --git a/libglusterfs/src/gfdb/Makefile.am b/libglusterfs/src/gfdb/Makefile.am
index fdc11bf131a..30d1b7bcdde 100644
--- a/libglusterfs/src/gfdb/Makefile.am
+++ b/libglusterfs/src/gfdb/Makefile.am
@@ -5,7 +5,8 @@ libgfdb_la_CPPFLAGS = $(GF_CPPFLAGS) -D__USE_FILE_OFFSET64 -fpic \
-I$(top_srcdir)/libglusterfs/src \
-DDATADIR=\"$(localstatedir)\"
-libgfdb_la_LIBADD = $(top_builddir)/libglusterfs/src/libglusterfs.la $(SQLITE_LIBS)
+libgfdb_la_LIBADD = $(top_builddir)/libglusterfs/src/libglusterfs.la \
+ $(SQLITE_LIBS) $(UUID_LIBS)
libgfdb_la_LDFLAGS = $(GF_LDFLAGS) -version-info $(LIBGLUSTERFS_LT_VERSION)
@@ -18,25 +19,15 @@ endif
CONTRIB_BUILDDIR = $(top_builddir)/contrib
libgfdb_la_SOURCES = gfdb_data_store.c gfdb_sqlite3_helper.c\
- gfdb_sqlite3.c \
- $(CONTRIBDIR)/uuid/clear.c \
- $(CONTRIBDIR)/uuid/copy.c $(CONTRIBDIR)/uuid/gen_uuid.c \
- $(CONTRIBDIR)/uuid/pack.c $(CONTRIBDIR)/uuid/parse.c \
- $(CONTRIBDIR)/uuid/unparse.c $(CONTRIBDIR)/uuid/uuid_time.c \
- $(CONTRIBDIR)/uuid/compare.c $(CONTRIBDIR)/uuid/isnull.c \
- $(CONTRIBDIR)/uuid/unpack.c
+ gfdb_sqlite3.c
noinst_HEADERS = gfdb_data_store.h gfdb_data_store_types.h gfdb_sqlite3_helper.h\
- gfdb_sqlite3.h gfdb_mem-types.h \
- $(CONTRIBDIR)/uuid/uuidd.h \
- $(CONTRIBDIR)/uuid/uuid.h $(CONTRIBDIR)/uuid/uuid.h \
- $(CONTRIB_BUILDDIR)/uuid/uuid_types.h
+ gfdb_sqlite3.h gfdb_mem-types.h
libgfdb_HEADERS = gfdb_data_store.h gfdb_data_store_types.h \
gfdb_sqlite3.h gfdb_mem-types.h gfdb_sqlite3_helper.c
CLEANFILES =
-CONFIG_CLEAN_FILES = $(CONTRIB_BUILDDIR)/uuid/uuid_types.h
$(top_builddir)/libglusterfs/src/libglusterfs.la:
$(MAKE) -C $(top_builddir)/libglusterfs/src/ all
diff --git a/libglusterfs/src/gfdb/gfdb_data_store_types.h b/libglusterfs/src/gfdb/gfdb_data_store_types.h
index 94708ac1d3b..5bd95241f06 100644
--- a/libglusterfs/src/gfdb/gfdb_data_store_types.h
+++ b/libglusterfs/src/gfdb/gfdb_data_store_types.h
@@ -21,6 +21,7 @@
#include <string.h>
#include "common-utils.h"
+#include "compat-uuid.h"
#include "gfdb_mem-types.h"
#include "dict.h"