From patchwork Sun Mar 4 00:43:40 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christian Stewart X-Patchwork-Id: 881125 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=none (p=none dis=none) header.from=paral.in Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=paral-in.20150623.gappssmtp.com header.i=@paral-in.20150623.gappssmtp.com header.b="fBGrbK4C"; dkim-atps=neutral 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 3zv47610BGz9sWj for ; Sun, 4 Mar 2018 11:44:33 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by whitealder.osuosl.org (Postfix) with ESMTP id 812AC884CC; Sun, 4 Mar 2018 00:44:31 +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 w+FfM4CdhwQA; Sun, 4 Mar 2018 00:44:30 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by whitealder.osuosl.org (Postfix) with ESMTP id 26570884D5; Sun, 4 Mar 2018 00:44:30 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from hemlock.osuosl.org (smtp2.osuosl.org [140.211.166.133]) by ash.osuosl.org (Postfix) with ESMTP id 253851C2C7D for ; Sun, 4 Mar 2018 00:44:27 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by hemlock.osuosl.org (Postfix) with ESMTP id 2225588F19 for ; Sun, 4 Mar 2018 00:44:27 +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 rW8siWBtBkAQ for ; Sun, 4 Mar 2018 00:44:26 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from mail-io0-f181.google.com (mail-io0-f181.google.com [209.85.223.181]) by hemlock.osuosl.org (Postfix) with ESMTPS id 6232A88F0A for ; Sun, 4 Mar 2018 00:44:26 +0000 (UTC) Received: by mail-io0-f181.google.com with SMTP id q24so14360294ioh.8 for ; Sat, 03 Mar 2018 16:44:26 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=paral-in.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=FE4p5AdCkUnRsdToGMIUCpFla1/CaH+QeDhE481+MYY=; b=fBGrbK4CegRqIJZnzb+gTKDc+MjtS51tKqWjG4KOuQw9puSf90IbQ/4Y93TLrtQ8mh lFZtwYFMF+gTAAcTlx/u+7vAFo4X1aZzmGeGUtEuBw4uPaVFyoD4S8ZzHMQEUvENWnFR pzaa/48orSTiD+pVFvgnV3mqRgpYCsRfXrf/fF4o3Yw2Qf9JooGUim7jPBtRH0GaBEJ3 kasNF/WPt6cOzjzPOX6qkXD5cA9Q/xeCMfCODvA1dxrtCfxofyqDccll65/llgjnryHj nSrIggWYdJDoKMBxEKArvJtuyanX+qILc+hp5fFE8tf/x7jEClAaOk0ZlzHjwGz17hUt EFMw== 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=FE4p5AdCkUnRsdToGMIUCpFla1/CaH+QeDhE481+MYY=; b=t8ojP+aXLxMD2QKwmfJfGhfVj69yv9hVOf0IyGkHqPLKy/h1PCee6NWHAUaYkq/i61 pXHk7MO/HH868P6qgqYdLJd2EJVUenBmblSTc868FyOniTGu+sK3Xx7EByMaefaM0Ozy 4N9GQZsdfp48HNc+AYqLXYZjQr2ylGaohyr41lSeWB5kEBi3wJxc8I89bAZoJ1kV6YpG 8td94aw6fufDdSZ0u7R3a7IDQFAfr1BBBbnZfMNtssnz5SIZmRlyJrRM3SADTO19xFIx 4sDJh0GVqmmx2rM0JMlVVJPN5ovmkEpCoBbMl67wluwDe+yVA13dJZsv/bAuodyykeND uLDw== X-Gm-Message-State: AElRT7FMJ+eI23vucwb3NbYQBQVAfifQVXbwKJc9rWvEBxzrzAtgtgcF 2wzfKythUAgWrsAdsgm+5V6utIg0 X-Google-Smtp-Source: AG47ELswNWH+8ZdZiZ7ynD1csPmuHppAhrju4fN//gW0iFD18trPN3UjW8SUkDGM0MPZ28ZubbrP4Q== X-Received: by 10.107.200.69 with SMTP id y66mr12251936iof.116.1520124265431; Sat, 03 Mar 2018 16:44:25 -0800 (PST) Received: from localhost.localdomain (69-174-166-55.lfytina2.metronetinc.net. [69.174.166.55]) by smtp.gmail.com with ESMTPSA id b99sm6148072ioj.82.2018.03.03.16.44.24 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sat, 03 Mar 2018 16:44:25 -0800 (PST) From: Christian Stewart To: buildroot@buildroot.org Date: Sat, 3 Mar 2018 19:43:40 -0500 Message-Id: <20180304004346.331-3-christian@paral.in> X-Mailer: git-send-email 2.13.6 In-Reply-To: <20180304004346.331-1-christian@paral.in> References: <20180304004346.331-1-christian@paral.in> Subject: [Buildroot] [PATCH v3 2/8] dumb-init: new package 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: Thomas Petazzoni , hamilton@aperturerobotics.com, Christian Stewart , "Yann E . MORIN" MIME-Version: 1.0 Errors-To: buildroot-bounces@busybox.net Sender: "buildroot" dumb-init is a minimal init process to act as PID 1 for containers. Static compilation is used, as dumb-init will typically be executed inside a container. dumb-init can satisfy docker-engine's docker-init requirement. Signed-off-by: Christian Stewart --- Changes since v1: - Upgraded to v1.2.1 - Added license hash --- package/Config.in | 1 + package/dumb-init/Config.in | 7 +++++++ package/dumb-init/dumb-init.hash | 3 +++ package/dumb-init/dumb-init.mk | 24 ++++++++++++++++++++++++ 4 files changed, 35 insertions(+) create mode 100644 package/dumb-init/Config.in create mode 100644 package/dumb-init/dumb-init.hash create mode 100644 package/dumb-init/dumb-init.mk diff --git a/package/Config.in b/package/Config.in index 5bdaa24340..dd42db79ec 100644 --- a/package/Config.in +++ b/package/Config.in @@ -1906,6 +1906,7 @@ comment "Utilities" source "package/crudini/Config.in" source "package/dialog/Config.in" source "package/dtach/Config.in" + source "package/dumb-init/Config.in" source "package/easy-rsa/Config.in" source "package/file/Config.in" source "package/gnupg/Config.in" diff --git a/package/dumb-init/Config.in b/package/dumb-init/Config.in new file mode 100644 index 0000000000..e817493605 --- /dev/null +++ b/package/dumb-init/Config.in @@ -0,0 +1,7 @@ +config BR2_PACKAGE_DUMB_INIT + bool "dumb-init" + help + dumb-init is a simple but valid init binary to + act as PID 1 for containers. + + https://github.com/Yelp/dumb-init diff --git a/package/dumb-init/dumb-init.hash b/package/dumb-init/dumb-init.hash new file mode 100644 index 0000000000..9e74ff5580 --- /dev/null +++ b/package/dumb-init/dumb-init.hash @@ -0,0 +1,3 @@ +# Locally computed +sha256 56858088d9d6c911c227d196fcbfca06aff31fbe83e1519f9cabe5cf6f11b242 dumb-init-v1.2.1.tar.gz +sha256 4d74123f166ad8f147e9939bfb451578db84823f22b48fd64b1086d3654a0149 LICENSE diff --git a/package/dumb-init/dumb-init.mk b/package/dumb-init/dumb-init.mk new file mode 100644 index 0000000000..4ebbff1930 --- /dev/null +++ b/package/dumb-init/dumb-init.mk @@ -0,0 +1,24 @@ +################################################################################ +# +# dumb-init +# +################################################################################ + +DUMB_INIT_VERSION = v1.2.1 +DUMB_INIT_SITE = $(call github,Yelp,dumb-init,$(DUMB_INIT_VERSION)) + +DUMB_INIT_LICENSE = MIT +DUMB_INIT_LICENSE_FILES = LICENSE +DUMB_INIT_CFLAGS += -static + +define DUMB_INIT_BUILD_CMDS + $(TARGET_CC) \ + $(DUMB_INIT_CFLAGS) \ + -o $(@D)/dumb-init $(@D)/dumb-init.c +endef + +define DUMB_INIT_INSTALL_TARGET_CMDS + $(INSTALL) -D -m 0755 $(@D)/dumb-init $(TARGET_DIR)/usr/bin/dumb-init +endef + +$(eval $(generic-package))