From patchwork Wed Nov 20 17:39:33 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thomas Preston X-Patchwork-Id: 1198361 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.133; helo=hemlock.osuosl.org; envelope-from=buildroot-bounces@busybox.net; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=none dis=none) header.from=codethink.co.uk Received: from hemlock.osuosl.org (smtp2.osuosl.org [140.211.166.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 47J92H6DWcz9sQp for ; Thu, 21 Nov 2019 04:40:23 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by hemlock.osuosl.org (Postfix) with ESMTP id 2D52B88691; Wed, 20 Nov 2019 17:40:22 +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 x-AhI3PfPJj6; Wed, 20 Nov 2019 17:40:21 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by hemlock.osuosl.org (Postfix) with ESMTP id 7D5A8886A0; Wed, 20 Nov 2019 17:40:21 +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 92F141BF97F for ; Wed, 20 Nov 2019 17:39:57 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by whitealder.osuosl.org (Postfix) with ESMTP id 8FD7487C22 for ; Wed, 20 Nov 2019 17:39:57 +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 JNx4DLf7H6ey for ; Wed, 20 Nov 2019 17:39:56 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from imap1.codethink.co.uk (imap1.codethink.co.uk [176.9.8.82]) by whitealder.osuosl.org (Postfix) with ESMTPS id 8F07D87C2E for ; Wed, 20 Nov 2019 17:39:56 +0000 (UTC) Received: from [167.98.27.226] (helo=ts007-build.ts007.codethink.co.uk) by imap1.codethink.co.uk with esmtpsa (Exim 4.84_2 #1 (Debian)) id 1iXTxK-0008QV-If; Wed, 20 Nov 2019 17:39:54 +0000 From: Thomas Preston To: buildroot@buildroot.org Date: Wed, 20 Nov 2019 17:39:33 +0000 Message-Id: <20191120173944.130142-20-thomas.preston@codethink.co.uk> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20191120173944.130142-1-thomas.preston@codethink.co.uk> References: <20191120173944.130142-1-thomas.preston@codethink.co.uk> MIME-Version: 1.0 Subject: [Buildroot] [RFC PATCH v3 19/30] package/libvpx: Add host package. 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: Michael Drake , Thomas Preston Errors-To: buildroot-bounces@busybox.net Sender: "buildroot" From: Michael Drake Signed-off-by: Michael Drake Signed-off-by: Thomas Preston --- package/libvpx/libvpx.mk | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/package/libvpx/libvpx.mk b/package/libvpx/libvpx.mk index aaef708416..c8debf27d5 100644 --- a/package/libvpx/libvpx.mk +++ b/package/libvpx/libvpx.mk @@ -15,11 +15,16 @@ LIBVPX_CONF_ENV = \ LD="$(TARGET_CC)" \ CROSS=$(GNU_TARGET_NAME) +HOST_LIBVPX_CONF_ENV = \ + LD="$(HOST_CC)" + LIBVPX_CONF_OPTS = \ --disable-examples \ --disable-docs \ --disable-unit-tests +HOST_LIBVPX_CONF_OPTS = $(LIBVPX_CONF_OPTS) + # This is not a true autotools package. It is based on the ffmpeg build system define LIBVPX_CONFIGURE_CMDS (cd $(LIBVPX_SRCDIR) && rm -rf config.cache && \ @@ -35,10 +40,29 @@ define LIBVPX_CONFIGURE_CMDS ) endef +define HOST_LIBVPX_CONFIGURE_CMDS + (cd $(HOST_LIBVPX_SRCDIR) && rm -rf config.cache && \ + $(HOST_CONFIGURE_OPTS) \ + $(HOST_CONFIGURE_ARGS) \ + $(HOST_LIBVPX_CONF_ENV) \ + ./configure \ + --target=generic-gnu \ + --enable-pic \ + --prefix="$(HOST_DIR)" \ + --enable-shared --disable-static \ + --disable-debug \ + $(HOST_LIBVPX_CONF_OPTS) \ + ) +endef + define LIBVPX_BUILD_CMDS $(TARGET_MAKE_ENV) $(LIBVPX_MAKE_ENV) $(MAKE) -C $(@D) all endef +define HOST_LIBVPX_BUILD_CMDS + $(HOST_MAKE_ENV) $(HOST_LIBVPX_MAKE_ENV) $(MAKE) -C $(@D) all +endef + define LIBVPX_INSTALL_STAGING_CMDS $(TARGET_MAKE_ENV) $(LIBVPX_MAKE_ENV) $(MAKE) DESTDIR="$(STAGING_DIR)" -C $(@D) install endef @@ -47,4 +71,9 @@ define LIBVPX_INSTALL_TARGET_CMDS $(TARGET_MAKE_ENV) $(LIBVPX_MAKE_ENV) $(MAKE) DESTDIR="$(TARGET_DIR)" -C $(@D) install endef +define HOST_LIBVPX_INSTALL_CMDS + $(HOST_MAKE_ENV) $(HOST_LIBVPX_MAKE_ENV) $(MAKE) -C $(@D) install +endef + $(eval $(generic-package)) +$(eval $(host-generic-package))