lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Date:   Wed, 16 Nov 2016 19:28:39 -0500 (EST)
From:   Nicolas Pitre <nicolas.pitre@...aro.org>
To:     Michal Marek <mmarek@...e.com>
cc:     linux-kbuild@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: [PATCH] kbuild: cmd_export_list: tighten the sed script


When LTO is used, some ___ksymtab_string sections are seen by this sed
script, creating lines containing a single ) such as:

EXPORT(foo)
)
)
EXPORT(bar)

Let's make it so the + character is also required for any line to be
printed.

Signed-off-by: Nicolas Pitre <nico@...aro.org>

diff --git a/scripts/Makefile.build b/scripts/Makefile.build
index 53b43f26bb..3066c8e61d 100644
--- a/scripts/Makefile.build
+++ b/scripts/Makefile.build
@@ -428,7 +428,7 @@ endif
 
 quiet_cmd_export_list = EXPORTS $@
 cmd_export_list = $(OBJDUMP) -h $< | \
-	sed -ne '/___ksymtab/{s/.*+/$(ref_prefix)/;s/ .*/)/;p}' >$(ksyms-lds);\
+	sed -ne '/___ksymtab/s/.*+\([^ ]*\).*/$(ref_prefix)\1)/p' >$(ksyms-lds);\
 	rm -f $(dummy-object);\
 	$(AR) rcs$(KBUILD_ARFLAGS) $(dummy-object);\
 	$(LD) $(ld_flags) -r -o $@ -T $(ksyms-lds) $(dummy-object);\

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ