Update to latest trunk (1756)
This commit is contained in:
parent
36df0fa194
commit
262f485720
@ -976,7 +976,7 @@ diff -Naurd corosync-0.92/exec/ipc.h corosync-trunk/exec/ipc.h
|
|||||||
#endif /* IPC_H_DEFINED */
|
#endif /* IPC_H_DEFINED */
|
||||||
diff -Naurd corosync-0.92/exec/logsys.c corosync-trunk/exec/logsys.c
|
diff -Naurd corosync-0.92/exec/logsys.c corosync-trunk/exec/logsys.c
|
||||||
--- corosync-0.92/exec/logsys.c 2008-09-17 20:22:58.000000000 +0200
|
--- corosync-0.92/exec/logsys.c 2008-09-17 20:22:58.000000000 +0200
|
||||||
+++ corosync-trunk/exec/logsys.c 2009-01-26 14:15:57.000000000 +0100
|
+++ corosync-trunk/exec/logsys.c 2009-01-23 15:25:30.000000000 +0100
|
||||||
@@ -1,6 +1,6 @@
|
@@ -1,6 +1,6 @@
|
||||||
/*
|
/*
|
||||||
* Copyright (c) 2002-2004 MontaVista Software, Inc.
|
* Copyright (c) 2002-2004 MontaVista Software, Inc.
|
||||||
@ -1003,7 +1003,7 @@ diff -Naurd corosync-0.92/exec/logsys.c corosync-trunk/exec/logsys.c
|
|||||||
#if defined(COROSYNC_LINUX)
|
#if defined(COROSYNC_LINUX)
|
||||||
#include <linux/un.h>
|
#include <linux/un.h>
|
||||||
#endif
|
#endif
|
||||||
@@ -54,14 +58,54 @@
|
@@ -54,14 +58,53 @@
|
||||||
#include <pthread.h>
|
#include <pthread.h>
|
||||||
|
|
||||||
#include <corosync/engine/logsys.h>
|
#include <corosync/engine/logsys.h>
|
||||||
@ -1044,7 +1044,6 @@ diff -Naurd corosync-0.92/exec/logsys.c corosync-trunk/exec/logsys.c
|
|||||||
+
|
+
|
||||||
+struct logsys_logger {
|
+struct logsys_logger {
|
||||||
+ char subsys[64];
|
+ char subsys[64];
|
||||||
+ unsigned int facility;
|
|
||||||
+ unsigned int priority;
|
+ unsigned int priority;
|
||||||
+ unsigned int tags;
|
+ unsigned int tags;
|
||||||
+ unsigned int mode;
|
+ unsigned int mode;
|
||||||
@ -1060,7 +1059,7 @@ diff -Naurd corosync-0.92/exec/logsys.c corosync-trunk/exec/logsys.c
|
|||||||
|
|
||||||
static char *logsys_file = NULL;
|
static char *logsys_file = NULL;
|
||||||
|
|
||||||
@@ -69,35 +113,44 @@
|
@@ -69,35 +112,44 @@
|
||||||
|
|
||||||
static int logsys_facility = LOG_DAEMON;
|
static int logsys_facility = LOG_DAEMON;
|
||||||
|
|
||||||
@ -1095,9 +1094,11 @@ diff -Naurd corosync-0.92/exec/logsys.c corosync-trunk/exec/logsys.c
|
|||||||
|
|
||||||
-int logsys_single_id = 0;
|
-int logsys_single_id = 0;
|
||||||
+static pthread_spinlock_t logsys_idx_spinlock;
|
+static pthread_spinlock_t logsys_idx_spinlock;
|
||||||
|
+
|
||||||
+static unsigned int log_rec_idx;
|
+static unsigned int log_rec_idx;
|
||||||
|
|
||||||
|
+static int logsys_buffer_full = 0;
|
||||||
|
|
||||||
-struct log_entry {
|
-struct log_entry {
|
||||||
- char *file;
|
- char *file;
|
||||||
- int line;
|
- int line;
|
||||||
@ -1105,14 +1106,12 @@ diff -Naurd corosync-0.92/exec/logsys.c corosync-trunk/exec/logsys.c
|
|||||||
- char str[128];
|
- char str[128];
|
||||||
- struct log_entry *next;
|
- struct log_entry *next;
|
||||||
-};
|
-};
|
||||||
+static int logsys_buffer_full = 0;
|
|
||||||
|
|
||||||
-static struct log_entry *head;
|
|
||||||
+static char *format_buffer="[%6s] %b";
|
+static char *format_buffer="[%6s] %b";
|
||||||
|
|
||||||
-static struct log_entry *tail;
|
-static struct log_entry *head;
|
||||||
+static int log_requests_pending = 0;
|
+static int log_requests_pending = 0;
|
||||||
+
|
|
||||||
|
-static struct log_entry *tail;
|
||||||
+static int log_requests_lost = 0;
|
+static int log_requests_lost = 0;
|
||||||
+
|
+
|
||||||
+void *logsys_rec_end;
|
+void *logsys_rec_end;
|
||||||
@ -1123,7 +1122,7 @@ diff -Naurd corosync-0.92/exec/logsys.c corosync-trunk/exec/logsys.c
|
|||||||
|
|
||||||
struct log_data {
|
struct log_data {
|
||||||
unsigned int syslog_pos;
|
unsigned int syslog_pos;
|
||||||
@@ -105,324 +158,674 @@
|
@@ -105,324 +157,674 @@
|
||||||
char *log_string;
|
char *log_string;
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -2022,7 +2021,7 @@ diff -Naurd corosync-0.92/exec/logsys.c corosync-trunk/exec/logsys.c
|
|||||||
pthread_mutex_unlock (&logsys_config_mutex);
|
pthread_mutex_unlock (&logsys_config_mutex);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -431,22 +834,28 @@
|
@@ -431,22 +833,28 @@
|
||||||
return logsys_mode;
|
return logsys_mode;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -2055,7 +2054,7 @@ diff -Naurd corosync-0.92/exec/logsys.c corosync-trunk/exec/logsys.c
|
|||||||
logsys_file_fp = fopen (file, "a+");
|
logsys_file_fp = fopen (file, "a+");
|
||||||
if (logsys_file_fp == 0) {
|
if (logsys_file_fp == 0) {
|
||||||
sprintf (error_string_response,
|
sprintf (error_string_response,
|
||||||
@@ -454,222 +863,243 @@
|
@@ -454,222 +862,243 @@
|
||||||
file, strerror (errno));
|
file, strerror (errno));
|
||||||
*error_string = error_string_response;
|
*error_string = error_string_response;
|
||||||
pthread_mutex_unlock (&logsys_config_mutex);
|
pthread_mutex_unlock (&logsys_config_mutex);
|
||||||
@ -5853,7 +5852,7 @@ diff -Naurd corosync-0.92/include/corosync/ais_util.h corosync-trunk/include/cor
|
|||||||
#endif /* AIS_UTIL_H_DEFINED */
|
#endif /* AIS_UTIL_H_DEFINED */
|
||||||
diff -Naurd corosync-0.92/include/corosync/cfg.h corosync-trunk/include/corosync/cfg.h
|
diff -Naurd corosync-0.92/include/corosync/cfg.h corosync-trunk/include/corosync/cfg.h
|
||||||
--- corosync-0.92/include/corosync/cfg.h 2008-08-15 08:15:26.000000000 +0200
|
--- corosync-0.92/include/corosync/cfg.h 2008-08-15 08:15:26.000000000 +0200
|
||||||
+++ corosync-trunk/include/corosync/cfg.h 2009-01-19 09:31:21.000000000 +0100
|
+++ corosync-trunk/include/corosync/cfg.h 2009-01-29 10:17:43.000000000 +0100
|
||||||
@@ -1,6 +1,6 @@
|
@@ -1,6 +1,6 @@
|
||||||
/*
|
/*
|
||||||
* Copyright (c) 2005 MontaVista Software, Inc.
|
* Copyright (c) 2005 MontaVista Software, Inc.
|
||||||
@ -5982,7 +5981,7 @@ diff -Naurd corosync-0.92/include/corosync/cfg.h corosync-trunk/include/corosync
|
|||||||
+ */
|
+ */
|
||||||
+typedef struct
|
+typedef struct
|
||||||
+{
|
+{
|
||||||
+ int addressLength;
|
+ int address_length;
|
||||||
+ char address[sizeof(struct sockaddr_in6)];
|
+ char address[sizeof(struct sockaddr_in6)];
|
||||||
+} corosync_cfg_node_address_t;
|
+} corosync_cfg_node_address_t;
|
||||||
+
|
+
|
||||||
@ -8266,8 +8265,8 @@ diff -Naurd corosync-0.92/include/corosync/pload.h corosync-trunk/include/corosy
|
|||||||
+#endif /* COROSYNC_PLOAD_H_DEFINED */
|
+#endif /* COROSYNC_PLOAD_H_DEFINED */
|
||||||
diff -Naurd corosync-0.92/include/corosync/quorum.h corosync-trunk/include/corosync/quorum.h
|
diff -Naurd corosync-0.92/include/corosync/quorum.h corosync-trunk/include/corosync/quorum.h
|
||||||
--- corosync-0.92/include/corosync/quorum.h 1970-01-01 01:00:00.000000000 +0100
|
--- corosync-0.92/include/corosync/quorum.h 1970-01-01 01:00:00.000000000 +0100
|
||||||
+++ corosync-trunk/include/corosync/quorum.h 2008-12-08 16:55:41.000000000 +0100
|
+++ corosync-trunk/include/corosync/quorum.h 2009-01-30 14:31:40.000000000 +0100
|
||||||
@@ -0,0 +1,97 @@
|
@@ -0,0 +1,105 @@
|
||||||
+/*
|
+/*
|
||||||
+ * Copyright (c) 2008 Red Hat, Inc.
|
+ * Copyright (c) 2008 Red Hat, Inc.
|
||||||
+ *
|
+ *
|
||||||
@ -8341,6 +8340,14 @@ diff -Naurd corosync-0.92/include/corosync/quorum.h corosync-trunk/include/coros
|
|||||||
+
|
+
|
||||||
+
|
+
|
||||||
+/*
|
+/*
|
||||||
|
+ * Get a file descriptor on which to poll. quorum_handle_t is NOT a
|
||||||
|
+ * file descriptor and may not be used directly.
|
||||||
|
+ */
|
||||||
|
+cs_error_t quorum_fd_get (
|
||||||
|
+ quorum_handle_t handle,
|
||||||
|
+ int *fd);
|
||||||
|
+
|
||||||
|
+/*
|
||||||
+ * Dispatch messages and configuration changes
|
+ * Dispatch messages and configuration changes
|
||||||
+ */
|
+ */
|
||||||
+cs_error_t quorum_dispatch (
|
+cs_error_t quorum_dispatch (
|
||||||
@ -8608,8 +8615,8 @@ diff -Naurd corosync-0.92/include/corosync/totem/totempg.h corosync-trunk/includ
|
|||||||
|
|
||||||
diff -Naurd corosync-0.92/include/corosync/votequorum.h corosync-trunk/include/corosync/votequorum.h
|
diff -Naurd corosync-0.92/include/corosync/votequorum.h corosync-trunk/include/corosync/votequorum.h
|
||||||
--- corosync-0.92/include/corosync/votequorum.h 1970-01-01 01:00:00.000000000 +0100
|
--- corosync-0.92/include/corosync/votequorum.h 1970-01-01 01:00:00.000000000 +0100
|
||||||
+++ corosync-trunk/include/corosync/votequorum.h 2009-01-26 11:46:08.000000000 +0100
|
+++ corosync-trunk/include/corosync/votequorum.h 2009-01-30 14:31:40.000000000 +0100
|
||||||
@@ -0,0 +1,198 @@
|
@@ -0,0 +1,205 @@
|
||||||
+/*
|
+/*
|
||||||
+ * Copyright (c) 2009 Red Hat, Inc.
|
+ * Copyright (c) 2009 Red Hat, Inc.
|
||||||
+ *
|
+ *
|
||||||
@ -8722,6 +8729,13 @@ diff -Naurd corosync-0.92/include/corosync/votequorum.h corosync-trunk/include/c
|
|||||||
+ votequorum_handle_t handle,
|
+ votequorum_handle_t handle,
|
||||||
+ cs_dispatch_flags_t dispatch_types);
|
+ cs_dispatch_flags_t dispatch_types);
|
||||||
+
|
+
|
||||||
|
+/*
|
||||||
|
+ * Get a file descriptor on which to poll. votequorum_handle_t is NOT a
|
||||||
|
+ * file descriptor and may not be used directly.
|
||||||
|
+ */
|
||||||
|
+cs_error_t votequorum_fd_get (
|
||||||
|
+ votequorum_handle_t handle,
|
||||||
|
+ int *fd);
|
||||||
+
|
+
|
||||||
+/*
|
+/*
|
||||||
+ * Get quorum information.
|
+ * Get quorum information.
|
||||||
@ -8886,7 +8900,7 @@ diff -Naurd corosync-0.92/lcr/uis.c corosync-trunk/lcr/uis.c
|
|||||||
|
|
||||||
diff -Naurd corosync-0.92/lib/cfg.c corosync-trunk/lib/cfg.c
|
diff -Naurd corosync-0.92/lib/cfg.c corosync-trunk/lib/cfg.c
|
||||||
--- corosync-0.92/lib/cfg.c 2008-08-15 08:15:26.000000000 +0200
|
--- corosync-0.92/lib/cfg.c 2008-08-15 08:15:26.000000000 +0200
|
||||||
+++ corosync-trunk/lib/cfg.c 2009-01-19 09:31:21.000000000 +0100
|
+++ corosync-trunk/lib/cfg.c 2009-01-29 10:17:43.000000000 +0100
|
||||||
@@ -1,13 +1,13 @@
|
@@ -1,13 +1,13 @@
|
||||||
/*
|
/*
|
||||||
* Copyright (c) 2002-2005 MontaVista Software, Inc.
|
* Copyright (c) 2002-2005 MontaVista Software, Inc.
|
||||||
@ -9723,7 +9737,7 @@ diff -Naurd corosync-0.92/lib/cfg.c corosync-trunk/lib/cfg.c
|
|||||||
+ addrlen = sizeof(struct sockaddr_in6);
|
+ addrlen = sizeof(struct sockaddr_in6);
|
||||||
+
|
+
|
||||||
+ for (i=0; i<max_addrs && i<res_lib_cfg_get_node_addrs->num_addrs; i++) {
|
+ for (i=0; i<max_addrs && i<res_lib_cfg_get_node_addrs->num_addrs; i++) {
|
||||||
+ addrs[i].addressLength = addrlen;
|
+ addrs[i].address_length = addrlen;
|
||||||
+ struct sockaddr_in *in;
|
+ struct sockaddr_in *in;
|
||||||
+ struct sockaddr_in6 *in6;
|
+ struct sockaddr_in6 *in6;
|
||||||
+
|
+
|
||||||
@ -13913,8 +13927,8 @@ diff -Naurd corosync-0.92/lib/util.h corosync-trunk/lib/util.h
|
|||||||
SaVersionT *version);
|
SaVersionT *version);
|
||||||
diff -Naurd corosync-0.92/lib/votequorum.c corosync-trunk/lib/votequorum.c
|
diff -Naurd corosync-0.92/lib/votequorum.c corosync-trunk/lib/votequorum.c
|
||||||
--- corosync-0.92/lib/votequorum.c 1970-01-01 01:00:00.000000000 +0100
|
--- corosync-0.92/lib/votequorum.c 1970-01-01 01:00:00.000000000 +0100
|
||||||
+++ corosync-trunk/lib/votequorum.c 2009-01-26 11:46:08.000000000 +0100
|
+++ corosync-trunk/lib/votequorum.c 2009-01-30 14:31:40.000000000 +0100
|
||||||
@@ -0,0 +1,821 @@
|
@@ -0,0 +1,841 @@
|
||||||
+/*
|
+/*
|
||||||
+ * Copyright (c) 2009 Red Hat, Inc.
|
+ * Copyright (c) 2009 Red Hat, Inc.
|
||||||
+ *
|
+ *
|
||||||
@ -14587,6 +14601,26 @@ diff -Naurd corosync-0.92/lib/votequorum.c corosync-trunk/lib/votequorum.c
|
|||||||
+}
|
+}
|
||||||
+
|
+
|
||||||
+
|
+
|
||||||
|
+cs_error_t votequorum_fd_get (
|
||||||
|
+ votequorum_handle_t handle,
|
||||||
|
+ int *fd)
|
||||||
|
+{
|
||||||
|
+ cs_error_t error;
|
||||||
|
+ struct votequorum_inst *votequorum_inst;
|
||||||
|
+
|
||||||
|
+ error = saHandleInstanceGet (&votequorum_handle_t_db, handle, (void *)&votequorum_inst);
|
||||||
|
+ if (error != CS_OK) {
|
||||||
|
+ return (error);
|
||||||
|
+ }
|
||||||
|
+
|
||||||
|
+ *fd = votequorum_inst->dispatch_fd;
|
||||||
|
+
|
||||||
|
+ (void)saHandleInstancePut (&votequorum_handle_t_db, handle);
|
||||||
|
+
|
||||||
|
+ return (CS_OK);
|
||||||
|
+}
|
||||||
|
+
|
||||||
|
+
|
||||||
+struct res_overlay {
|
+struct res_overlay {
|
||||||
+ mar_res_header_t header __attribute__((aligned(8)));
|
+ mar_res_header_t header __attribute__((aligned(8)));
|
||||||
+ char data[512000];
|
+ char data[512000];
|
||||||
@ -14738,9 +14772,47 @@ diff -Naurd corosync-0.92/lib/votequorum.c corosync-trunk/lib/votequorum.c
|
|||||||
+}
|
+}
|
||||||
diff -Naurd corosync-0.92/Makefile corosync-trunk/Makefile
|
diff -Naurd corosync-0.92/Makefile corosync-trunk/Makefile
|
||||||
--- corosync-0.92/Makefile 2008-09-03 09:58:08.000000000 +0200
|
--- corosync-0.92/Makefile 2008-09-03 09:58:08.000000000 +0200
|
||||||
+++ corosync-trunk/Makefile 2009-01-26 11:46:08.000000000 +0100
|
+++ corosync-trunk/Makefile 2009-01-30 19:44:13.000000000 +0100
|
||||||
@@ -115,10 +115,17 @@
|
@@ -46,24 +46,8 @@
|
||||||
|
INCLUDEDIR_ENGINE=$(PREFIX)/include/corosync/engine
|
||||||
|
MANDIR=$(PREFIX)/share/man
|
||||||
|
ETCDIR=/etc
|
||||||
|
-ARCH=$(shell uname -p)
|
||||||
|
|
||||||
|
-ifeq (,$(findstring 64,$(ARCH)))
|
||||||
|
-LIBDIR=$(PREFIX)/lib/corosync
|
||||||
|
-else
|
||||||
|
-LIBDIR=$(PREFIX)/lib64/corosync
|
||||||
|
-endif
|
||||||
|
-ifeq (s390,$(ARCH))
|
||||||
|
-LIBDIR=$(PREFIX)/lib/corosync
|
||||||
|
-endif
|
||||||
|
-ifeq (s390x,$(ARCH))
|
||||||
|
-LIBDIR=$(PREFIX)/lib64/corosync
|
||||||
|
-endif
|
||||||
|
-ifeq (ia64,$(ARCH))
|
||||||
|
-LIBDIR=$(PREFIX)/lib/corosync
|
||||||
|
-endif
|
||||||
|
-
|
||||||
|
-SUBDIRS:=$(builddir)lcr $(builddir)lib $(builddir)tools $(builddir)exec $(builddir)test $(builddir)services
|
||||||
|
+SUBDIRS:=$(builddir)lcr $(builddir)lib $(builddir)tools $(builddir)exec $(builddir)test $(builddir)services $(builddir)pkgconfig
|
||||||
|
sub_make = srcdir=$(srcdir) builddir=$(builddir) subdir=$(1)/ $(MAKE) -I$(srcdir)$(1) -f $(srcdir)$(1)/Makefile $(2)
|
||||||
|
|
||||||
|
all: $(SUBDIRS)
|
||||||
|
@@ -73,6 +57,7 @@
|
||||||
|
@(cd $(builddir)tools; echo ==== `pwd` ===; $(call sub_make,tools,all));
|
||||||
|
@(cd $(builddir)services; echo ==== `pwd` ===; $(call sub_make,services,all));
|
||||||
|
@(cd $(builddir)test; echo ==== `pwd` ===; $(call sub_make,test,all));
|
||||||
|
+ @(cd $(builddir)pkgconfig; echo ==== `pwd` ===; $(call sub_make,pkgconfig,all));
|
||||||
|
|
||||||
|
# subdirs are not phony
|
||||||
|
.PHONY: all clean install doxygen
|
||||||
|
@@ -113,12 +98,21 @@
|
||||||
|
(cd $(builddir)exec; echo ==== `pwd` ===; $(call sub_make,exec,clean));
|
||||||
|
(cd $(builddir)services; echo ==== `pwd` ===; $(call sub_make,services,clean));
|
||||||
(cd $(builddir)test; echo ==== `pwd` ===; $(call sub_make,test,clean));
|
(cd $(builddir)test; echo ==== `pwd` ===; $(call sub_make,test,clean));
|
||||||
|
+ (cd $(builddir)pkgconfig; echo ==== `pwd` ===; $(call sub_make,pkgconfig,clean));
|
||||||
|
+
|
||||||
rm -rf $(builddir)doc/api
|
rm -rf $(builddir)doc/api
|
||||||
|
|
||||||
-COROSYNC_LIBS = evs cpg cfg coroutil confdb
|
-COROSYNC_LIBS = evs cpg cfg coroutil confdb
|
||||||
@ -14759,7 +14831,15 @@ diff -Naurd corosync-0.92/Makefile corosync-trunk/Makefile
|
|||||||
|
|
||||||
EXEC_LIBS = totem_pg logsys
|
EXEC_LIBS = totem_pg logsys
|
||||||
|
|
||||||
@@ -145,7 +152,7 @@
|
@@ -134,6 +128,7 @@
|
||||||
|
mkdir -p $(DESTDIR)$(MANDIR)/man5
|
||||||
|
mkdir -p $(DESTDIR)$(MANDIR)/man8
|
||||||
|
mkdir -p $(DESTDIR)$(ETCDIR)/ld.so.conf.d
|
||||||
|
+ mkdir -p $(DESTDIR)$(PKGCONFIGDIR)
|
||||||
|
|
||||||
|
|
||||||
|
for eLib in $(EXEC_LIBS); do \
|
||||||
|
@@ -145,7 +140,7 @@
|
||||||
install -m 755 exec/lib$$eLib.so.2.* $(DESTDIR)$(LIBDIR); \
|
install -m 755 exec/lib$$eLib.so.2.* $(DESTDIR)$(LIBDIR); \
|
||||||
if [ "xYES" = "x$(STATICLIBS)" ]; then \
|
if [ "xYES" = "x$(STATICLIBS)" ]; then \
|
||||||
install -m 755 exec/lib$$eLib.a $(DESTDIR)$(LIBDIR); \
|
install -m 755 exec/lib$$eLib.a $(DESTDIR)$(LIBDIR); \
|
||||||
@ -14768,7 +14848,7 @@ diff -Naurd corosync-0.92/Makefile corosync-trunk/Makefile
|
|||||||
ranlib $(DESTDIR)$(LIBDIR)/lib$$eLib.a; \
|
ranlib $(DESTDIR)$(LIBDIR)/lib$$eLib.a; \
|
||||||
fi \
|
fi \
|
||||||
fi \
|
fi \
|
||||||
@@ -161,7 +168,7 @@
|
@@ -161,7 +156,7 @@
|
||||||
install -m 755 lib/lib$$aLib.so.2.* $(DESTDIR)$(LIBDIR); \
|
install -m 755 lib/lib$$aLib.so.2.* $(DESTDIR)$(LIBDIR); \
|
||||||
if [ "xYES" = "x$(STATICLIBS)" ]; then \
|
if [ "xYES" = "x$(STATICLIBS)" ]; then \
|
||||||
install -m 755 lib/lib$$aLib.a $(DESTDIR)$(LIBDIR); \
|
install -m 755 lib/lib$$aLib.a $(DESTDIR)$(LIBDIR); \
|
||||||
@ -14777,7 +14857,7 @@ diff -Naurd corosync-0.92/Makefile corosync-trunk/Makefile
|
|||||||
ranlib $(DESTDIR)$(LIBDIR)/lib$$aLib.a; \
|
ranlib $(DESTDIR)$(LIBDIR)/lib$$aLib.a; \
|
||||||
fi \
|
fi \
|
||||||
fi \
|
fi \
|
||||||
@@ -177,7 +184,7 @@
|
@@ -177,7 +172,7 @@
|
||||||
install -m 755 $(builddir)tools/corosync-cfgtool $(DESTDIR)$(SBINDIR)
|
install -m 755 $(builddir)tools/corosync-cfgtool $(DESTDIR)$(SBINDIR)
|
||||||
install -m 755 $(builddir)tools/corosync-keygen $(DESTDIR)$(SBINDIR)
|
install -m 755 $(builddir)tools/corosync-keygen $(DESTDIR)$(SBINDIR)
|
||||||
|
|
||||||
@ -14786,7 +14866,7 @@ diff -Naurd corosync-0.92/Makefile corosync-trunk/Makefile
|
|||||||
install -m 644 $(srcdir)conf/corosync.conf $(DESTDIR)$(ETCDIR) ; \
|
install -m 644 $(srcdir)conf/corosync.conf $(DESTDIR)$(ETCDIR) ; \
|
||||||
fi
|
fi
|
||||||
|
|
||||||
@@ -196,6 +203,7 @@
|
@@ -196,10 +191,13 @@
|
||||||
install -m 644 $(srcdir)include/corosync/engine/coroapi.h $(DESTDIR)$(INCLUDEDIR_ENGINE)
|
install -m 644 $(srcdir)include/corosync/engine/coroapi.h $(DESTDIR)$(INCLUDEDIR_ENGINE)
|
||||||
install -m 644 $(srcdir)include/corosync/engine/objdb.h $(DESTDIR)$(INCLUDEDIR_ENGINE)
|
install -m 644 $(srcdir)include/corosync/engine/objdb.h $(DESTDIR)$(INCLUDEDIR_ENGINE)
|
||||||
install -m 644 $(srcdir)include/corosync/engine/logsys.h $(DESTDIR)$(INCLUDEDIR_ENGINE)
|
install -m 644 $(srcdir)include/corosync/engine/logsys.h $(DESTDIR)$(INCLUDEDIR_ENGINE)
|
||||||
@ -14794,10 +14874,42 @@ diff -Naurd corosync-0.92/Makefile corosync-trunk/Makefile
|
|||||||
install -m 644 $(srcdir)include/corosync/engine/config.h $(DESTDIR)$(INCLUDEDIR_ENGINE)
|
install -m 644 $(srcdir)include/corosync/engine/config.h $(DESTDIR)$(INCLUDEDIR_ENGINE)
|
||||||
install -m 644 $(srcdir)man/*.3 $(DESTDIR)$(MANDIR)/man3
|
install -m 644 $(srcdir)man/*.3 $(DESTDIR)$(MANDIR)/man3
|
||||||
install -m 644 $(srcdir)man/*.5 $(DESTDIR)$(MANDIR)/man5
|
install -m 644 $(srcdir)man/*.5 $(DESTDIR)$(MANDIR)/man5
|
||||||
|
install -m 644 $(srcdir)man/*.8 $(DESTDIR)$(MANDIR)/man8
|
||||||
|
|
||||||
|
+ install -m 644 $(builddir)/pkgconfig/*.pc $(DESTDIR)$(PKGCONFIGDIR)
|
||||||
|
+
|
||||||
|
doxygen:
|
||||||
|
mkdir -p doc/api && doxygen
|
||||||
diff -Naurd corosync-0.92/Makefile.inc corosync-trunk/Makefile.inc
|
diff -Naurd corosync-0.92/Makefile.inc corosync-trunk/Makefile.inc
|
||||||
--- corosync-0.92/Makefile.inc 2008-09-03 09:58:08.000000000 +0200
|
--- corosync-0.92/Makefile.inc 2008-09-03 09:58:08.000000000 +0200
|
||||||
+++ corosync-trunk/Makefile.inc 2008-12-09 14:48:47.000000000 +0100
|
+++ corosync-trunk/Makefile.inc 2009-01-30 19:25:04.000000000 +0100
|
||||||
@@ -38,16 +38,15 @@
|
@@ -3,6 +3,25 @@
|
||||||
|
DESTDIR=
|
||||||
|
LCRSODIR=$(PREFIX)/libexec/lcrso
|
||||||
|
|
||||||
|
+ARCH=$(shell uname -p)
|
||||||
|
+ifeq (,$(findstring 64,$(ARCH)))
|
||||||
|
+PRELIBDIR=$(PREFIX)/lib
|
||||||
|
+else
|
||||||
|
+PRELIBDIR=$(PREFIX)/lib64
|
||||||
|
+endif
|
||||||
|
+ifeq (s390,$(ARCH))
|
||||||
|
+PRELIBDIR=$(PREFIX)/lib
|
||||||
|
+endif
|
||||||
|
+ifeq (s390x,$(ARCH))
|
||||||
|
+PRELIBDIR=$(PREFIX)/lib64
|
||||||
|
+endif
|
||||||
|
+ifeq (ia64,$(ARCH))
|
||||||
|
+PRELIBDIR=$(PREFIX)/lib
|
||||||
|
+endif
|
||||||
|
+
|
||||||
|
+LIBDIR=$(PRELIBDIR)/corosync
|
||||||
|
+PKGCONFIGDIR=$(PRELIBDIR)/pkgconfig
|
||||||
|
+
|
||||||
|
# Do not modify below this line
|
||||||
|
|
||||||
|
# Basic OS detection
|
||||||
|
@@ -38,16 +57,15 @@
|
||||||
# COROSYNC_BUILD can be defined as RELEASE or DEBUG
|
# COROSYNC_BUILD can be defined as RELEASE or DEBUG
|
||||||
#
|
#
|
||||||
ifndef COROSYNC_BUILD
|
ifndef COROSYNC_BUILD
|
||||||
@ -14816,7 +14928,7 @@ diff -Naurd corosync-0.92/Makefile.inc corosync-trunk/Makefile.inc
|
|||||||
|
|
||||||
override CFLAGS += -DLCRSODIR='"$(LCRSODIR)"'
|
override CFLAGS += -DLCRSODIR='"$(LCRSODIR)"'
|
||||||
|
|
||||||
@@ -58,35 +57,26 @@
|
@@ -58,35 +76,26 @@
|
||||||
# build CFLAGS, LDFLAGS
|
# build CFLAGS, LDFLAGS
|
||||||
#
|
#
|
||||||
ifeq (${COROSYNC_BUILD}, RELEASE)
|
ifeq (${COROSYNC_BUILD}, RELEASE)
|
||||||
@ -15982,9 +16094,78 @@ diff -Naurd corosync-0.92/man/votequorum_setvotes.3 corosync-trunk/man/votequoru
|
|||||||
+.BR votequorum_dispatch (3),
|
+.BR votequorum_dispatch (3),
|
||||||
+.BR votequorum_fd_get (3),
|
+.BR votequorum_fd_get (3),
|
||||||
+.PP
|
+.PP
|
||||||
|
diff -Naurd corosync-0.92/pkgconfig/libtemplate.pc.in corosync-trunk/pkgconfig/libtemplate.pc.in
|
||||||
|
--- corosync-0.92/pkgconfig/libtemplate.pc.in 1970-01-01 01:00:00.000000000 +0100
|
||||||
|
+++ corosync-trunk/pkgconfig/libtemplate.pc.in 2009-01-30 19:25:04.000000000 +0100
|
||||||
|
@@ -0,0 +1,11 @@
|
||||||
|
+prefix=@PREFIX@
|
||||||
|
+exec_prefix=${prefix}
|
||||||
|
+libdir=@LIBDIR@
|
||||||
|
+includedir=${prefix}/include
|
||||||
|
+
|
||||||
|
+Name: @LIB@
|
||||||
|
+Version: trunk
|
||||||
|
+Description: @LIB@
|
||||||
|
+Requires:
|
||||||
|
+Libs: -L${libdir} -l@LIB@
|
||||||
|
+Cflags: -I${includedir}
|
||||||
|
diff -Naurd corosync-0.92/pkgconfig/Makefile corosync-trunk/pkgconfig/Makefile
|
||||||
|
--- corosync-0.92/pkgconfig/Makefile 1970-01-01 01:00:00.000000000 +0100
|
||||||
|
+++ corosync-trunk/pkgconfig/Makefile 2009-01-30 19:25:04.000000000 +0100
|
||||||
|
@@ -0,0 +1,50 @@
|
||||||
|
+# Copyright (c) 2009 Red Hat, Inc.
|
||||||
|
+#
|
||||||
|
+# All rights reserved.
|
||||||
|
+#
|
||||||
|
+# This software licensed under BSD license, the text of which follows:
|
||||||
|
+#
|
||||||
|
+# Redistribution and use in source and binary forms, with or without
|
||||||
|
+# modification, are permitted provided that the following conditions are met:
|
||||||
|
+#
|
||||||
|
+# - Redistributions of source code must retain the above copyright notice,
|
||||||
|
+# this list of conditions and the following disclaimer.
|
||||||
|
+# - Redistributions in binary form must reproduce the above copyright notice,
|
||||||
|
+# this list of conditions and the following disclaimer in the documentation
|
||||||
|
+# and/or other materials provided with the distribution.
|
||||||
|
+# - Neither the name of the MontaVista Software, Inc. nor the names of its
|
||||||
|
+# contributors may be used to endorse or promote products derived from this
|
||||||
|
+# software without specific prior written permission.
|
||||||
|
+#
|
||||||
|
+# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
|
||||||
|
+# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
||||||
|
+# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
||||||
|
+# ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
|
||||||
|
+# LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
|
||||||
|
+# CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
|
||||||
|
+# SUBSTITUTE GOODS OR ENGINES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
|
||||||
|
+# INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
|
||||||
|
+# CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
|
||||||
|
+# ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
|
||||||
|
+# THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
|
+
|
||||||
|
+# Include configuration
|
||||||
|
+#
|
||||||
|
+srcdir ?= $(CURDIR)/../
|
||||||
|
+subdir ?= pkgconfig
|
||||||
|
+
|
||||||
|
+include $(srcdir)/Makefile.inc
|
||||||
|
+
|
||||||
|
+LIBS = evs cpg cfg coroutil confdb quorum votequorum totem_pg logsys
|
||||||
|
+
|
||||||
|
+all:
|
||||||
|
+ for i in $(LIBS); do \
|
||||||
|
+ cat ${srcdir}/pkgconfig/libtemplate.pc.in | sed \
|
||||||
|
+ -e 's#@PREFIX@#$(PREFIX)#g' \
|
||||||
|
+ -e 's#@LIBDIR@#$(LIBDIR)#g' \
|
||||||
|
+ -e 's#@LIB@#'$${i}'#g' \
|
||||||
|
+ > lib$${i}.pc; \
|
||||||
|
+ done;
|
||||||
|
+
|
||||||
|
+clean:
|
||||||
|
+ rm -f *.pc
|
||||||
diff -Naurd corosync-0.92/services/cfg.c corosync-trunk/services/cfg.c
|
diff -Naurd corosync-0.92/services/cfg.c corosync-trunk/services/cfg.c
|
||||||
--- corosync-0.92/services/cfg.c 2008-08-14 18:44:26.000000000 +0200
|
--- corosync-0.92/services/cfg.c 2008-08-14 18:44:26.000000000 +0200
|
||||||
+++ corosync-trunk/services/cfg.c 2009-01-19 09:31:21.000000000 +0100
|
+++ corosync-trunk/services/cfg.c 2009-01-30 12:56:34.000000000 +0100
|
||||||
@@ -1,13 +1,13 @@
|
@@ -1,13 +1,13 @@
|
||||||
/*
|
/*
|
||||||
* Copyright (c) 2005-2006 MontaVista Software, Inc.
|
* Copyright (c) 2005-2006 MontaVista Software, Inc.
|
||||||
@ -16838,7 +17019,7 @@ diff -Naurd corosync-0.92/services/cfg.c corosync-trunk/services/cfg.c
|
|||||||
+ char buf[PIPE_BUF];
|
+ char buf[PIPE_BUF];
|
||||||
+ char **status;
|
+ char **status;
|
||||||
+ unsigned int num_interfaces = 0;
|
+ unsigned int num_interfaces = 0;
|
||||||
+ int ret = 0;
|
+ int ret = CS_OK;
|
||||||
+ int i;
|
+ int i;
|
||||||
+ struct req_lib_cfg_get_node_addrs *req_lib_cfg_get_node_addrs = (struct req_lib_cfg_get_node_addrs *)msg;
|
+ struct req_lib_cfg_get_node_addrs *req_lib_cfg_get_node_addrs = (struct req_lib_cfg_get_node_addrs *)msg;
|
||||||
+ struct res_lib_cfg_get_node_addrs *res_lib_cfg_get_node_addrs = (struct res_lib_cfg_get_node_addrs *)buf;
|
+ struct res_lib_cfg_get_node_addrs *res_lib_cfg_get_node_addrs = (struct res_lib_cfg_get_node_addrs *)buf;
|
||||||
@ -18351,7 +18532,7 @@ diff -Naurd corosync-0.92/services/testquorum.c corosync-trunk/services/testquor
|
|||||||
+}
|
+}
|
||||||
diff -Naurd corosync-0.92/services/votequorum.c corosync-trunk/services/votequorum.c
|
diff -Naurd corosync-0.92/services/votequorum.c corosync-trunk/services/votequorum.c
|
||||||
--- corosync-0.92/services/votequorum.c 1970-01-01 01:00:00.000000000 +0100
|
--- corosync-0.92/services/votequorum.c 1970-01-01 01:00:00.000000000 +0100
|
||||||
+++ corosync-trunk/services/votequorum.c 2009-01-26 11:46:08.000000000 +0100
|
+++ corosync-trunk/services/votequorum.c 2009-01-29 15:21:05.000000000 +0100
|
||||||
@@ -0,0 +1,1619 @@
|
@@ -0,0 +1,1619 @@
|
||||||
+/*
|
+/*
|
||||||
+ * Copyright (c) 2009 Red Hat, Inc.
|
+ * Copyright (c) 2009 Red Hat, Inc.
|
||||||
@ -19483,10 +19664,10 @@ diff -Naurd corosync-0.92/services/votequorum.c corosync-trunk/services/votequor
|
|||||||
+ list_iterate(nodelist, &cluster_members_list) {
|
+ list_iterate(nodelist, &cluster_members_list) {
|
||||||
+ iternode = list_entry(nodelist, struct cluster_node, list);
|
+ iternode = list_entry(nodelist, struct cluster_node, list);
|
||||||
+
|
+
|
||||||
+ if (node->state == NODESTATE_MEMBER) {
|
+ if (iternode->state == NODESTATE_MEMBER) {
|
||||||
+ highest_expected =
|
+ highest_expected =
|
||||||
+ max(highest_expected, node->expected_votes);
|
+ max(highest_expected, iternode->expected_votes);
|
||||||
+ total_votes += node->votes;
|
+ total_votes += iternode->votes;
|
||||||
+ }
|
+ }
|
||||||
+ }
|
+ }
|
||||||
+
|
+
|
@ -1,14 +1,14 @@
|
|||||||
%define alphatag svn1750
|
%define alphatag svn1756
|
||||||
|
|
||||||
Name: corosync
|
Name: corosync
|
||||||
Summary: The Corosync Cluster Engine and Application Programming Interfaces
|
Summary: The Corosync Cluster Engine and Application Programming Interfaces
|
||||||
Version: 0.92
|
Version: 0.92
|
||||||
Release: 6%{?alphatag:.%{alphatag}}%{?dist}
|
Release: 7%{?alphatag:.%{alphatag}}%{?dist}
|
||||||
License: BSD
|
License: BSD
|
||||||
Group: System Environment/Base
|
Group: System Environment/Base
|
||||||
URL: http://www.openais.org
|
URL: http://www.openais.org
|
||||||
Source0: http://developer.osdl.org/dev/openais/downloads/corosync-%{version}/corosync-%{version}.tar.gz
|
Source0: http://developer.osdl.org/dev/openais/downloads/corosync-%{version}/corosync-%{version}.tar.gz
|
||||||
Patch0: corosync-trunk-1750.diff
|
Patch0: corosync-trunk.diff
|
||||||
|
|
||||||
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
||||||
Requires(pre): /usr/sbin/useradd
|
Requires(pre): /usr/sbin/useradd
|
||||||
@ -26,6 +26,7 @@ APIs and libraries, default configuration files, and an init script.
|
|||||||
Summary: The Corosync Cluster Engine
|
Summary: The Corosync Cluster Engine
|
||||||
Group: System Environment/Libraries
|
Group: System Environment/Libraries
|
||||||
Requires: %{name} = %{version}-%{release}
|
Requires: %{name} = %{version}-%{release}
|
||||||
|
Requires: pkgconfig
|
||||||
|
|
||||||
%description devel
|
%description devel
|
||||||
This package contains include files and man pages used to develop using
|
This package contains include files and man pages used to develop using
|
||||||
@ -154,6 +155,7 @@ fi
|
|||||||
%{_libdir}/corosync/libcoroutil.so
|
%{_libdir}/corosync/libcoroutil.so
|
||||||
%{_libdir}/corosync/libquorum.so
|
%{_libdir}/corosync/libquorum.so
|
||||||
%{_libdir}/corosync/libvotequorum.so
|
%{_libdir}/corosync/libvotequorum.so
|
||||||
|
%{_libdir}/pkgconfig/*.pc
|
||||||
%{_mandir}/man3/cpg_*3*
|
%{_mandir}/man3/cpg_*3*
|
||||||
%{_mandir}/man3/evs_*3*
|
%{_mandir}/man3/evs_*3*
|
||||||
%{_mandir}/man3/confdb_*3*
|
%{_mandir}/man3/confdb_*3*
|
||||||
@ -165,6 +167,10 @@ fi
|
|||||||
%{_mandir}/man8/votequorum_overview.8*
|
%{_mandir}/man8/votequorum_overview.8*
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Mon Feb 2 2009 Fabio M. Di Nitto <fdinitto@redhat.com> - 0.92-7.svn1756
|
||||||
|
- Update to svn trunk at revision 1756 from upstream.
|
||||||
|
- Add support pkgconfig to devel package.
|
||||||
|
|
||||||
* Tue Jan 27 2009 Fabio M. Di Nitto <fdinitto@redhat.com> - 0.92-6.svn1750
|
* Tue Jan 27 2009 Fabio M. Di Nitto <fdinitto@redhat.com> - 0.92-6.svn1750
|
||||||
- Update to svn trunk at revision 1750 from upstream.
|
- Update to svn trunk at revision 1750 from upstream.
|
||||||
- Include new quorum service in the packaging.
|
- Include new quorum service in the packaging.
|
||||||
|
Loading…
Reference in New Issue
Block a user