From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751680AbcDUE16 (ORCPT ); Thu, 21 Apr 2016 00:27:58 -0400 Received: from mx1.redhat.com ([209.132.183.28]:50889 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750864AbcDUE14 (ORCPT ); Thu, 21 Apr 2016 00:27:56 -0400 Date: Thu, 21 Apr 2016 00:27:51 -0400 From: Josh Poimboeuf To: Steven Rostedt Cc: Thomas Gleixner , Ingo Molnar , "H. Peter Anvin" , x86@kernel.org, linux-kernel@vger.kernel.org, live-patching@vger.kernel.org, Michal Marek , Peter Zijlstra , Andy Lutomirski , Borislav Petkov , Linus Torvalds , Andi Kleen , Pedro Alves , Namhyung Kim , Bernd Petrovitsch , Chris J Arges , Andrew Morton , Jiri Slaby , Arnaldo Carvalho de Melo Subject: Re: [PATCH] objtool: Fix Makefile to properly see if libelf is supported Message-ID: <20160421042751.is4hf6afh3kcnc4a@treble> References: <20160420153234.GA24032@home.goodmis.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20160420153234.GA24032@home.goodmis.org> User-Agent: Mutt/1.6.0.1 (2016-04-01) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Apr 20, 2016 at 11:32:35AM -0400, Steven Rostedt wrote: > When doing a make allmodconfig, I hit the following compile error: > > In file included from builtin-check.c:32:0: > elf.h:22:18: fatal error: gelf.h: No such file or directory > compilation terminated. > In file included from special.h:22:0, > from special.c:26: > elf.h:22:18: fatal error: gelf.h: No such file or directory > compilation terminated. > In file included from elf.c:30:0: > elf.h:22:18: fatal error: gelf.h: No such file or directory > compilation terminated. > mv: cannot stat 'tools/objtool/.elf.o.tmp': No such file or directory > tools/build/Makefile.build:77: recipe for target 'tools/objtool/elf.o' failed > make[4]: *** [tools/objtool/elf.o] Error 1 > make[4]: *** Waiting for unfinished jobs.... > > Digging into it, it appears that the $(shell ..) command in the Makefile does > not give the proper result when it fails to find -lelf, and continues to > compile objtool. > > Instead, use the "try-run" makefile macro to perform the test. This gives a > proper result for both cases. > > Fixes: 442f04c34a1a4 ("objtool: Add tool to perform compile-time stack metadata validation") > Signed-off-by: Steven Rostedt Thanks! Acked-by: Josh Poimboeuf -- Josh