From: Jim Fehlig jfehlig@suse.com
While packaging sanlock 5.0.0, I attempted to work around the link errors introduced in commit e68723c12a by adding
export LDFLAGS="-Wl,--no-undefined"
to %build of the spec file. I noticed my LDFLAGS were not honored when building fence_sanlock. Fix by appending to LDFLAGS in fence_sanlock/Makefile, instead of overwriting. While at it, make the same change to LDADD.
Signed-off-by: Jim Fehlig jfehlig@suse.com --- fence_sanlock/Makefile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/fence_sanlock/Makefile b/fence_sanlock/Makefile index 14bbe13..778530c 100644 --- a/fence_sanlock/Makefile +++ b/fence_sanlock/Makefile @@ -34,8 +34,8 @@ VER=$(shell cat ../VERSION) CFLAGS += -DVERSION="$(VER)" -I../src -I../wdmd CFLAGS += -fPIE -DPIE
-LDFLAGS = -Wl,-z,now -Wl,-z,relro -pie -LDADD = -lrt -laio -lblkid -lsanlock -lwdmd +LDFLAGS += -Wl,-z,now -Wl,-z,relro -pie +LDADD += -lrt -laio -lblkid -lsanlock -lwdmd
all: $(TARGET1) $(TARGET2)
On Thu, Mar 19, 2026 at 03:30:53PM -0600, Jim Fehlig via sanlock-devel wrote:
From: Jim Fehlig jfehlig@suse.com
While packaging sanlock 5.0.0, I attempted to work around the link errors introduced in commit e68723c12a by adding
export LDFLAGS="-Wl,--no-undefined"
to %build of the spec file. I noticed my LDFLAGS were not honored when building fence_sanlock. Fix by appending to LDFLAGS in fence_sanlock/Makefile, instead of overwriting. While at it, make the same change to LDADD.
I've been unsure about what to do about outdated parts of the sanlock repo like this. I'd been reluctant to use git rm, because finding it again for reference can be a pain (or someone new may not know it ever existed to look for it.) I'm thinking about moving the folling dirs into a "retired" directory with a README explaining their status.
"fence_sanlock": POC, not fully developed, never used, abandoned shortly after being written well over a decade ago.
"reset": another POC that was never used.
"python": became outdated after the only user went away.
Dave
On 3/19/26 4:12 PM, David Teigland wrote:
On Thu, Mar 19, 2026 at 03:30:53PM -0600, Jim Fehlig via sanlock-devel wrote:
From: Jim Fehlig jfehlig@suse.com
While packaging sanlock 5.0.0, I attempted to work around the link errors introduced in commit e68723c12a by adding
export LDFLAGS="-Wl,--no-undefined"
to %build of the spec file. I noticed my LDFLAGS were not honored when building fence_sanlock. Fix by appending to LDFLAGS in fence_sanlock/Makefile, instead of overwriting. While at it, make the same change to LDADD.
I've been unsure about what to do about outdated parts of the sanlock repo like this. I'd been reluctant to use git rm, because finding it again for reference can be a pain (or someone new may not know it ever existed to look for it.) I'm thinking about moving the folling dirs into a "retired" directory with a README explaining their status.
"fence_sanlock": POC, not fully developed, never used, abandoned shortly after being written well over a decade ago.
"reset": another POC that was never used.
"python": became outdated after the only user went away.
I was not aware of the status of these components. Thanks a lot for the clarification!
Regards, Jim
sanlock-devel@lists.fedorahosted.org