From patchwork Thu Jan 7 21:53:54 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Robert Jarzmik X-Patchwork-Id: 7980001 Return-Path: X-Original-To: patchwork-linux-kbuild@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 714B39F38D for ; Thu, 7 Jan 2016 22:01:33 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 8FC2A2013D for ; Thu, 7 Jan 2016 22:01:32 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 554F52012E for ; Thu, 7 Jan 2016 22:01:31 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753397AbcAGWBa (ORCPT ); Thu, 7 Jan 2016 17:01:30 -0500 Received: from smtp02.smtpout.orange.fr ([80.12.242.124]:33213 "EHLO smtp.smtpout.orange.fr" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753194AbcAGWBa (ORCPT ); Thu, 7 Jan 2016 17:01:30 -0500 X-Greylist: delayed 450 seconds by postgrey-1.27 at vger.kernel.org; Thu, 07 Jan 2016 17:01:29 EST Received: from belgarion ([90.16.86.215]) by mwinf5d56 with ME id 39tu1s00g4elfN2039tv10; Thu, 07 Jan 2016 22:53:56 +0100 X-ME-Helo: belgarion X-ME-Auth: amFyem1pay5yb2JlcnRAb3JhbmdlLmZy X-ME-Date: Thu, 07 Jan 2016 22:53:56 +0100 X-ME-IP: 90.16.86.215 From: Robert Jarzmik To: Michal Marek Cc: linux-kbuild Subject: Re: kbuild: global makefile and spaces in path References: <87lh8nfrx8.fsf@belgarion.home> <568D2927.2010106@suse.com> X-URL: http://belgarath.falguerolles.org/ Date: Thu, 07 Jan 2016 22:53:54 +0100 In-Reply-To: <568D2927.2010106@suse.com> (Michal Marek's message of "Wed, 6 Jan 2016 15:48:07 +0100") Message-ID: <87mvshdpjh.fsf@belgarion.home> User-Agent: Gnus/5.130008 (Ma Gnus v0.8) Emacs/24.4 (gnu/linux) MIME-Version: 1.0 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,FREEMAIL_FROM, RCVD_IN_DNSWL_HI, 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 Michal Marek writes: > On 2015-12-21 21:49, Robert Jarzmik wrote: >> Hi Michal, >> >> I compiled my kernel in a directory /home/robert jarzmik/kernel, and that's the >> first time I encountered a space in the path containing my kernel in years. >> >> I was wondering if there is a known constraint that the linux kernel source >> should be contained within a path without any space ? > Whitespace and colons are problematic. Ok. >> If no such constraint is known, maybe you could consider the patch in [1]. > I expect it is going to break in lot more places, especially if you do > an O= build. I think it's better to just check for this and error out early. Ok, I'll try to do that. Let's see if the patch at the end of this mail is what you're expecting. Cheers. diff --git a/Makefile b/Makefile index 45ec34644b4f..72e9b7371b0d 100644 --- a/Makefile +++ b/Makefile @@ -128,6 +128,10 @@ _all: # Cancel implicit rules on top Makefile $(CURDIR)/Makefile Makefile: ; +ifneq ($(words $(CURDIR)),1) + $(error main directory cannot contain spaces) +endif + ifneq ($(KBUILD_OUTPUT),) # Invoke a second make in the output directory, passing relevant variables # check that the output directory actually exists