[SCM] CTDB repository - branch master updated - ctdb-1.0.114-111-gc0f38e0

Ronnie Sahlberg sahlberg at samba.org
Tue Jun 1 17:26:08 MDT 2010


The branch, master has been updated
       via  c0f38e0936c487b63964fd9cef7a9370f227275f (commit)
       via  96f186240a17386de1e02eb3af392d97bb55a1ae (commit)
      from  2d60f96680d16c2992e2a35517822f88c12538b7 (commit)

http://gitweb.samba.org/?p=sahlberg/ctdb.git;a=shortlog;h=master


- Log -----------------------------------------------------------------
commit c0f38e0936c487b63964fd9cef7a9370f227275f
Author: Ronnie Sahlberg <ronniesahlberg at gmail.com>
Date:   Wed Jun 2 09:24:17 2010 +1000

    Update the tst.c example application for libctdb to
    use the headers from /usr/include
    and add a comment about how to compile it

commit 96f186240a17386de1e02eb3af392d97bb55a1ae
Author: Ronnie Sahlberg <ronniesahlberg at gmail.com>
Date:   Wed Jun 2 09:18:48 2010 +1000

    rename ccan/typesafe_cb.h to ctdb_typesafe_cb.h and
    add this file to the install/rpm

-----------------------------------------------------------------------

Summary of changes:
 Makefile.in                                        |    1 +
 include/ctdb.h                                     |    2 +-
 include/{ccan/typesafe_cb.h => ctdb_typesafe_cb.h} |    0 
 libctdb/tst.c                                      |   18 +++++++++++++-----
 packaging/RPM/ctdb.spec.in                         |    1 +
 5 files changed, 16 insertions(+), 6 deletions(-)
 rename include/{ccan/typesafe_cb.h => ctdb_typesafe_cb.h} (100%)


Changeset truncated at 500 lines:

diff --git a/Makefile.in b/Makefile.in
index 7b3c621..30cbf2e 100755
--- a/Makefile.in
+++ b/Makefile.in
@@ -224,6 +224,7 @@ install: all
 	${INSTALLCMD} -m 644 include/ctdb_client.h $(DESTDIR)$(includedir)
 	${INSTALLCMD} -m 644 include/ctdb_protocol.h $(DESTDIR)$(includedir)
 	${INSTALLCMD} -m 644 include/ctdb_private.h $(DESTDIR)$(includedir) # for samba3
+	${INSTALLCMD} -m 644 include/ctdb_typesafe_cb.h $(DESTDIR)$(includedir)
 	${INSTALLCMD} -m 644 config/functions $(DESTDIR)$(etcdir)/ctdb
 	${INSTALLCMD} -m 755 config/statd-callout $(DESTDIR)$(etcdir)/ctdb
 	${INSTALLCMD} -m 755 config/interface_modify.sh $(DESTDIR)$(etcdir)/ctdb
diff --git a/include/ctdb.h b/include/ctdb.h
index bd4fdc1..040cd0c 100644
--- a/include/ctdb.h
+++ b/include/ctdb.h
@@ -211,7 +211,7 @@ int ctdb_cancel(struct ctdb_request *);
 
 
 /* These ugly macro wrappers make the callbacks typesafe. */
-#include <ccan/typesafe_cb.h>
+#include <ctdb_typesafe_cb.h>
 #define ctdb_sendcb(cb, cbdata)						\
 	 typesafe_cb_preargs(void, (cb), (cbdata),			\
 			     struct ctdb_connection *, struct ctdb_request *)
diff --git a/include/ccan/typesafe_cb.h b/include/ctdb_typesafe_cb.h
similarity index 100%
rename from include/ccan/typesafe_cb.h
rename to include/ctdb_typesafe_cb.h
diff --git a/libctdb/tst.c b/libctdb/tst.c
index 32dc3a0..af23a56 100644
--- a/libctdb/tst.c
+++ b/libctdb/tst.c
@@ -1,9 +1,6 @@
 /*
  * Example program to demonstrate the libctdb api
  *
- * This program needs to be linked with libtdb.
- * (libtdb and libtdb-devel packages)
- *
  * This program is free software; you can redistribute it and/or modify
  * it under the terms of the GNU General Public License as published by
  * the Free Software Foundation; either version 3 of the License, or
@@ -17,6 +14,17 @@
  * You should have received a copy of the GNU General Public License
  * along with this program; if not, see <http://www.gnu.org/licenses/>.
  */
+
+/*
+ * This program needs to be linked with libtdb and libctdb
+ * (You need these packages installed: libtdb libtdb-devel
+ *  ctdb and ctdb-devel)
+ *
+ * This program can then be compiled using
+ *    gcc -o tst tst.c -ltdb -lctdb
+ *
+ *
+ */
 #include <stdio.h>
 #include <stdint.h>
 #include <poll.h>
@@ -25,8 +33,8 @@
 #include <stdlib.h>
 #include <err.h>
 #include <stdbool.h>
-#include "lib/tdb/include/tdb.h"
-#include "include/ctdb.h"
+#include <tdb.h>
+#include <ctdb.h>
 
 TDB_DATA key;
 
diff --git a/packaging/RPM/ctdb.spec.in b/packaging/RPM/ctdb.spec.in
index 7389213..6706672 100644
--- a/packaging/RPM/ctdb.spec.in
+++ b/packaging/RPM/ctdb.spec.in
@@ -138,6 +138,7 @@ rm -rf $RPM_BUILD_ROOT
 %{_includedir}/ctdb_client.h
 %{_includedir}/ctdb_protocol.h
 %{_includedir}/ctdb_private.h
+%{_includedir}/ctdb_typesafe_cb.h
 %{_libdir}/libctdb.a
 
 %changelog


-- 
CTDB repository


More information about the samba-cvs mailing list