From 17273b73d6d9e1d7ff475f698d167a9e313bba4d Mon Sep 17 00:00:00 2001 From: Dmitry Vyukov Date: Tue, 17 Dec 2019 11:15:08 +0100 Subject: sys/syz-extract: don't redefine __asm__ in ELF mode MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This is not necessary since we build legit object file for the target binary now. But this breaks mips with: /linux/arch/mips/include/asm/thread_info.h:53:30: error: register name not specified for ‘__current_thread_info’ register struct thread_info *__current_thread_info __asm__("$28"); So just remove the old hack. Follow up to #1536 --- sys/syz-extract/fetch.go | 2 ++ 1 file changed, 2 insertions(+) (limited to 'sys') diff --git a/sys/syz-extract/fetch.go b/sys/syz-extract/fetch.go index 405b0167f..9b09477fb 100644 --- a/sys/syz-extract/fetch.go +++ b/sys/syz-extract/fetch.go @@ -172,7 +172,9 @@ func extractFromELF(binFile string) ([]uint64, error) { } var srcTemplate = template.Must(template.New("").Parse(` +{{if not .ExtractFromELF}} #define __asm__(...) +{{end}} {{if .DefineGlibcUse}} #ifndef __GLIBC_USE -- cgit mrf-deployment