From patchwork Thu Mar 8 21:44:03 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Markus Mayer X-Patchwork-Id: 883348 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.138; helo=whitealder.osuosl.org; envelope-from=buildroot-bounces@busybox.net; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=quarantine dis=none) header.from=broadcom.com 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 3zy3tv1Lbkz9skx for ; Fri, 9 Mar 2018 08:44:22 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by whitealder.osuosl.org (Postfix) with ESMTP id A40CA893E8; Thu, 8 Mar 2018 21:44:19 +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 0gAOcmf1gK4x; Thu, 8 Mar 2018 21:44:18 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by whitealder.osuosl.org (Postfix) with ESMTP id 1897488EE0; Thu, 8 Mar 2018 21:44:18 +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 033A21C03E8 for ; Thu, 8 Mar 2018 21:44:16 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by silver.osuosl.org (Postfix) with ESMTP id 0028D2F044 for ; Thu, 8 Mar 2018 21:44:16 +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 2oxIANYFPk9D for ; Thu, 8 Mar 2018 21:44:15 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from smtp-out-so.shaw.ca (smtp-out-so.shaw.ca [64.59.136.139]) by silver.osuosl.org (Postfix) with ESMTPS id 060CD2EE6E for ; Thu, 8 Mar 2018 21:44:14 +0000 (UTC) Received: from triton.mmayer.net ([96.48.174.102]) by shaw.ca with ESMTP id u3KeeNZbVYxCTu3KfeMxwH; Thu, 08 Mar 2018 14:44:14 -0700 X-Authority-Analysis: v=2.3 cv=cav8UELM c=1 sm=1 tr=0 a=IfKG9KDHjPrX0SZ8gMoyrg==:117 a=IfKG9KDHjPrX0SZ8gMoyrg==:17 a=v2DPQv5-lfwA:10 a=Q-fNiiVtAAAA:8 a=nT-Ct6wqSoucKf3CD2cA:9 a=Fp8MccfUoT0GBdDC_Lng:22 Received: by triton.mmayer.net (Postfix, from userid 501) id 7F91C2031EBF12; Thu, 8 Mar 2018 13:44:12 -0800 (PST) From: Markus Mayer To: buildroot@buildroot.org Date: Thu, 8 Mar 2018 13:44:03 -0800 Message-Id: <20180308214403.94906-1-mmayer@broadcom.com> X-Mailer: git-send-email 2.14.1 X-CMAE-Envelope: MS4wfEIZP0mG2Lby/wUpzfNvdwu4g2xYf7t7kyhQFaMa9AO/g+6mLrU5hFxQOY191nvYLGiP8RL31dUZDik/35VTUnNkf+JDEvoSyje9ilF9uCAjEQ3fSlFB 52nuB7Nu00zJcJf7PIQB9fTl5gCRSsCmZ2E9sh2L0Dkny36xXTYMPKCNf9MLXE+yGX+UpJuqt3QAzqINEF3I7ZcxbItC0v+6AN0= Subject: [Buildroot] [PATCH] package: dropbear: make PATH configurable X-BeenThere: buildroot@busybox.net X-Mailman-Version: 2.1.24 Precedence: list List-Id: Discussion and development of buildroot List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Markus Mayer MIME-Version: 1.0 Errors-To: buildroot-bounces@busybox.net Sender: "buildroot" Make the default PATH dropbear is using configurable. If not specified, it will continue to default to dropbear's DEFAULT_PATH. Signed-off-by: Markus Mayer --- Please let me know what you think. Thanks. package/dropbear/Config.in | 6 ++++++ package/dropbear/dropbear.mk | 8 ++++++++ 2 files changed, 14 insertions(+) diff --git a/package/dropbear/Config.in b/package/dropbear/Config.in index 6700778161ba..d38ecf50834a 100644 --- a/package/dropbear/Config.in +++ b/package/dropbear/Config.in @@ -55,4 +55,10 @@ config BR2_PACKAGE_DROPBEAR_LASTLOG Enable logging of dropbear access to lastlog. Notice that Buildroot does not generate lastlog by default. +config BR2_PACKAGE_DROPBEAR_PATH + string "dropbear default path" + help + Use the path specified here as dropbear's default path. + If not specified, dropbear will use "/usr/bin:/bin". + endif diff --git a/package/dropbear/dropbear.mk b/package/dropbear/dropbear.mk index 01a1a07b7696..ddbedf3bce93 100644 --- a/package/dropbear/dropbear.mk +++ b/package/dropbear/dropbear.mk @@ -51,6 +51,14 @@ define DROPBEAR_DISABLE_STANDALONE $(SED) 's:\(#define NON_INETD_MODE\):/*\1 */:' $(@D)/options.h endef +ifneq ($(BR2_PACKAGE_DROPBEAR_PATH),"") +define DROPBEAR_CUSTOM_PATH + $(SED) 's|^\(#define DEFAULT_PATH\).*|\1 $(BR2_PACKAGE_DROPBEAR_PATH)|' $(@D)/options.h +endef + +DROPBEAR_POST_EXTRACT_HOOKS += DROPBEAR_CUSTOM_PATH +endif + define DROPBEAR_INSTALL_INIT_SYSTEMD $(INSTALL) -D -m 644 package/dropbear/dropbear.service \ $(TARGET_DIR)/usr/lib/systemd/system/dropbear.service