From patchwork Thu Jul 18 10:06:35 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Titouan Christophe X-Patchwork-Id: 1133660 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=none dis=none) header.from=railnova.eu Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=railnova-eu.20150623.gappssmtp.com header.i=@railnova-eu.20150623.gappssmtp.com header.b="Yd98MvAV"; dkim-atps=neutral Received: from whitealder.osuosl.org (smtp1.osuosl.org [140.211.166.138]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 45q8v26p6Yz9sBF for ; Thu, 18 Jul 2019 20:07:10 +1000 (AEST) Received: from localhost (localhost [127.0.0.1]) by whitealder.osuosl.org (Postfix) with ESMTP id D822C877AD; Thu, 18 Jul 2019 10:07:06 +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 D1v2vIZaxBNw; Thu, 18 Jul 2019 10:07:02 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by whitealder.osuosl.org (Postfix) with ESMTP id 2C87D876B3; Thu, 18 Jul 2019 10:07:02 +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 AC6141BF2F9 for ; Thu, 18 Jul 2019 10:06:59 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by hemlock.osuosl.org (Postfix) with ESMTP id A93B8880C8 for ; Thu, 18 Jul 2019 10:06:59 +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 E8aDRiUUHXjj for ; Thu, 18 Jul 2019 10:06:58 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from mail-wm1-f54.google.com (mail-wm1-f54.google.com [209.85.128.54]) by hemlock.osuosl.org (Postfix) with ESMTPS id 23BE488084 for ; Thu, 18 Jul 2019 10:06:58 +0000 (UTC) Received: by mail-wm1-f54.google.com with SMTP id 207so24989002wma.1 for ; Thu, 18 Jul 2019 03:06:58 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=railnova-eu.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=Ej+tQxyXyPa6i24sosNJAzhBgNiKv9sXn4zptx02RZA=; b=Yd98MvAV769zLfZLbcIiHOgq2GsCgWYJRVDljrWMCixyhN9aVSSmoyly1PD6XPxZmV /s3kzqbw0BPiWKjwVM9T45wrrwJ8/vBnUMQ1GSJRcB93gQY7WGMYZvTdDxe8Jz9TamqY +vQEpVrAlWsqwwDs87lJuVu818xQmZyIUxmnRUZcPVDQR+DNpBDvDLKPJ8ZLF2/Lnpiw 20S6qGYZAYQsHoPKi2AsJ9cnym3/rymwpbA1mGEZrQXQWwmswW8E56ooT/YLrB+/nItM E+vQbbmSLUnFbmAjGudi/uQsFDuendXiRecekQC7ctmjcK6T4HVMqcB1GsNpWTNJAUCg i9iw== 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:mime-version:content-transfer-encoding; bh=Ej+tQxyXyPa6i24sosNJAzhBgNiKv9sXn4zptx02RZA=; b=aNDrl3j5uZ3iut1JU49P3N/kE3Ict69ALdGxWxtgm06/s+RG/GpSVLsZjKMYP+WFlM Y5OyISSFG9qRl6W2OqC7+M9wcgY630MwqUcGDJ7v1ooLDB9ZRy9rkcQBPbMv54LzS1X5 dVmAb6cRZuovnMmWcnbUfQUyC3cQKfi/Nr8gpd9d+HdvcrzVkCcNQpH8874hJwZhjXUD By2QDDCoMBR5HULSSVYi68C4XUYUZtSsGp6blPNrCxDKTvGATmqWpCaqaVRYXkapeEgR 7yAf/ApI+mQXzSwgP7IOnEQEPYTQ/Lf/fElf9rV/LK0uCjBbzeRs9Mm2PN2he6SsXtqA JDow== X-Gm-Message-State: APjAAAUAEz6JSYJlLQGqFm8mPlMiCLzKbYO+lOiqus3/2KNQfmhNiNWj uZf0XXlA+Fxx9NoXktXKEbeCNS+bdl30yQ== X-Google-Smtp-Source: APXvYqxy81thiOgJCpc7DlJc0FVPN3HKsBfabvTY8Wfn6+ctW84trhzdouUY4lYKDWglyIBh1Rd9Aw== X-Received: by 2002:a05:600c:230c:: with SMTP id 12mr36536543wmo.151.1563444416389; Thu, 18 Jul 2019 03:06:56 -0700 (PDT) Received: from localhost.localdomain ([212.76.254.67]) by smtp.gmail.com with ESMTPSA id f204sm35910856wme.18.2019.07.18.03.06.55 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 18 Jul 2019 03:06:55 -0700 (PDT) From: Titouan Christophe To: buildroot@buildroot.org Date: Thu, 18 Jul 2019 12:06:35 +0200 Message-Id: <20190718100636.27290-3-titouan.christophe@railnova.eu> X-Mailer: git-send-email 2.21.0 In-Reply-To: <20190718100636.27290-1-titouan.christophe@railnova.eu> References: <20190718100636.27290-1-titouan.christophe@railnova.eu> MIME-Version: 1.0 Subject: [Buildroot] [PATCH 2/3] package/mosquitto: Switch systemd unit to Type=notify and depend on network 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: Peter Korsgaard , Titouan Christophe Errors-To: buildroot-bounces@busybox.net Sender: "buildroot" Signed-off-by: Titouan Christophe --- RFC: Would it be better to use the mosquitto.service file provided upstream ? https://github.com/eclipse/mosquitto/blob/master/service/systemd/mosquitto.service.notify --- package/mosquitto/mosquitto.mk | 4 ++++ package/mosquitto/mosquitto.service | 3 +++ 2 files changed, 7 insertions(+) diff --git a/package/mosquitto/mosquitto.mk b/package/mosquitto/mosquitto.mk index ed72af754a..333cce35c2 100644 --- a/package/mosquitto/mosquitto.mk +++ b/package/mosquitto/mosquitto.mk @@ -23,6 +23,10 @@ else MOSQUITTO_MAKE_OPTS += WITH_STATIC_LIBRARIES=no WITH_SHARED_LIBRARIES=yes endif +ifeq ($(BR2_PACKAGE_SYSTEMD),y) +MOSQUITTO_MAKE_OPTS += WITH_SYSTEMD=yes +endif + # adns uses getaddrinfo_a ifeq ($(BR2_TOOLCHAIN_USES_GLIBC),y) MOSQUITTO_MAKE_OPTS += WITH_ADNS=yes diff --git a/package/mosquitto/mosquitto.service b/package/mosquitto/mosquitto.service index 2d1939d1c7..24c9d8e948 100644 --- a/package/mosquitto/mosquitto.service +++ b/package/mosquitto/mosquitto.service @@ -1,7 +1,10 @@ [Unit] Description=Mosquitto MQTT broker +After=network-online.target +Wants=network-online.target [Service] +Type=notify ExecStart=/usr/sbin/mosquitto -c /etc/mosquitto/mosquitto.conf ExecReload=/bin/kill -HUP $MAINPID Restart=always