From patchwork Mon Nov 21 16:15:29 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Ga=C3=ABl_PORTAY?= X-Patchwork-Id: 697308 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from whitealder.osuosl.org (smtp1.osuosl.org [140.211.166.138]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 3tMtxS5sb0z9rvt for ; Tue, 22 Nov 2016 03:15:40 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by whitealder.osuosl.org (Postfix) with ESMTP id 734A98587A; Mon, 21 Nov 2016 16:15:37 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from whitealder.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id trzmNQi3iYLX; Mon, 21 Nov 2016 16:15:35 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by whitealder.osuosl.org (Postfix) with ESMTP id 516B085823; Mon, 21 Nov 2016 16:15:35 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from silver.osuosl.org (smtp3.osuosl.org [140.211.166.136]) by ash.osuosl.org (Postfix) with ESMTP id CF5541BFEE6 for ; Mon, 21 Nov 2016 16:15:34 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by silver.osuosl.org (Postfix) with ESMTP id C5D7F234DB for ; Mon, 21 Nov 2016 16:15:34 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from silver.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 9WzgT7cxsscz for ; Mon, 21 Nov 2016 16:15:33 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mail.savoirfairelinux.com (mail.savoirfairelinux.com [208.88.110.44]) by silver.osuosl.org (Postfix) with ESMTPS id 50042231C7 for ; Mon, 21 Nov 2016 16:15:33 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by mail.savoirfairelinux.com (Postfix) with ESMTP id 7265E9C1AC8; Mon, 21 Nov 2016 11:15:31 -0500 (EST) Received: from mail.savoirfairelinux.com ([127.0.0.1]) by localhost (mail.savoirfairelinux.com [127.0.0.1]) (amavisd-new, port 10032) with ESMTP id gKT9_nHXcmhi; Mon, 21 Nov 2016 11:15:30 -0500 (EST) Received: from localhost (localhost [127.0.0.1]) by mail.savoirfairelinux.com (Postfix) with ESMTP id D77189C1CA4; Mon, 21 Nov 2016 11:15:30 -0500 (EST) X-Virus-Scanned: amavisd-new at mail.savoirfairelinux.com Received: from mail.savoirfairelinux.com ([127.0.0.1]) by localhost (mail.savoirfairelinux.com [127.0.0.1]) (amavisd-new, port 10026) with ESMTP id ro3vLdV6AFJc; Mon, 21 Nov 2016 11:15:30 -0500 (EST) Received: from gportay.mtl.sfl (unknown [192.168.48.87]) by mail.savoirfairelinux.com (Postfix) with ESMTPSA id B080F9C1AC8; Mon, 21 Nov 2016 11:15:30 -0500 (EST) From: =?UTF-8?q?Ga=C3=ABl=20PORTAY?= To: buildroot@buildroot.org Date: Mon, 21 Nov 2016 11:15:29 -0500 Message-Id: <20161121161529.10366-1-gael.portay@savoirfairelinux.com> X-Mailer: git-send-email 2.10.2 MIME-Version: 1.0 Cc: =?utf-8?q?Ga=C3=ABl=20PORTAY?= , "Yann E. MORIN" Subject: [Buildroot] [PATCH] fs/ext2: fix double quoted label X-BeenThere: buildroot@busybox.net X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Discussion and development of buildroot List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: buildroot-bounces@busybox.net Sender: "buildroot" Since the commit 6dd7bbb59134799ed3d7343f238b3b02592faebf, the label does not need anymore to be quoted. Even worse it *must* not be simple-quoted, unless the label will contain the double-quotes from the config variable BR2_TARGET_ROOTFS_EXT2_LABEL. The commit mentionned above has replaced echo by printf: - echo "$$(ROOTFS_$(2)_CMD)" >> $$(FAKEROOT_SCRIPT) + $$(call PRINTF,$$(ROOTFS_$(2)_CMD)) >> $$(FAKEROOT_SCRIPT) Since this commit the rootfs label contains extra double-quotes. $ blkid /dev/mmcblk0: LABEL=""BR 2016.08"" UUID="xxx" ^ ^ With this fix, the extra double-quotes have disappeared: /dev/mmcblk0: LABEL="BR 2016.11-rc2" UUID="yyy" Signed-off-by: Gaƫl PORTAY Acked-by: "Yann E. MORIN" --- fs/ext2/ext2.mk | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/fs/ext2/ext2.mk b/fs/ext2/ext2.mk index 7417f81..cfb34c4 100644 --- a/fs/ext2/ext2.mk +++ b/fs/ext2/ext2.mk @@ -20,12 +20,11 @@ ifneq ($(strip $(BR2_TARGET_ROOTFS_EXT2_RESBLKS)),0) EXT2_OPTS += -r $(BR2_TARGET_ROOTFS_EXT2_RESBLKS) endif -# Not qstrip-ing the variable, because it may contain spaces, but we must -# qstrip it when checking. Furthermore, we need to further quote it, so -# that the quotes do not get eaten by the echo statement when creating the -# fakeroot script -ifneq ($(call qstrip,$(BR2_TARGET_ROOTFS_EXT2_LABEL)),) -EXT2_OPTS += -l '$(BR2_TARGET_ROOTFS_EXT2_LABEL)' +# qstrip results in stripping consecutive spaces into a single one. So the +# variable is not qstrip-ed to preserve the integrity of the string value. +EXT2_LABEL := $(subst ",,$(BR2_TARGET_ROOTFS_EXT2_LABEL)) +ifneq ($(EXT2_LABEL),) +EXT2_OPTS += -l "$(EXT2_LABEL)" endif ROOTFS_EXT2_DEPENDENCIES = host-mke2img