From patchwork Wed Nov 20 17:39:32 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thomas Preston X-Patchwork-Id: 1198360 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=codethink.co.uk 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 47J92H3Pqjz9sPn for ; Thu, 21 Nov 2019 04:40:23 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by silver.osuosl.org (Postfix) with ESMTP id F20FB24B04; Wed, 20 Nov 2019 17:40:21 +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 Yfl4m4Hfabkd; Wed, 20 Nov 2019 17:40:17 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by silver.osuosl.org (Postfix) with ESMTP id CD5DF24981; Wed, 20 Nov 2019 17:40:15 +0000 (UTC) X-Original-To: buildroot@lists.busybox.net Delivered-To: buildroot@osuosl.org Received: from silver.osuosl.org (smtp3.osuosl.org [140.211.166.136]) by ash.osuosl.org (Postfix) with ESMTP id 2A1571BF3D0 for ; Wed, 20 Nov 2019 17:39:57 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by silver.osuosl.org (Postfix) with ESMTP id 26EBF204D2 for ; Wed, 20 Nov 2019 17:39:57 +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 5ga0li4zfzmG 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 silver.osuosl.org (Postfix) with ESMTPS id 543C320516 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-BG; Wed, 20 Nov 2019 17:39:54 +0000 From: Thomas Preston To: buildroot@buildroot.org Date: Wed, 20 Nov 2019 17:39:32 +0000 Message-Id: <20191120173944.130142-19-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 18/30] package/ffmpeg: 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/ffmpeg/ffmpeg.mk | 61 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 61 insertions(+) diff --git a/package/ffmpeg/ffmpeg.mk b/package/ffmpeg/ffmpeg.mk index 3dd2e3ef76..d20209d72b 100644 --- a/package/ffmpeg/ffmpeg.mk +++ b/package/ffmpeg/ffmpeg.mk @@ -56,6 +56,46 @@ FFMPEG_CONF_OPTS = \ --disable-symver \ --disable-doc +HOST_FFMPEG_CONF_OPTS = \ + --enable-avfilter \ + --disable-version3 \ + --enable-logging \ + --enable-optimizations \ + --disable-extra-warnings \ + --enable-avdevice \ + --enable-avcodec \ + --enable-avformat \ + --enable-network \ + --disable-gray \ + --enable-swscale-alpha \ + --disable-small \ + --enable-dct \ + --enable-fft \ + --enable-mdct \ + --enable-rdft \ + --disable-crystalhd \ + --disable-dxva2 \ + --enable-runtime-cpudetect \ + --disable-hardcoded-tables \ + --disable-mipsdsp \ + --disable-mipsdspr2 \ + --disable-msa \ + --enable-hwaccels \ + --disable-cuda \ + --disable-cuvid \ + --disable-nvenc \ + --disable-avisynth \ + --disable-frei0r \ + --disable-libopencore-amrnb \ + --disable-libopencore-amrwb \ + --disable-libdc1394 \ + --disable-libgsm \ + --disable-libilbc \ + --disable-libvo-amrwbenc \ + --disable-libxcb \ + --disable-symver \ + --disable-doc + FFMPEG_DEPENDENCIES += host-pkgconf ifeq ($(BR2_PACKAGE_FFMPEG_GPL),y) @@ -413,9 +453,12 @@ endif ifeq ($(BR2_X86_CPU_HAS_MMX),y) FFMPEG_CONF_OPTS += --enable-x86asm FFMPEG_DEPENDENCIES += host-nasm +HOST_FFMPEG_DEPENDENCIES += host-nasm else FFMPEG_CONF_OPTS += --disable-x86asm FFMPEG_CONF_OPTS += --disable-mmx +HOST_FFMPEG_CONF_OPTS += --disable-x86asm +HOST_FFMPEG_CONF_OPTS += --disable-mmx endif ifeq ($(BR2_X86_CPU_HAS_SSE),y) @@ -560,9 +603,27 @@ define FFMPEG_CONFIGURE_CMDS ) endef +HOST_FFMPEG_CONF_ENV += CFLAGS="$(HOST_FFMPEG_CFLAGS)" + +# Override HOST_FFMPEG_CONFIGURE_CMDS: FFmpeg does not support --target and others +define HOST_FFMPEG_CONFIGURE_CMDS + (cd $(HOST_FFMPEG_SRCDIR) && rm -rf config.cache && \ + $(HOST_CONFIGURE_OPTS) \ + $(HOST_CONFIGURE_ARGS) \ + $(HOST_FFMPEG_CONF_ENV) \ + ./configure \ + --prefix="$(HOST_DIR)" \ + --enable-shared --disable-static \ + --disable-doc \ + --disable-debug \ + $(HOST_FFMPEG_CONF_OPTS) \ + ) +endef + define FFMPEG_REMOVE_EXAMPLE_SRC_FILES rm -rf $(TARGET_DIR)/usr/share/ffmpeg/examples endef FFMPEG_POST_INSTALL_TARGET_HOOKS += FFMPEG_REMOVE_EXAMPLE_SRC_FILES $(eval $(autotools-package)) +$(eval $(host-autotools-package))