From patchwork Sun Sep 24 16:33:01 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Yann E. MORIN" X-Patchwork-Id: 817937 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=busybox.net (client-ip=140.211.166.137; helo=fraxinus.osuosl.org; envelope-from=buildroot-bounces@busybox.net; receiver=) Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.b="c6uZUX30"; dkim-atps=neutral Received: from fraxinus.osuosl.org (smtp4.osuosl.org [140.211.166.137]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 3y0Xp80LZzz9sRq for ; Mon, 25 Sep 2017 02:33:19 +1000 (AEST) Received: from localhost (localhost [127.0.0.1]) by fraxinus.osuosl.org (Postfix) with ESMTP id 02C7C87474; Sun, 24 Sep 2017 16:33:15 +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 35mZ7c8Iev0G; Sun, 24 Sep 2017 16:33:12 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by fraxinus.osuosl.org (Postfix) with ESMTP id 9A8198746D; Sun, 24 Sep 2017 16:33:12 +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 98B741C1E7D for ; Sun, 24 Sep 2017 16:33:11 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by hemlock.osuosl.org (Postfix) with ESMTP id 93C4787FC4 for ; Sun, 24 Sep 2017 16:33:11 +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 kPoeHHFmUkxc for ; Sun, 24 Sep 2017 16:33:10 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mail-wr0-f193.google.com (mail-wr0-f193.google.com [209.85.128.193]) by hemlock.osuosl.org (Postfix) with ESMTPS id 4D8AC87F8A for ; Sun, 24 Sep 2017 16:33:10 +0000 (UTC) Received: by mail-wr0-f193.google.com with SMTP id p37so5839wrb.5 for ; Sun, 24 Sep 2017 09:33:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id; bh=/t1eyxbsTEGCrpSGmnX7nJj/FjlKZ0IgsTsq+awfyMQ=; b=c6uZUX308uYSPLqWAzs77aXWyO7b95C7DSQs0T/OvExM3DgeWxGDbHPK2fPb6YDLP2 STw3I3YqxI1wcPNcuMN8fcTEzcUmMRw+QeK32+0z+9/wq7nShHUk5/KKTj/h8toAOU+n SVVPF9q/FwYdbgMcHpngx5dC70haGPligZDzPnvXSlYTkCQlDBja5Scw47U1zRgioVcf Y1J3K5vlW6UypXr3x6ZR+4zO3jBSgZFkzkjFds6VML0Fb13nZlLAIEAL7pg7ViC+qD+G xZJYyQSAPtTRh+bADYKjSZdUVVNGV8k7FoBuF+/qts2rgKDxE0sy6n4xQJ1CBepo89Zq RP8A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id; bh=/t1eyxbsTEGCrpSGmnX7nJj/FjlKZ0IgsTsq+awfyMQ=; b=EUHmuUndcdP201DPvnrg1SedrcikdkgBcjhhyp8XUSY86LKJt0D3P3sPtQSkDQJJwE 04ScktFShlcTCc3Y5UXZsb3Cx6YYdu1vH2M5HEyIW/fWzzRX2J0gT5hFy5GlbD0EPoe2 JB0lcJ02VRPa5PfIJRiXhZnTpso+y+NrFtPQ+ItZgY5SRRvR7O5EYPkwnYqE5FdzHJiy Rm/sKNDLIZVxxwDzttNIRFE0HUTroJn6GP6BuyreHKxlRaxHb06h02nR18S0U8CrXOjW JPKO/AgpcPfU/4oltBFtiN0VsiMM8sbkmIGRhRCpQAwW+eO1lIojHgVoMlid/Hg4t058 r+HQ== X-Gm-Message-State: AHPjjUjeukbSimaYuUIrUjNdppIEI+FqzEaodLO0dN4cgZcWRmkf8yf5 WIJdIjs5mxiDAswmjCZYQi9JMQ== X-Google-Smtp-Source: AOwi7QAKJf6NzLw1A1aDwS6e2Usixq3kJ7qFrhX1bnZw8nYgu3wu4ZDkTQVWAaZSfKqKrGz5h5tYFA== X-Received: by 10.223.151.55 with SMTP id r52mr4387920wrb.69.1506270788514; Sun, 24 Sep 2017 09:33:08 -0700 (PDT) Received: from localhost.localdomain (2a01cb0886107300342e2d3b6f39c2a7.ipv6.abo.wanadoo.fr. [2a01:cb08:8610:7300:342e:2d3b:6f39:c2a7]) by smtp.gmail.com with ESMTPSA id i50sm5975618wrf.84.2017.09.24.09.33.06 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 24 Sep 2017 09:33:07 -0700 (PDT) From: "Yann E. MORIN" To: buildroot@buildroot.org Date: Sun, 24 Sep 2017 18:33:01 +0200 Message-Id: <20170924163301.10853-1-yann.morin.1998@free.fr> X-Mailer: git-send-email 2.11.0 Cc: "Yann E. MORIN" Subject: [Buildroot] [PATCH] package/asterisk: fix host build 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" The host menuselect tool is linked to our host libxml2 library, but it is missing an RPATH to the host directory. This is because menuselect does not use automake, so does not inherit the LDFLAGS from the configure run. We fix that by simply passing $(HOST_CONFIGURE_OPTS) in the make environment. At the same time, we also install the tool in the host directory, even if not used from there, so that the sanity checks we run are properly passed. Signed-off-by: "Yann E. MORIN" Cc: Arnout Vandecappelle --- package/asterisk/asterisk.mk | 21 ++++++++++++++++----- 1 file changed, 16 insertions(+), 5 deletions(-) diff --git a/package/asterisk/asterisk.mk b/package/asterisk/asterisk.mk index a6801a006d..50512c0b3a 100644 --- a/package/asterisk/asterisk.mk +++ b/package/asterisk/asterisk.mk @@ -294,12 +294,23 @@ HOST_ASTERISK_CONF_OPTS = \ --without-curses \ --with-ncurses=$(HOST_DIR)/usr -# Even though menuselect is an autotools package, it is *not* installed, -# as asterisk does expect it to be in a sub-directory of its source tree, -# which do by copying the full menuselect build tree as a pre-configure -# hook in the target variant. +# Not an automake package, so does not inherit LDFLAGS et al. from +# the configure run. +HOST_ASTERISK_MAKE_ENV = $(HOST_CONFIGURE_OPTS) + +# Even though menuselect is an autotools package, it is not an automake +# package and does not have an 'install' rule, as asterisk does expect +# it to be in a sub-directory of its source tree. We do so by copying +# the full menuselect build tree as a pre-configure hook in the target +# variant. +# However, the sanity checks on host packages are not run on menuselect. +# But we still want to catch that menuselect has the proper rpath set, +# for example, as it uses host libraries that we do build, like +# host-libxml2. +# So we do manually install the menuselect tool. define HOST_ASTERISK_INSTALL_CMDS - @: + $(INSTALL) -D -m 0755 $(@D)/menuselect/menuselect \ + $(HOST_DIR)/bin/asterisk-menuselect endef $(eval $(host-autotools-package))