From patchwork Tue Dec 18 00:51:14 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Markus Mayer X-Patchwork-Id: 1014901 Return-Path: X-Original-To: incoming-buildroot@patchwork.ozlabs.org Delivered-To: patchwork-incoming-buildroot@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=busybox.net (client-ip=140.211.166.133; helo=hemlock.osuosl.org; envelope-from=buildroot-bounces@busybox.net; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=quarantine dis=none) header.from=broadcom.com Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (1024-bit key; unprotected) header.d=broadcom.com header.i=@broadcom.com header.b="iHTszTWr"; dkim-atps=neutral Received: from hemlock.osuosl.org (smtp2.osuosl.org [140.211.166.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 43JflR5lXBz9s3q for ; Tue, 18 Dec 2018 11:58:10 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by hemlock.osuosl.org (Postfix) with ESMTP id D87A885B92; Tue, 18 Dec 2018 00:58:06 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from hemlock.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id cz-TQbA3DIdd; Tue, 18 Dec 2018 00:58:02 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by hemlock.osuosl.org (Postfix) with ESMTP id AD67385B6C; Tue, 18 Dec 2018 00:58:02 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from whitealder.osuosl.org (smtp1.osuosl.org [140.211.166.138]) by ash.osuosl.org (Postfix) with ESMTP id 362DF1C31B6 for ; Tue, 18 Dec 2018 00:58:02 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by whitealder.osuosl.org (Postfix) with ESMTP id 32D5D8403D for ; Tue, 18 Dec 2018 00:58:02 +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 AGSrvvuMTkZi for ; Tue, 18 Dec 2018 00:58:01 +0000 (UTC) X-Greylist: delayed 00:06:12 by SQLgrey-1.7.6 Received: from mail-yw1-f42.google.com (mail-yw1-f42.google.com [209.85.161.42]) by whitealder.osuosl.org (Postfix) with ESMTPS id 7486481F0F for ; Tue, 18 Dec 2018 00:58:01 +0000 (UTC) Received: by mail-yw1-f42.google.com with SMTP id t13so5983620ywe.13 for ; Mon, 17 Dec 2018 16:58:01 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=broadcom.com; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=i1tw4guVnY8D/M4OmnyR8PlntEJa1Tc9Xg/o1nFao9w=; b=iHTszTWrYF0EVNSqwciUCMh0i6zpEQmBiLTxrCSAzc/3bPrd5ZXDr1gIJ6r8NNCHno KCWzuzMZ6Ooe+wILq4f5NQBplFhb74lcCzRdq/595JzslOfyPTu67+Ny+rs3CzCt2L4T ZgEBB21q7gMpD+hHnu0fg3eQfJ9zVgvwdHv28= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=i1tw4guVnY8D/M4OmnyR8PlntEJa1Tc9Xg/o1nFao9w=; b=SYKcGv+Ggh5TcSx6xVDG/1ZAgFXmSBZb68hN/Fq+pCJX8Z9F1RzccYVwSxJIQNC4np pr2o3GgE+E4bK8YfSDY+tZx4ACj2I+wBC7QqMyY0g35So8DfsqFQxw62xsLETwO0oCrt jkfVvUJGC4fqneukHHkQZphdmVO45tajm/pGat/QqpGGvwxwCrq3yxJRnJmG/TKGjmPZ EvoMasEi1/Nfaa3wOR+oe4msAYk+0epw463w5x9HKN6uZXCC8e8PD5whJxEyQUK7mo8H HMbH1MwlorQzxhBBjj1FYeehe1TMxraMH9mB34k7rL7OWCuSB6cxXO5hiOrExqangCLX aEaw== X-Gm-Message-State: AA+aEWZIWPzbGVT9ZjU2OhXlskzek8sc5IMZlDWDiu607UArJKOxTkOi pO1YKlBhuA5kWi3QPvt6hysWPdU/Oxn4IQ== X-Google-Smtp-Source: AFSGD/ULhgl0rz2eJgW/JSZnRadj94bSDj/vVrBBXkjDycFvOS1mRMuhirV7HqQ4+5jj+3qqvCeW9g== X-Received: by 2002:a0d:d386:: with SMTP id v128mr15020876ywd.449.1545094307698; Mon, 17 Dec 2018 16:51:47 -0800 (PST) Received: from lbrmn-mmayer.ric.broadcom.com ([192.19.228.250]) by smtp.gmail.com with ESMTPSA id h62sm4429911ywe.100.2018.12.17.16.51.46 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 17 Dec 2018 16:51:47 -0800 (PST) From: Markus Mayer To: Buildroot Mailing List Date: Mon, 17 Dec 2018 16:51:14 -0800 Message-Id: <20181218005116.17435-3-mmayer@broadcom.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20181218005116.17435-1-mmayer@broadcom.com> References: <20181218005116.17435-1-mmayer@broadcom.com> Subject: [Buildroot] [PATCH 2/4] skeleton: use BR2_SYSTEM_DEFAULT_PATH as default PATH X-BeenThere: buildroot@busybox.net X-Mailman-Version: 2.1.29 Precedence: list List-Id: Discussion and development of buildroot List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: "Yann E. MORIN" , Markus Mayer MIME-Version: 1.0 Errors-To: buildroot-bounces@busybox.net Sender: "buildroot" We substitute the path specified in system/skeleton/etc/profile with the path specified in the configuration varialbe BR2_SYSTEM_DEFAULT_PATH. Signed-off-by: Markus Mayer --- package/skeleton-init-common/skeleton-init-common.mk | 3 +++ system/skeleton/etc/profile | 1 + 2 files changed, 4 insertions(+) diff --git a/package/skeleton-init-common/skeleton-init-common.mk b/package/skeleton-init-common/skeleton-init-common.mk index e8a052205268..358336599389 100644 --- a/package/skeleton-init-common/skeleton-init-common.mk +++ b/package/skeleton-init-common/skeleton-init-common.mk @@ -22,6 +22,9 @@ define SKELETON_INIT_COMMON_INSTALL_TARGET_CMDS $(call SYSTEM_LIB_SYMLINK,$(TARGET_DIR)) $(INSTALL) -m 0644 support/misc/target-dir-warning.txt \ $(TARGET_DIR_WARNING_FILE) + $(SED) '/.*the PATH below may be replaced.*/d' $(TARGET_DIR)/etc/profile + $(SED) 's|PATH=.*|PATH=$(BR2_SYSTEM_DEFAULT_PATH)|' \ + $(TARGET_DIR)/etc/profile endef # We don't care much about what goes in staging, as long as it is diff --git a/system/skeleton/etc/profile b/system/skeleton/etc/profile index 1255d23ff40d..5ed47743d8f4 100644 --- a/system/skeleton/etc/profile +++ b/system/skeleton/etc/profile @@ -1,3 +1,4 @@ +# At install, the PATH below may be replaced with BR2_SYSTEM_DEFAULT_PATH. export PATH=/bin:/sbin:/usr/bin:/usr/sbin if [ "$PS1" ]; then