From patchwork Thu Mar 5 13:38:41 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Michal Simek X-Patchwork-Id: 5946131 Return-Path: X-Original-To: patchwork-linux-kbuild@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id CEC4EBF440 for ; Thu, 5 Mar 2015 13:39:08 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id EFAD720380 for ; Thu, 5 Mar 2015 13:39:07 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 1697F2034A for ; Thu, 5 Mar 2015 13:39:07 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754908AbbCENiv (ORCPT ); Thu, 5 Mar 2015 08:38:51 -0500 Received: from mail-pd0-f175.google.com ([209.85.192.175]:39055 "EHLO mail-pd0-f175.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753435AbbCENiu (ORCPT ); Thu, 5 Mar 2015 08:38:50 -0500 Received: by pdbft15 with SMTP id ft15so5967363pdb.6 for ; Thu, 05 Mar 2015 05:38:50 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id; bh=T201O5tlclVFoausDwFR0O4B3rlEEGa45Ve3jy8RU40=; b=FfOFDrLSv2kRHCf6NcSJmEB/Bw1LfUzN3vM2fbdn7s/jsK4nvJhlAv+xOrudaAw3hq uOZWac8qX5eAXpV7pUpdiVNb8m91kOjWNYnf+IXSUaKyiuNu/S+9DIEUPrcmoPjdjCp0 FKMbUMdjPmITOjXBMM66zxJHht4CKIB+P9Uzts/cy4HmCZFnE3d/QhmsaJuQvzmljYsK evgLGmeuRJY97mrNyxO1yNTW6tGH9y/mw9ZZV5QCnq3XcbbWyka1nOuNA/FbE1kV9ZAq pWh8SWM2asY43VA2H/4q81tCEGrxXpfq5C34fv8HD0erPgk1NTxHpNmYrLzYtS0ERAIU CLwQ== X-Gm-Message-State: ALoCoQldCqm7a4IB14zjkeQH3nLaL8jLZYrghDex/pSN6V4xn5dl+Rqpn10CqVSLA6pY2FX3OTky X-Received: by 10.70.38.163 with SMTP id h3mr15831308pdk.95.1425562730182; Thu, 05 Mar 2015 05:38:50 -0800 (PST) Received: from localhost (nat-35.starnet.cz. [178.255.168.35]) by mx.google.com with ESMTPSA id zc3sm7001116pbb.46.2015.03.05.05.38.47 (version=TLSv1.1 cipher=RC4-SHA bits=128/128); Thu, 05 Mar 2015 05:38:49 -0800 (PST) From: Michal Simek To: linux-kernel@vger.kernel.org, monstr@monstr.eu Cc: Zach Pfeffer , Nathan Rossi , Arnd Bergmann , catalin.marinas@arm.com, will.deacon@arm.com, Nathan Rossi , Michal Marek , linux-kbuild@vger.kernel.org Subject: [PATCH] kbuild: Create directory for target DTB Date: Thu, 5 Mar 2015 14:38:41 +0100 Message-Id: X-Mailer: git-send-email 1.8.2.3 Sender: linux-kbuild-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kbuild@vger.kernel.org X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Nathan Rossi When building specific DTBs out of the kernel tree the vendor subdirs (boot/dts/) are not created, ensure that they are before building the DTB. Signed-off-by: Nathan Rossi Signed-off-by: Michal Simek --- Problem is visible with arm64 for out of tree builds. make O=/tmp/kkk/ defconfig make O=/tmp/kkk/ cavium/thunder-88xx.dtb DTC arch/arm64/boot/dts/cavium/thunder-88xx.dtb cc1: fatal error: opening output file arch/arm64/boot/dts/cavium/.thunder-88xx.dtb.dts.tmp: No such file or directory compilation terminated. make[2]: *** [arch/arm64/boot/dts/cavium/thunder-88xx.dtb] Error 1 make[1]: *** [cavium/thunder-88xx.dtb] Error 2 Building specific dtb target on arm32 is working fine make O=/tmp/kkk4/ multi_v7_defconfig make O=/tmp/kkk4/ zynq-zc702.dtb This is the way how Yocto is building dtb for specific target. --- scripts/Makefile.lib | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/scripts/Makefile.lib b/scripts/Makefile.lib index 044eb4f89a91..6e3356005ec4 100644 --- a/scripts/Makefile.lib +++ b/scripts/Makefile.lib @@ -282,7 +282,8 @@ $(obj)/%.dtb.S: $(obj)/%.dtb $(call cmd,dt_S_dtb) quiet_cmd_dtc = DTC $@ -cmd_dtc = $(CPP) $(dtc_cpp_flags) -x assembler-with-cpp -o $(dtc-tmp) $< ; \ +cmd_dtc = mkdir -p `dirname ${dtc-tmp}` ; \ + $(CPP) $(dtc_cpp_flags) -x assembler-with-cpp -o $(dtc-tmp) $< ; \ $(objtree)/scripts/dtc/dtc -O dtb -o $@ -b 0 \ -i $(dir $<) $(DTC_FLAGS) \ -d $(depfile).dtc.tmp $(dtc-tmp) ; \