2020-12-15 23:11:58

by Hauke Mehrtens

[permalink] [raw]
Subject: [PATCH e2fsprogs] build: Add SYSLIBS to e4crypt linking

The $(SYSLIBS) was missing when linking the e4crypt application. This is
available in the e4crypt.profiled variant, so I assume this was just
missing in the normal variant and is not left out intentionally.

This fixes building e2fsprogrs with -fsanitize=undefined in the global
CFLAGS nad LDFLAGS.

Signed-off-by: Hauke Mehrtens <[email protected]>
---
misc/Makefile.in | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/misc/Makefile.in b/misc/Makefile.in
index fde01775..ae1fc42e 100644
--- a/misc/Makefile.in
+++ b/misc/Makefile.in
@@ -248,7 +248,7 @@ e4defrag: $(E4DEFRAG_OBJS) $(DEPLIBS)
e4crypt: $(E4CRYPT_OBJS) $(DEPLIBS) $(DEPSTATIC_LIBUUID)
$(E) " LD $@"
$(Q) $(CC) $(ALL_LDFLAGS) -o e4crypt $(E4CRYPT_OBJS) \
- $(LIBUUID) $(LIBS)
+ $(LIBUUID) $(LIBS) $(SYSLIBS)

e4defrag.profiled: $(E4DEFRAG_OBJS) $(PROFILED_DEPLIBS)
$(E) " LD $@"
--
2.20.1


2021-01-21 23:28:52

by Theodore Ts'o

[permalink] [raw]
Subject: Re: [PATCH e2fsprogs] build: Add SYSLIBS to e4crypt linking

On Wed, Dec 16, 2020 at 12:05:57AM +0100, Hauke Mehrtens wrote:
> The $(SYSLIBS) was missing when linking the e4crypt application. This is
> available in the e4crypt.profiled variant, so I assume this was just
> missing in the normal variant and is not left out intentionally.

Thanks, I've applied. It was left out unintentionally, although I
don't see how this is affecting building e2fsprogs with
-fsanitize=undefined in the global CFLAGS and LDFLAGS. (Which worked
for me both before and after applying this change.)

- Ted