aboutsummaryrefslogtreecommitdiff
path: root/system/dlm/patches
diff options
context:
space:
mode:
authorMario Preksavec <mario at slackware dot hr>2019-05-18 06:43:50 +0700
committerWilly Sudiarto Raharjo <willysr@slackbuilds.org>2019-05-18 06:43:50 +0700
commit4d8764c7cb268c2946c4e7b646fea759671825b1 (patch)
treeb2007ac79f0d96adeb3c619e078c2bdea9aeaee7 /system/dlm/patches
parent832fba7887d31db10bf533579caad343531896e7 (diff)
system/dlm: Added (Distributed Lock Manager).
Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
Diffstat (limited to 'system/dlm/patches')
-rw-r--r--system/dlm/patches/Check-sscanf-return-value.patch24
-rw-r--r--system/dlm/patches/Debian-path-for-the-config-file.patch21
-rw-r--r--system/dlm/patches/Don-t-link-dlm_stonith-against-libxml2.patch20
-rw-r--r--system/dlm/patches/Enable-systemctl-help-dlm-to-show-relevant-man-pages.patch20
-rw-r--r--system/dlm/patches/Use-CPPFLAGS-from-the-environment.patch71
-rw-r--r--system/dlm/patches/series5
6 files changed, 161 insertions, 0 deletions
diff --git a/system/dlm/patches/Check-sscanf-return-value.patch b/system/dlm/patches/Check-sscanf-return-value.patch
new file mode 100644
index 0000000000000..719e294fca39e
--- /dev/null
+++ b/system/dlm/patches/Check-sscanf-return-value.patch
@@ -0,0 +1,24 @@
+From: Valentin Vidic <Valentin.Vidic@CARNet.hr>
+Date: Wed, 25 Apr 2018 23:13:29 +0200
+Subject: Check sscanf return value
+
+---
+ dlm_tool/main.c | 5 +++++
+ 1 file changed, 5 insertions(+)
+
+diff --git a/dlm_tool/main.c b/dlm_tool/main.c
+index 042caa9..1900236 100644
+--- a/dlm_tool/main.c
++++ b/dlm_tool/main.c
+@@ -692,6 +692,11 @@ static void print_lkb(char *line, struct rinfo *ri)
+ (unsigned long long *)&lkb.timestamp,
+ (unsigned long long *)&lkb.time_bast);
+
++ if (rv != 17) {
++ fprintf(stderr, "print_lkb error rv %d line \"%s\"\n", rv, line);
++ return;
++ }
++
+ ri->lkb_count++;
+
+ if (lkb.status == DLM_LKSTS_GRANTED) {
diff --git a/system/dlm/patches/Debian-path-for-the-config-file.patch b/system/dlm/patches/Debian-path-for-the-config-file.patch
new file mode 100644
index 0000000000000..f59ee39ca0c76
--- /dev/null
+++ b/system/dlm/patches/Debian-path-for-the-config-file.patch
@@ -0,0 +1,21 @@
+From: =?utf-8?q?Ferenc_W=C3=A1gner?= <wferi@niif.hu>
+Date: Sun, 30 Aug 2015 16:48:15 +0200
+Subject: Debian path for the config file
+
+---
+ init/dlm.service | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/init/dlm.service b/init/dlm.service
+index 1db5925..5cd01c5 100644
+--- a/init/dlm.service
++++ b/init/dlm.service
+@@ -7,7 +7,7 @@ After=corosync.service sys-kernel-config.mount
+ OOMScoreAdjust=-1000
+ Type=notify
+ NotifyAccess=main
+-EnvironmentFile=/etc/sysconfig/dlm
++EnvironmentFile=-/etc/default/dlm
+ ExecStartPre=/sbin/modprobe dlm
+ ExecStart=/usr/sbin/dlm_controld --foreground $DLM_CONTROLD_OPTS
+ #ExecStopPost=/sbin/modprobe -r dlm
diff --git a/system/dlm/patches/Don-t-link-dlm_stonith-against-libxml2.patch b/system/dlm/patches/Don-t-link-dlm_stonith-against-libxml2.patch
new file mode 100644
index 0000000000000..11a4a4091b7fa
--- /dev/null
+++ b/system/dlm/patches/Don-t-link-dlm_stonith-against-libxml2.patch
@@ -0,0 +1,20 @@
+From: =?utf-8?q?Ferenc_W=C3=A1gner?= <wferi@debian.org>
+Date: Mon, 19 Dec 2016 22:57:22 +0100
+Subject: Don't link dlm_stonith against libxml2
+
+---
+ fence/Makefile | 1 -
+ 1 file changed, 1 deletion(-)
+
+diff --git a/fence/Makefile b/fence/Makefile
+index d4a3c09..1382260 100644
+--- a/fence/Makefile
++++ b/fence/Makefile
+@@ -22,7 +22,6 @@ CFLAGS += `xml2-config --cflags`
+ CFLAGS += -I../include
+
+ LDFLAGS += -Wl,-z,relro -pie
+-LDFLAGS += `xml2-config --libs`
+ LDFLAGS += -ldl
+
+ all: $(BIN_TARGET)
diff --git a/system/dlm/patches/Enable-systemctl-help-dlm-to-show-relevant-man-pages.patch b/system/dlm/patches/Enable-systemctl-help-dlm-to-show-relevant-man-pages.patch
new file mode 100644
index 0000000000000..8e4fba92700a3
--- /dev/null
+++ b/system/dlm/patches/Enable-systemctl-help-dlm-to-show-relevant-man-pages.patch
@@ -0,0 +1,20 @@
+From: =?utf-8?q?Ferenc_W=C3=A1gner?= <wferi@niif.hu>
+Date: Wed, 27 Apr 2016 12:00:43 +0200
+Subject: Enable systemctl help dlm to show relevant man pages
+
+---
+ init/dlm.service | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/init/dlm.service b/init/dlm.service
+index 5cd01c5..5854738 100644
+--- a/init/dlm.service
++++ b/init/dlm.service
+@@ -2,6 +2,7 @@
+ Description=dlm control daemon
+ Requires=corosync.service sys-kernel-config.mount
+ After=corosync.service sys-kernel-config.mount
++Documentation=man:dlm_controld man:dlm.conf man:dlm_stonith
+
+ [Service]
+ OOMScoreAdjust=-1000
diff --git a/system/dlm/patches/Use-CPPFLAGS-from-the-environment.patch b/system/dlm/patches/Use-CPPFLAGS-from-the-environment.patch
new file mode 100644
index 0000000000000..7f32d838d25d3
--- /dev/null
+++ b/system/dlm/patches/Use-CPPFLAGS-from-the-environment.patch
@@ -0,0 +1,71 @@
+From: =?utf-8?q?Ferenc_W=C3=A1gner?= <wferi@debian.org>
+Date: Mon, 19 Dec 2016 21:36:05 +0100
+Subject: Use CPPFLAGS from the environment
+
+---
+ dlm_controld/Makefile | 4 ++--
+ dlm_tool/Makefile | 2 +-
+ fence/Makefile | 2 +-
+ libdlm/Makefile | 4 ++--
+ 4 files changed, 6 insertions(+), 6 deletions(-)
+
+diff --git a/dlm_controld/Makefile b/dlm_controld/Makefile
+index 75c5750..47af929 100644
+--- a/dlm_controld/Makefile
++++ b/dlm_controld/Makefile
+@@ -58,10 +58,10 @@ endif
+ all: $(LIB_TARGET) $(BIN_TARGET)
+
+ $(BIN_TARGET): $(BIN_SOURCE)
+- $(CC) $(BIN_SOURCE) $(BIN_CFLAGS) $(BIN_LDFLAGS) -o $@ -L.
++ $(CC) $(CPPFLAGS) $(BIN_SOURCE) $(BIN_CFLAGS) $(BIN_LDFLAGS) -o $@ -L.
+
+ $(LIB_TARGET): $(LIB_SOURCE)
+- $(CC) $^ $(LIB_CFLAGS) $(LIB_LDFLAGS) -shared -o $@ -Wl,-soname=$(LIB_SMAJOR)
++ $(CC) $(CPPFLAGS) $^ $(LIB_CFLAGS) $(LIB_LDFLAGS) -shared -o $@ -Wl,-soname=$(LIB_SMAJOR)
+ ln -sf $(LIB_TARGET) $(LIB_SO)
+ ln -sf $(LIB_TARGET) $(LIB_SMAJOR)
+
+diff --git a/dlm_tool/Makefile b/dlm_tool/Makefile
+index 80d7725..a9b3be0 100644
+--- a/dlm_tool/Makefile
++++ b/dlm_tool/Makefile
+@@ -27,7 +27,7 @@ LDFLAGS += -lpthread -ldlm -ldlmcontrol
+ all: $(BIN_TARGET)
+
+ $(BIN_TARGET): $(BIN_SOURCE)
+- $(CC) $(BIN_SOURCE) $(CFLAGS) $(LDFLAGS) -o $@
++ $(CC) $(CPPFLAGS) $(BIN_SOURCE) $(CFLAGS) $(LDFLAGS) -o $@
+
+ clean:
+ rm -f *.o *.so *.so.* $(BIN_TARGET)
+diff --git a/fence/Makefile b/fence/Makefile
+index b927879..d4a3c09 100644
+--- a/fence/Makefile
++++ b/fence/Makefile
+@@ -28,7 +28,7 @@ LDFLAGS += -ldl
+ all: $(BIN_TARGET)
+
+ $(BIN_TARGET): $(BIN_SOURCE)
+- $(CC) $(BIN_SOURCE) $(CFLAGS) $(LDFLAGS) -o $@ -L.
++ $(CC) $(CPPFLAGS) $(BIN_SOURCE) $(CFLAGS) $(LDFLAGS) -o $@ -L.
+
+ clean:
+ rm -f *.o *.so *.so.* $(BIN_TARGET)
+diff --git a/libdlm/Makefile b/libdlm/Makefile
+index ab32761..21addf8 100644
+--- a/libdlm/Makefile
++++ b/libdlm/Makefile
+@@ -90,10 +90,10 @@ LLT_LDFLAGS += $(LDFLAGS)
+ all: $(LIB_TARGET) $(LLT_TARGET) $(LIB_PC) $(LLT_PC)
+
+ $(LIB_O): $(SOURCE)
+- $(CC) $< $(LIB_CFLAGS) -c -o $@
++ $(CC) $(CPPFLAGS) $< $(LIB_CFLAGS) -c -o $@
+
+ $(LLT_O): $(SOURCE)
+- $(CC) $< $(LLT_CFLAGS) -c -o $@
++ $(CC) $(CPPFLAGS) $< $(LLT_CFLAGS) -c -o $@
+
+ $(LIB_TARGET): $(LIB_O)
+ $(CC) $^ $(LIB_LDFLAGS) -shared -o $@ -Wl,-soname=$(LIB_SMAJOR)
diff --git a/system/dlm/patches/series b/system/dlm/patches/series
new file mode 100644
index 0000000000000..3b61b57b9b177
--- /dev/null
+++ b/system/dlm/patches/series
@@ -0,0 +1,5 @@
+Debian-path-for-the-config-file.patch
+Enable-systemctl-help-dlm-to-show-relevant-man-pages.patch
+Use-CPPFLAGS-from-the-environment.patch
+Don-t-link-dlm_stonith-against-libxml2.patch
+Check-sscanf-return-value.patch