From patchwork Mon Feb 2 14:33:44 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?S=C5=82awomir_Demeszko?= X-Patchwork-Id: 435525 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from arrakis.dune.hu (arrakis.dune.hu [78.24.191.176]) (using TLSv1.1 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 413BC14017D for ; Tue, 3 Feb 2015 01:34:15 +1100 (AEDT) Received: from arrakis.dune.hu (localhost [127.0.0.1]) by arrakis.dune.hu (Postfix) with ESMTP id 8477028BFB0; Mon, 2 Feb 2015 15:31:34 +0100 (CET) X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on arrakis.dune.hu X-Spam-Level: X-Spam-Status: No, score=-1.5 required=5.0 tests=BAYES_00,T_DKIM_INVALID autolearn=unavailable version=3.3.2 Received: from arrakis.dune.hu (localhost [127.0.0.1]) by arrakis.dune.hu (Postfix) with ESMTP id 6146C28BC2E for ; Mon, 2 Feb 2015 15:31:28 +0100 (CET) X-policyd-weight: using cached result; rate: -7.6 Received: from hosting.nazwa24.pl (ns1.hosting.nazwa24.pl [46.242.129.143]) by arrakis.dune.hu (Postfix) with ESMTPS for ; Mon, 2 Feb 2015 15:31:26 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=wireless-instruments.com; s=default; h=Content-Transfer-Encoding:Content-Type:MIME-Version:Message-Id:Date:Subject:Cc:To:From; bh=mas6X7/6r/lGYIb+xHXUixqJh/+uZHrGqmMXB64Z47E=; b=ehmTItOn20e/7dNp1uryivmJvfNy6NfyDXznUUFj2fbx8zVGLW/rWKZOGj5IVB4dFRrDVsivpIm1sG6zOQbC1tNog+Yc6gksxRUYsimRjSCU/wHSSVTQ1jYtmCH4g9Jsoe5Qboj3OVsxIeg+fp2XlT5oCxIpLQqpuRR4tNSbQXA=; Received: from afo149.internetdsl.tpnet.pl ([83.16.144.149]:51467 helo=localhost.localdomain) by hosting.nazwa24.pl with esmtpsa (UNKNOWN:AES128-SHA256:128) (Exim 4.82) (envelope-from ) id 1YII4Y-0003NL-4h; Mon, 02 Feb 2015 15:33:54 +0100 From: =?UTF-8?q?S=C5=82awomir=20Demeszko?= To: openwrt-devel@lists.openwrt.org Date: Mon, 2 Feb 2015 15:33:44 +0100 Message-Id: <1422887624-8471-1-git-send-email-s.demeszko@wireless-instruments.com> X-Mailer: git-send-email 1.9.1 MIME-Version: 1.0 X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - hosting.nazwa24.pl X-AntiAbuse: Original Domain - lists.openwrt.org X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12] X-AntiAbuse: Sender Address Domain - wireless-instruments.com X-Get-Message-Sender-Via: hosting.nazwa24.pl: authenticated_id: s.demeszko@wireless-instruments.com Cc: =?UTF-8?q?S=C5=82awomir=20Demeszko?= Subject: [OpenWrt-Devel] [PATCH] Fix possible fail to check for dependencies X-BeenThere: openwrt-devel@lists.openwrt.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: OpenWrt Development List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: openwrt-devel-bounces@lists.openwrt.org Sender: "openwrt-devel" Few characters in filenames (a plus sign, a dot) can be interpreted specially by grep. This can lead to the omission of missing package dependency. For example if we would have "some.file.so" then it matches also "some2file.so". -F switch off special meaning of any character and -x match against whole line. Signed-off-by: SÅ‚awomir Demeszko --- include/package-ipkg.mk | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/package-ipkg.mk b/include/package-ipkg.mk index 11edb9a..b7dc0ad 100644 --- a/include/package-ipkg.mk +++ b/include/package-ipkg.mk @@ -66,7 +66,7 @@ ifneq ($(PKG_NAME),toolchain) XARGS="$(XARGS)"; \ $(SCRIPT_DIR)/gen-dependencies.sh "$$(IDIR_$(1))"; \ ) | while read FILE; do \ - grep -q "^$$$$FILE$$$$" $(PKG_INFO_DIR)/$(1).provides || \ + grep -qxF "$$$$FILE" $(PKG_INFO_DIR)/$(1).provides || \ echo "$$$$FILE" >> $(PKG_INFO_DIR)/$(1).missing; \ done; \ if [ -f "$(PKG_INFO_DIR)/$(1).missing" ]; then \