From e93b85dbd871d5d56a7bc13235820c488a41266f Mon Sep 17 00:00:00 2001 From: Stefan Metzmacher Date: Tue, 21 Jan 2014 15:26:28 +0100 Subject: s3:wscript: only build ctdb_dummy.c if we have no cluster support Signed-off-by: Stefan Metzmacher Reviewed-by: Michael Adam --- source3/wscript_build | 24 ++++++++++++++++++------ 1 file changed, 18 insertions(+), 6 deletions(-) (limited to 'source3/wscript_build') diff --git a/source3/wscript_build b/source3/wscript_build index 9fc33ceb1c5..02a5c7d58a7 100755 --- a/source3/wscript_build +++ b/source3/wscript_build @@ -270,22 +270,34 @@ bld.SAMBA3_SUBSYSTEM('samba3util', lib/sock_exec.c''', deps='ndr samba-security NDR_SECURITY samba-util util_tdb ccan-hash') -bld.SAMBA3_LIBRARY('samba-cluster-support', - source=''' +if bld.CONFIG_GET("CTDB_CFLAGS"): + SAMBA_CLUSTER_SUPPORT_SOURCES=''' lib/cluster_support.c - lib/ctdb_dummy.c lib/dbwrap/dbwrap_ctdb.c lib/messages_ctdbd.c lib/ctdb_packet.c lib/ctdbd_conn.c lib/ctdb_conn.c torture/test_ctdbconn.c - ''', - deps=''' + ''' + SAMBA_CLUSTER_SUPPORT_DEPS=''' talloc tevent tdb - ''', + ''' +else: + SAMBA_CLUSTER_SUPPORT_SOURCES=''' + lib/cluster_support.c + lib/ctdb_dummy.c + ''' + SAMBA_CLUSTER_SUPPORT_DEPS=''' + talloc + tevent + ''' + +bld.SAMBA3_LIBRARY('samba-cluster-support', + source=SAMBA_CLUSTER_SUPPORT_SOURCES, + deps=SAMBA_CLUSTER_SUPPORT_DEPS, cflags=bld.CONFIG_GET("CTDB_CFLAGS"), allow_undefined_symbols=True, private_library=True) -- cgit