From patchwork Thu Oct 15 16:46:04 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Fabrice Fontaine X-Patchwork-Id: 1382801 Return-Path: X-Original-To: incoming-buildroot@patchwork.ozlabs.org Delivered-To: patchwork-incoming-buildroot@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=busybox.net (client-ip=140.211.166.136; helo=silver.osuosl.org; envelope-from=buildroot-bounces@busybox.net; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20161025 header.b=Z12wr9aR; dkim-atps=neutral Received: from silver.osuosl.org (smtp3.osuosl.org [140.211.166.136]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 4CBwDC0hVsz9sTK for ; Fri, 16 Oct 2020 03:46:51 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by silver.osuosl.org (Postfix) with ESMTP id F15172E33C; Thu, 15 Oct 2020 16:46:48 +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 8J1lEkb3DtcO; Thu, 15 Oct 2020 16:46:44 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by silver.osuosl.org (Postfix) with ESMTP id 8F0BB2E335; Thu, 15 Oct 2020 16:46:44 +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 346011BF405 for ; Thu, 15 Oct 2020 16:46:43 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by whitealder.osuosl.org (Postfix) with ESMTP id 29C5B886A3 for ; Thu, 15 Oct 2020 16:46:43 +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 PZ-Ua6-muH+k for ; Thu, 15 Oct 2020 16:46:41 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mail-wm1-f47.google.com (mail-wm1-f47.google.com [209.85.128.47]) by whitealder.osuosl.org (Postfix) with ESMTPS id 861D088372 for ; Thu, 15 Oct 2020 16:46:41 +0000 (UTC) Received: by mail-wm1-f47.google.com with SMTP id q5so4522909wmq.0 for ; Thu, 15 Oct 2020 09:46:41 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=gbFaYGmfH31ZV381yNfI2bdJ9ngSyrjokbEJYRud4Rw=; b=Z12wr9aRtD/VD8b3BFfKLoOn6gnL/xrrbIlWlh8tZ8pxU2tUK71YNImIKAVMTE2pFl 098YvsjQ4747hzyeOWT2qN/0RhfN+oisMwVDXlax/0EbgeB2FnWH/Jji96yoSd/T04qJ ATfQfw2nDZ/hViBko8mEF7a6LsmtrNYWw77a5559OAaij5nE1q8aD1BAJXSnbtokPzcB 8h+M4asN5EiAHwSLqrF/vZO0HxPHE2s+/SnvKMjmdGQyzTkbsf2JmMQj3kgQiHvHMk95 6zTo3KH4nKTmdYzBOyFTdCRCGxgV6s7B4YsaQLgs75AweFBhlOpmiSn9H/7pQHiID8k7 7Unw== 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:mime-version :content-transfer-encoding; bh=gbFaYGmfH31ZV381yNfI2bdJ9ngSyrjokbEJYRud4Rw=; b=EA/6e+9wpJKL1nKWASNarCaEEJlawz0Mr5UcyPT5CwJ4iAPOahoQ1ZtSeslo18SzM6 Aq87ztYQ2lr/FAx8v1CCmr7vaWMKz0RP1Dzj3dJfTcjipiTZNOf6z6Cj0uKmtMCFoq2z kV7U1JGD7FjJG806pWGMn6a2IJWre2xTrcniuWFI0k4QC58gMKwGXssfcxyu5CygTOd6 RF+ajipEblj5xKp+GNhMnbr9OEXvBvAKvHYDgrfWn1OI9nul9+utZkPQ3Wx3ztjZuadx LPMd8dDvkMCIC26yK7VmYjVzqAR2R9AtbtIJRljslWuF3elLsLRZu8CiKR0pQXZbM6Tm 6Row== X-Gm-Message-State: AOAM5333YFyNxPHQbFfPM4smYLFHsaQcebrpXPEJYoUiKiKCyvjv3DBp Sw+hFTBTSSfgJTvPfuv/Pf8VUiiXrijC0Q== X-Google-Smtp-Source: ABdhPJwOpammpHZuWoNzp2Wjumft233MqtHPvL4/3GzEXYYGjsrM4smJ5d/HYjREJerGQRwtF3T3rQ== X-Received: by 2002:a1c:9e12:: with SMTP id h18mr4887619wme.11.1602780399616; Thu, 15 Oct 2020 09:46:39 -0700 (PDT) Received: from kali.home (2a01cb0881b76d00c2afd0dfa851d2b9.ipv6.abo.wanadoo.fr. [2a01:cb08:81b7:6d00:c2af:d0df:a851:d2b9]) by smtp.gmail.com with ESMTPSA id v8sm5372085wmb.20.2020.10.15.09.46.38 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 15 Oct 2020 09:46:38 -0700 (PDT) From: Fabrice Fontaine To: buildroot@buildroot.org Date: Thu, 15 Oct 2020 18:46:04 +0200 Message-Id: <20201015164604.963072-1-fontaine.fabrice@gmail.com> X-Mailer: git-send-email 2.28.0 MIME-Version: 1.0 Subject: [Buildroot] [PATCH 1/1] package/apparmor: fix build on uclibc 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: Angelo Compagnucci , Fabrice Fontaine Errors-To: buildroot-bounces@busybox.net Sender: "buildroot" Fix build of version 3.0.0 with uclibc Fixes: - http://autobuild.buildroot.org/results/aea20bd5539fad35385565ffeb7e6ac566507017 Signed-off-by: Fabrice Fontaine --- ...orce-host-cpp-to-detect-reallocarray.patch | 37 +++++++++++++++++++ 1 file changed, 37 insertions(+) create mode 100644 package/apparmor/0001-parser-Makefile-dont-force-host-cpp-to-detect-reallocarray.patch diff --git a/package/apparmor/0001-parser-Makefile-dont-force-host-cpp-to-detect-reallocarray.patch b/package/apparmor/0001-parser-Makefile-dont-force-host-cpp-to-detect-reallocarray.patch new file mode 100644 index 0000000000..0510489d55 --- /dev/null +++ b/package/apparmor/0001-parser-Makefile-dont-force-host-cpp-to-detect-reallocarray.patch @@ -0,0 +1,37 @@ +From 0dbcbee70097ecde66708064ec1dedfa64e581e8 Mon Sep 17 00:00:00 2001 +From: Armin Kuster +Date: Wed, 7 Oct 2020 20:50:38 -0700 +Subject: [PATCH] parser/Makefile: dont force host cpp to detect reallocarray + +In cross build environments, using the hosts cpp gives incorrect +detection of reallocarray. Change cpp to a variable. + +fixes: +parser_misc.c: In function 'int capable_add_cap(const char*, int, unsigned int, capability_flags)': +| parser_misc.c:297:37: error: 'reallocarray' was not declared in this scope +| 297 | tmp = (struct capability_table *) reallocarray(cap_table, sizeof(struct capability_table), cap_table_size+1); + +Signed-off-by: Armin Kuster +[Retrieved from: +https://gitlab.com/ffontaine/apparmor/-/commit/0dbcbee70097ecde66708064ec1dedfa64e581e8] +Signed-off-by: Fabrice Fontaine +--- + parser/Makefile | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/parser/Makefile b/parser/Makefile +index acef3d77a..8250ac451 100644 +--- a/parser/Makefile ++++ b/parser/Makefile +@@ -54,7 +54,7 @@ endif + CPPFLAGS += -D_GNU_SOURCE + + STDLIB_INCLUDE:="\#include " +-HAVE_REALLOCARRAY:=$(shell echo $(STDLIB_INCLUDE) | cpp ${CPPFLAGS} | grep -q reallocarray && echo true) ++HAVE_REALLOCARRAY:=$(shell echo $(STDLIB_INCLUDE) | ${CPP} ${CPPFLAGS} | grep -q reallocarray && echo true) + + WARNINGS = -Wall + CXX_WARNINGS = ${WARNINGS} ${EXTRA_WARNINGS} +-- +GitLab +