From patchwork Fri Apr 24 21:40:20 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Angelo Compagnucci X-Patchwork-Id: 1276709 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.138; helo=whitealder.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=iWMplxYb; 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 4986zP6BCNz9sPF for ; Sat, 25 Apr 2020 07:40:33 +1000 (AEST) Received: from localhost (localhost [127.0.0.1]) by whitealder.osuosl.org (Postfix) with ESMTP id EF45387F3E; Fri, 24 Apr 2020 21:40:30 +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 ycc4Jt8cE3Nq; Fri, 24 Apr 2020 21:40:29 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by whitealder.osuosl.org (Postfix) with ESMTP id 9564387F44; Fri, 24 Apr 2020 21:40:29 +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 B206A1BF39A for ; Fri, 24 Apr 2020 21:40:27 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by hemlock.osuosl.org (Postfix) with ESMTP id AD9D28879D for ; Fri, 24 Apr 2020 21:40: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 I8EjBKmm4Jog for ; Fri, 24 Apr 2020 21:40:26 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mail-wr1-f50.google.com (mail-wr1-f50.google.com [209.85.221.50]) by hemlock.osuosl.org (Postfix) with ESMTPS id 0773488792 for ; Fri, 24 Apr 2020 21:40:26 +0000 (UTC) Received: by mail-wr1-f50.google.com with SMTP id d15so11271066wrx.3 for ; Fri, 24 Apr 2020 14:40:25 -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; bh=bcQKxGCtb6qi5GjaK1eBk4Wm0hO/1d2TfhaAKlKjOvs=; b=iWMplxYb59c7cYU3o6NtRasmte7+9oGUOWYPMdTbW1VTgIWyFtwaPSvzA2XShJxSwS J+iM1FeI8R6oWF5UAztSrCVlw9agU69oU5EfDZUcdSzPWvh77NcKkRNZ4FfgsvIvllqL ntP6ITbn2SETWwUMqg+ORLQnasdeucqbOaH0/EJJoIJX7Acer48xX3xOxiOu8AeXnthL uvbHL85Y7N2sbJ73RcBf68qj6HkdRYSShTq6b3wJcKGau7jok4/3VHCyclqAUQ6SYMF4 PKub33kJSR7E1F/X57t0EAE5xWl1teNBYgdFtmBiCGzrCUSqJ6h+dcQq9J6UtzlzVcFW 9xHw== 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; bh=bcQKxGCtb6qi5GjaK1eBk4Wm0hO/1d2TfhaAKlKjOvs=; b=eQDF3tuYwfX4pCE1rsH44EGcD0DsAojwk/+tVDhIkwpdqFa5huhvtABmP2FSuWKcPR X3wlGc3i3gZA5P7eVMFBDnPRyuUWGhZPK/chpGhMrVZDpS37+/LAEuIqjVb7CLPaDMgM ZGfxk5Snwbvb++cTQqn3QK2zy2RissBFzi9/M+8EI9PMOXv725hLQGbN15MBstqBiRKZ 6X8Ihwsz8yUVrLu+DaLJxbM6AmBKTuxSOMvMW7l4fPxrl9ynoVBCjy7WaLiR+FDH1K/z EHina54eIz/yMBD1QtToz2d1+br0YGi1zapoR4DitSEn3W4fCn9rp2LMSE4/1eRFYNJ9 MYsg== X-Gm-Message-State: AGi0PuaNN9PUXEUvkQT9K8DhQsviYhHwSnAEPDEJFiDcFEdMzVtYRKLb NYKS6cFcOb/HEfO0Xq/j0FA4/cmz2X0= X-Google-Smtp-Source: APiQypJy6xB6vhmFH3zCzap0Le0qu7wEaEiL4zlIcZ8M8hCmSm6uqbiIIFIU2/QH7bohLoV9KOEBgA== X-Received: by 2002:adf:ef8b:: with SMTP id d11mr14577421wro.340.1587764424228; Fri, 24 Apr 2020 14:40:24 -0700 (PDT) Received: from localhost.localdomain (host185036129193.static.fidoka.tech. [185.36.129.193]) by smtp.gmail.com with ESMTPSA id s14sm4290857wmh.18.2020.04.24.14.40.23 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 24 Apr 2020 14:40:23 -0700 (PDT) From: Angelo Compagnucci X-Google-Original-From: Angelo Compagnucci To: buildroot@buildroot.org Date: Fri, 24 Apr 2020 23:40:20 +0200 Message-Id: <20200424214020.381865-1-angelo@amarulasolutions.com> X-Mailer: git-send-email 2.17.1 Subject: [Buildroot] [PATCH] package/apparmor: fix compilation with libintl 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 MIME-Version: 1.0 Errors-To: buildroot-bounces@busybox.net Sender: "buildroot" When libintl is enabled, Apparmor should link againts libintl. The attached patch is already sent upstream. Signed-off-by: Angelo Compagnucci --- ...inutils-fix-compilation-with-libintl.patch | 48 +++++++++++++++++++ package/apparmor/apparmor.mk | 4 ++ 2 files changed, 52 insertions(+) create mode 100644 package/apparmor/0001-parser-binutils-fix-compilation-with-libintl.patch diff --git a/package/apparmor/0001-parser-binutils-fix-compilation-with-libintl.patch b/package/apparmor/0001-parser-binutils-fix-compilation-with-libintl.patch new file mode 100644 index 0000000000..d3f4a51646 --- /dev/null +++ b/package/apparmor/0001-parser-binutils-fix-compilation-with-libintl.patch @@ -0,0 +1,48 @@ +From c9fe40d9386a5e4cf99f44df9b98382d83f1c4f4 Mon Sep 17 00:00:00 2001 +From: Angelo Compagnucci +Date: Fri, 24 Apr 2020 17:34:24 +0200 +Subject: [PATCH] parser: binutils: fix compilation with libintl + +When libintl is available on the system, we need to link against the +libintl library too. + +Signed-off-by: Angelo Compagnucci +--- + binutils/Makefile | 4 ++++ + parser/Makefile | 5 +++++ + 2 files changed, 9 insertions(+) + +diff --git a/binutils/Makefile b/binutils/Makefile +index 11459bec..d8c1b634 100644 +--- a/binutils/Makefile ++++ b/binutils/Makefile +@@ -56,6 +56,10 @@ SBINTOOLS = aa-status + + AALIB = -Wl,-Bstatic -lapparmor -Wl,-Bdynamic -lpthread + ++ifdef WITH_LIBINTL ++ AALIB += -lintl ++endif ++ + ifdef USE_SYSTEM + # Using the system libapparmor so Makefile dependencies can't be used + LIBAPPARMOR_A = +diff --git a/parser/Makefile b/parser/Makefile +index eab64be9..998230ee 100644 +--- a/parser/Makefile ++++ b/parser/Makefile +@@ -91,6 +91,11 @@ AAREOBJECTS = $(AAREOBJECT) + AARE_LDFLAGS = -static-libgcc -static-libstdc++ -L. $(LDFLAGS) + AALIB = -Wl,-Bstatic -lapparmor -Wl,-Bdynamic -lpthread + ++ifdef WITH_LIBINTL ++ AALIB += -lintl ++endif ++ ++ + ifdef USE_SYSTEM + # Using the system libapparmor so Makefile dependencies can't be used + LIBAPPARMOR_A = +-- +2.25.1 + diff --git a/package/apparmor/apparmor.mk b/package/apparmor/apparmor.mk index 9180fcd803..c3b9d9fab9 100644 --- a/package/apparmor/apparmor.mk +++ b/package/apparmor/apparmor.mk @@ -17,6 +17,10 @@ APPARMOR_DEPENDENCIES = libapparmor APPARMOR_TOOLS = parser APPARMOR_MAKE_OPTS = USE_SYSTEM=1 DISTRO=unknown +ifeq ($(BR2_PACKAGE_GETTEXT_PROVIDES_LIBINTL),y) +APPARMOR_MAKE_OPTS += WITH_LIBINTL=1 +endif + ifeq ($(BR2_PACKAGE_APPARMOR_BINUTILS),y) APPARMOR_TOOLS += binutils endif