From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-9.0 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_PATCH,MAILING_LIST_MULTI,SIGNED_OFF_BY,SPF_PASS,URIBL_BLOCKED, USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id D9FDCECDE4B for ; Thu, 8 Nov 2018 19:56:35 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 9F0E52081C for ; Thu, 8 Nov 2018 19:56:35 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 9F0E52081C Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=alien8.de Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726962AbeKIFdd (ORCPT ); Fri, 9 Nov 2018 00:33:33 -0500 Received: from mail.skyhub.de ([5.9.137.197]:47808 "EHLO mail.skyhub.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725764AbeKIFdd (ORCPT ); Fri, 9 Nov 2018 00:33:33 -0500 X-Virus-Scanned: Nedap ESD1 at mail.skyhub.de Received: from mail.skyhub.de ([127.0.0.1]) by localhost (blast.alien8.de [127.0.0.1]) (amavisd-new, port 10026) with ESMTP id RgchpIW6QK3B; Thu, 8 Nov 2018 20:56:32 +0100 (CET) Received: from zn.tnic (p200300EC2BD03D00329C23FFFEA6A903.dip0.t-ipconnect.de [IPv6:2003:ec:2bd0:3d00:329c:23ff:fea6:a903]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.skyhub.de (SuperMail on ZX Spectrum 128k) with ESMTPSA id DE1E91EC0755; Thu, 8 Nov 2018 20:56:31 +0100 (CET) From: Borislav Petkov To: LKML Cc: Masahiro Yamada , Michal Marek , linux-kbuild@vger.kernel.org Subject: [PATCH] kbuild/builddeb: Fix building .deb packages out-of-tree Date: Thu, 8 Nov 2018 20:56:24 +0100 Message-Id: <20181108195624.25410-1-bp@alien8.de> X-Mailer: git-send-email 2.19.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Borislav Petkov When building a .deb package with make O=/tmp/b oldconfig cd /tmp/b make bindeb-pkg the build fails with fakeroot -u debian/rules binary *** *** Configuration file ".config" not found! *** *** Please run some configurator (e.g. "make oldconfig" or *** "make menuconfig" or "make xconfig"). *** make[12]: *** [/mnt/kernel/kernel/linux/scripts/kconfig/Makefile:69: syncconfig] Error 1 make[11]: *** [/mnt/kernel/kernel/linux/Makefile:544: syncconfig] Error 2 make[10]: *** [Makefile:640: include/config/auto.conf] Error 2 make[9]: *** [Makefile:15: __sub-make] Error 2 because ($MAKE -s image_name) in the subshell is missing KBUILD_SRC and cannot find .config. Passing in KBUILD_SRC= for the current pwd fixes the build. Signed-off-by: Borislav Petkov Cc: Masahiro Yamada Cc: Michal Marek Cc: --- scripts/package/builddeb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/package/builddeb b/scripts/package/builddeb index 90c9a8ac7adb..149bbbd8e98d 100755 --- a/scripts/package/builddeb +++ b/scripts/package/builddeb @@ -81,7 +81,7 @@ else cp System.map "$tmpdir/boot/System.map-$version" cp $KCONFIG_CONFIG "$tmpdir/boot/config-$version" fi -cp "$($MAKE -s image_name)" "$tmpdir/$installed_image_path" +cp "$($MAKE KBUILD_SRC= -s image_name)" "$tmpdir/$installed_image_path" if grep -q "^CONFIG_OF=y" $KCONFIG_CONFIG ; then # Only some architectures with OF support have this target -- 2.19.1