From patchwork Thu Nov 5 18:41:53 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: James Knight X-Patchwork-Id: 540605 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from fraxinus.osuosl.org (smtp4.osuosl.org [140.211.166.137]) by ozlabs.org (Postfix) with ESMTP id 5213E140E31 for ; Fri, 6 Nov 2015 05:42:07 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by fraxinus.osuosl.org (Postfix) with ESMTP id 0F0018B745; Thu, 5 Nov 2015 18:42:07 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from fraxinus.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id ZDDG76XwQS98; Thu, 5 Nov 2015 18:42:06 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by fraxinus.osuosl.org (Postfix) with ESMTP id E604F8B642; Thu, 5 Nov 2015 18:42:05 +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 4DD4D1C0E0E for ; Thu, 5 Nov 2015 18:42:05 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by whitealder.osuosl.org (Postfix) with ESMTP id 494948CE2C for ; Thu, 5 Nov 2015 18:42:05 +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 mqYwUb8mrukk for ; Thu, 5 Nov 2015 18:42:04 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from ch3vs01.rockwellcollins.com (ch3vs01.rockwellcollins.com [205.175.226.27]) by whitealder.osuosl.org (Postfix) with ESMTPS id 612A78D1FC for ; Thu, 5 Nov 2015 18:42:04 +0000 (UTC) Received: from ofwch3n02.rockwellcollins.com (HELO crulimr01.rockwellcollins.com) ([205.175.226.14]) by ch3vs01.rockwellcollins.com with ESMTP; 05 Nov 2015 12:42:04 -0600 X-Received: from JDKNIGHT-PC.rccalab.inside (unknown [192.168.162.69]) by crulimr01.rockwellcollins.com (Postfix) with ESMTP id 49CB5601DA; Thu, 5 Nov 2015 12:42:03 -0600 (CST) From: James Knight To: buildroot@busybox.net Date: Thu, 5 Nov 2015 13:41:53 -0500 Message-Id: <1446748914-12628-2-git-send-email-james.knight@rockwellcollins.com> X-Mailer: git-send-email 1.9.5.msysgit.1 In-Reply-To: <1446748914-12628-1-git-send-email-james.knight@rockwellcollins.com> References: <1446748914-12628-1-git-send-email-james.knight@rockwellcollins.com> Cc: James Knight Subject: [Buildroot] [PATCH v2 2/3] gpsd: cleanup udev rule permissions 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: , MIME-Version: 1.0 Errors-To: buildroot-bounces@busybox.net Sender: "buildroot" Adjust a generated udev rule file (25-gpsd.rules) to have user write permissions. This is to prevent rebuild issues when the gpsd package fails to re-install on a target (since the `cp` of the rule file will fail due to permissions). Signed-off-by: James Knight --- Changes v1 -> v2: - Package change introduced in change set 2. --- package/gpsd/gpsd.mk | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/package/gpsd/gpsd.mk b/package/gpsd/gpsd.mk index 577b43c..5a369b0 100644 --- a/package/gpsd/gpsd.mk +++ b/package/gpsd/gpsd.mk @@ -217,6 +217,8 @@ define GPSD_INSTALL_STAGING_CMDS install) endef +# When adding udev rules, ensure rules are writable to prevent rebuild +# issues. ifeq ($(BR2_PACKAGE_HAS_UDEV),y) define GPSD_INSTALL_UDEV_RULES (cd $(@D); \ @@ -225,6 +227,8 @@ define GPSD_INSTALL_UDEV_RULES $(SCONS) \ $(GPSD_SCONS_OPTS) \ udev-install) + + chmod u+w $(TARGET_DIR)/lib/udev/rules.d/25-gpsd.rules endef GPSD_POST_INSTALL_TARGET_HOOKS += GPSD_INSTALL_UDEV_RULES