Alexandre Belloni | 8dfd59d | 2013-06-05 23:53:30 +0000 | [diff] [blame] | 1 | ################################################################################ |
Luca Ceresoli | 1329340 | 2010-06-14 21:41:42 +0200 | [diff] [blame] | 2 | # |
| 3 | # ffmpeg |
| 4 | # |
Alexandre Belloni | 8dfd59d | 2013-06-05 23:53:30 +0000 | [diff] [blame] | 5 | ################################################################################ |
Gustavo Zacarias | 1b269dd | 2011-03-01 13:20:00 -0300 | [diff] [blame] | 6 | |
Bernd Kuhls | a3cf057 | 2016-08-27 08:01:41 +0200 | [diff] [blame] | 7 | FFMPEG_VERSION = 3.1.3 |
Jerzy Grzegorek | 0a854ce | 2015-10-14 12:34:22 +0200 | [diff] [blame] | 8 | FFMPEG_SOURCE = ffmpeg-$(FFMPEG_VERSION).tar.xz |
Gustavo Zacarias | 1b269dd | 2011-03-01 13:20:00 -0300 | [diff] [blame] | 9 | FFMPEG_SITE = http://ffmpeg.org/releases |
Luca Ceresoli | 1329340 | 2010-06-14 21:41:42 +0200 | [diff] [blame] | 10 | FFMPEG_INSTALL_STAGING = YES |
Luca Ceresoli | 1329340 | 2010-06-14 21:41:42 +0200 | [diff] [blame] | 11 | |
Luca Ceresoli | a17d894 | 2013-02-07 11:02:33 +0000 | [diff] [blame] | 12 | FFMPEG_LICENSE = LGPLv2.1+, libjpeg license |
Luca Ceresoli | a20aae6 | 2014-10-02 12:11:01 +0200 | [diff] [blame] | 13 | FFMPEG_LICENSE_FILES = LICENSE.md COPYING.LGPLv2.1 |
Luca Ceresoli | a17d894 | 2013-02-07 11:02:33 +0000 | [diff] [blame] | 14 | ifeq ($(BR2_PACKAGE_FFMPEG_GPL),y) |
| 15 | FFMPEG_LICENSE += and GPLv2+ |
| 16 | FFMPEG_LICENSE_FILES += COPYING.GPLv2 |
| 17 | endif |
| 18 | |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 19 | FFMPEG_CONF_OPTS = \ |
Bernd Kuhls | 79449c2 | 2014-10-03 11:50:46 +0200 | [diff] [blame] | 20 | --prefix=/usr \ |
Bernd Kuhls | 62ab07e | 2014-01-02 18:59:44 +0100 | [diff] [blame] | 21 | --enable-avfilter \ |
Bernd Kuhls | 62ab07e | 2014-01-02 18:59:44 +0100 | [diff] [blame] | 22 | --disable-version3 \ |
| 23 | --enable-logging \ |
Bernd Kuhls | 62ab07e | 2014-01-02 18:59:44 +0100 | [diff] [blame] | 24 | --enable-optimizations \ |
| 25 | --disable-extra-warnings \ |
Bernd Kuhls | 62ab07e | 2014-01-02 18:59:44 +0100 | [diff] [blame] | 26 | --enable-avdevice \ |
| 27 | --enable-avcodec \ |
| 28 | --enable-avformat \ |
Bernd Kuhls | 62ab07e | 2014-01-02 18:59:44 +0100 | [diff] [blame] | 29 | --disable-x11grab \ |
| 30 | --enable-network \ |
| 31 | --disable-gray \ |
| 32 | --enable-swscale-alpha \ |
| 33 | --disable-small \ |
| 34 | --enable-dct \ |
| 35 | --enable-fft \ |
| 36 | --enable-mdct \ |
| 37 | --enable-rdft \ |
| 38 | --disable-crystalhd \ |
Bernd Kuhls | 62ab07e | 2014-01-02 18:59:44 +0100 | [diff] [blame] | 39 | --disable-dxva2 \ |
| 40 | --enable-runtime-cpudetect \ |
| 41 | --disable-hardcoded-tables \ |
| 42 | --disable-memalign-hack \ |
Vicente Olivert Riera | 2893d2f | 2016-08-15 17:03:36 +0200 | [diff] [blame] | 43 | --disable-mipsdsp \ |
Vicente Olivert Riera | b090dcb | 2015-10-14 16:58:22 +0100 | [diff] [blame] | 44 | --disable-mipsdspr2 \ |
Bernd Kuhls | 1ca32ad | 2015-07-24 20:13:47 +0200 | [diff] [blame] | 45 | --disable-msa \ |
Bernd Kuhls | 62ab07e | 2014-01-02 18:59:44 +0100 | [diff] [blame] | 46 | --enable-hwaccels \ |
| 47 | --disable-avisynth \ |
| 48 | --disable-frei0r \ |
| 49 | --disable-libopencore-amrnb \ |
| 50 | --disable-libopencore-amrwb \ |
Bernd Kuhls | 632df1d | 2015-10-17 14:31:58 +0200 | [diff] [blame] | 51 | --disable-libcdio \ |
Bernd Kuhls | 62ab07e | 2014-01-02 18:59:44 +0100 | [diff] [blame] | 52 | --disable-libdc1394 \ |
| 53 | --disable-libfaac \ |
Bernd Kuhls | 62ab07e | 2014-01-02 18:59:44 +0100 | [diff] [blame] | 54 | --disable-libgsm \ |
Bernd Kuhls | 632df1d | 2015-10-17 14:31:58 +0200 | [diff] [blame] | 55 | --disable-libilbc \ |
Bernd Kuhls | 62ab07e | 2014-01-02 18:59:44 +0100 | [diff] [blame] | 56 | --disable-libnut \ |
| 57 | --disable-libopenjpeg \ |
Bernd Kuhls | 62ab07e | 2014-01-02 18:59:44 +0100 | [diff] [blame] | 58 | --disable-libschroedinger \ |
Bernd Kuhls | 62ab07e | 2014-01-02 18:59:44 +0100 | [diff] [blame] | 59 | --disable-libvo-amrwbenc \ |
Bernd Kuhls | 62ab07e | 2014-01-02 18:59:44 +0100 | [diff] [blame] | 60 | --disable-symver \ |
Thomas De Schampheleire | 7164a32 | 2014-02-05 14:50:56 +0100 | [diff] [blame] | 61 | --disable-doc |
Luca Ceresoli | 1329340 | 2010-06-14 21:41:42 +0200 | [diff] [blame] | 62 | |
Danomi Manchego | a9a5a81 | 2014-09-08 22:06:46 -0400 | [diff] [blame] | 63 | FFMPEG_DEPENDENCIES += $(if $(BR2_PACKAGE_LIBICONV),libiconv) host-pkgconf |
Bernd Kuhls | 62ab07e | 2014-01-02 18:59:44 +0100 | [diff] [blame] | 64 | |
Luca Ceresoli | 1329340 | 2010-06-14 21:41:42 +0200 | [diff] [blame] | 65 | ifeq ($(BR2_PACKAGE_FFMPEG_GPL),y) |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 66 | FFMPEG_CONF_OPTS += --enable-gpl |
Luca Ceresoli | 1329340 | 2010-06-14 21:41:42 +0200 | [diff] [blame] | 67 | else |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 68 | FFMPEG_CONF_OPTS += --disable-gpl |
Luca Ceresoli | 1329340 | 2010-06-14 21:41:42 +0200 | [diff] [blame] | 69 | endif |
| 70 | |
| 71 | ifeq ($(BR2_PACKAGE_FFMPEG_NONFREE),y) |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 72 | FFMPEG_CONF_OPTS += --enable-nonfree |
Luca Ceresoli | 1329340 | 2010-06-14 21:41:42 +0200 | [diff] [blame] | 73 | else |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 74 | FFMPEG_CONF_OPTS += --disable-nonfree |
Luca Ceresoli | 1329340 | 2010-06-14 21:41:42 +0200 | [diff] [blame] | 75 | endif |
| 76 | |
Luca Ceresoli | 5253efa | 2010-06-14 21:41:43 +0200 | [diff] [blame] | 77 | ifeq ($(BR2_PACKAGE_FFMPEG_FFMPEG),y) |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 78 | FFMPEG_CONF_OPTS += --enable-ffmpeg |
Luca Ceresoli | 5253efa | 2010-06-14 21:41:43 +0200 | [diff] [blame] | 79 | else |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 80 | FFMPEG_CONF_OPTS += --disable-ffmpeg |
Luca Ceresoli | 5253efa | 2010-06-14 21:41:43 +0200 | [diff] [blame] | 81 | endif |
| 82 | |
| 83 | ifeq ($(BR2_PACKAGE_FFMPEG_FFPLAY),y) |
| 84 | FFMPEG_DEPENDENCIES += sdl |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 85 | FFMPEG_CONF_OPTS += --enable-ffplay |
Luca Ceresoli | 5253efa | 2010-06-14 21:41:43 +0200 | [diff] [blame] | 86 | FFMPEG_CONF_ENV += SDL_CONFIG=$(STAGING_DIR)/usr/bin/sdl-config |
| 87 | else |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 88 | FFMPEG_CONF_OPTS += --disable-ffplay |
Luca Ceresoli | 5253efa | 2010-06-14 21:41:43 +0200 | [diff] [blame] | 89 | endif |
| 90 | |
| 91 | ifeq ($(BR2_PACKAGE_FFMPEG_FFSERVER),y) |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 92 | FFMPEG_CONF_OPTS += --enable-ffserver |
Luca Ceresoli | 5253efa | 2010-06-14 21:41:43 +0200 | [diff] [blame] | 93 | else |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 94 | FFMPEG_CONF_OPTS += --disable-ffserver |
Luca Ceresoli | 5253efa | 2010-06-14 21:41:43 +0200 | [diff] [blame] | 95 | endif |
| 96 | |
Bernd Kuhls | f376585 | 2014-10-14 20:28:24 +0200 | [diff] [blame] | 97 | ifeq ($(BR2_PACKAGE_FFMPEG_AVRESAMPLE),y) |
| 98 | FFMPEG_CONF_OPTS += --enable-avresample |
| 99 | else |
| 100 | FFMPEG_CONF_OPTS += --disable-avresample |
| 101 | endif |
| 102 | |
Steve Kenton | 3b3b4f2 | 2014-12-01 18:55:35 -0600 | [diff] [blame] | 103 | ifeq ($(BR2_PACKAGE_FFMPEG_FFPROBE),y) |
| 104 | FFMPEG_CONF_OPTS += --enable-ffprobe |
| 105 | else |
| 106 | FFMPEG_CONF_OPTS += --disable-ffprobe |
| 107 | endif |
| 108 | |
Peter Korsgaard | 4ff3455 | 2010-10-07 09:54:00 +0200 | [diff] [blame] | 109 | ifeq ($(BR2_PACKAGE_FFMPEG_POSTPROC),y) |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 110 | FFMPEG_CONF_OPTS += --enable-postproc |
Peter Korsgaard | 4ff3455 | 2010-10-07 09:54:00 +0200 | [diff] [blame] | 111 | else |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 112 | FFMPEG_CONF_OPTS += --disable-postproc |
Peter Korsgaard | 4ff3455 | 2010-10-07 09:54:00 +0200 | [diff] [blame] | 113 | endif |
| 114 | |
| 115 | ifeq ($(BR2_PACKAGE_FFMPEG_SWSCALE),y) |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 116 | FFMPEG_CONF_OPTS += --enable-swscale |
Peter Korsgaard | 4ff3455 | 2010-10-07 09:54:00 +0200 | [diff] [blame] | 117 | else |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 118 | FFMPEG_CONF_OPTS += --disable-swscale |
Peter Korsgaard | 4ff3455 | 2010-10-07 09:54:00 +0200 | [diff] [blame] | 119 | endif |
| 120 | |
Luca Ceresoli | 56e4d69 | 2010-06-14 21:41:44 +0200 | [diff] [blame] | 121 | ifneq ($(call qstrip,$(BR2_PACKAGE_FFMPEG_ENCODERS)),all) |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 122 | FFMPEG_CONF_OPTS += --disable-encoders \ |
Luca Ceresoli | 56e4d69 | 2010-06-14 21:41:44 +0200 | [diff] [blame] | 123 | $(foreach x,$(call qstrip,$(BR2_PACKAGE_FFMPEG_ENCODERS)),--enable-encoder=$(x)) |
| 124 | endif |
| 125 | |
| 126 | ifneq ($(call qstrip,$(BR2_PACKAGE_FFMPEG_DECODERS)),all) |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 127 | FFMPEG_CONF_OPTS += --disable-decoders \ |
Luca Ceresoli | 56e4d69 | 2010-06-14 21:41:44 +0200 | [diff] [blame] | 128 | $(foreach x,$(call qstrip,$(BR2_PACKAGE_FFMPEG_DECODERS)),--enable-decoder=$(x)) |
| 129 | endif |
| 130 | |
| 131 | ifneq ($(call qstrip,$(BR2_PACKAGE_FFMPEG_MUXERS)),all) |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 132 | FFMPEG_CONF_OPTS += --disable-muxers \ |
Luca Ceresoli | 56e4d69 | 2010-06-14 21:41:44 +0200 | [diff] [blame] | 133 | $(foreach x,$(call qstrip,$(BR2_PACKAGE_FFMPEG_MUXERS)),--enable-muxer=$(x)) |
| 134 | endif |
| 135 | |
| 136 | ifneq ($(call qstrip,$(BR2_PACKAGE_FFMPEG_DEMUXERS)),all) |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 137 | FFMPEG_CONF_OPTS += --disable-demuxers \ |
Luca Ceresoli | 56e4d69 | 2010-06-14 21:41:44 +0200 | [diff] [blame] | 138 | $(foreach x,$(call qstrip,$(BR2_PACKAGE_FFMPEG_DEMUXERS)),--enable-demuxer=$(x)) |
| 139 | endif |
| 140 | |
| 141 | ifneq ($(call qstrip,$(BR2_PACKAGE_FFMPEG_PARSERS)),all) |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 142 | FFMPEG_CONF_OPTS += --disable-parsers \ |
Luca Ceresoli | 56e4d69 | 2010-06-14 21:41:44 +0200 | [diff] [blame] | 143 | $(foreach x,$(call qstrip,$(BR2_PACKAGE_FFMPEG_PARSERS)),--enable-parser=$(x)) |
| 144 | endif |
| 145 | |
| 146 | ifneq ($(call qstrip,$(BR2_PACKAGE_FFMPEG_BSFS)),all) |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 147 | FFMPEG_CONF_OPTS += --disable-bsfs \ |
Bernd Kuhls | 62ab07e | 2014-01-02 18:59:44 +0100 | [diff] [blame] | 148 | $(foreach x,$(call qstrip,$(BR2_PACKAGE_FFMPEG_BSFS)),--enable-bsfs=$(x)) |
Luca Ceresoli | 56e4d69 | 2010-06-14 21:41:44 +0200 | [diff] [blame] | 149 | endif |
| 150 | |
| 151 | ifneq ($(call qstrip,$(BR2_PACKAGE_FFMPEG_PROTOCOLS)),all) |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 152 | FFMPEG_CONF_OPTS += --disable-protocols \ |
Luca Ceresoli | 56e4d69 | 2010-06-14 21:41:44 +0200 | [diff] [blame] | 153 | $(foreach x,$(call qstrip,$(BR2_PACKAGE_FFMPEG_PROTOCOLS)),--enable-protocol=$(x)) |
| 154 | endif |
| 155 | |
| 156 | ifneq ($(call qstrip,$(BR2_PACKAGE_FFMPEG_FILTERS)),all) |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 157 | FFMPEG_CONF_OPTS += --disable-filters \ |
Luca Ceresoli | 56e4d69 | 2010-06-14 21:41:44 +0200 | [diff] [blame] | 158 | $(foreach x,$(call qstrip,$(BR2_PACKAGE_FFMPEG_FILTERS)),--enable-filter=$(x)) |
| 159 | endif |
| 160 | |
| 161 | ifeq ($(BR2_PACKAGE_FFMPEG_INDEVS),y) |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 162 | FFMPEG_CONF_OPTS += --enable-indevs |
Luca Ceresoli | 56e4d69 | 2010-06-14 21:41:44 +0200 | [diff] [blame] | 163 | else |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 164 | FFMPEG_CONF_OPTS += --disable-indevs |
Luca Ceresoli | 56e4d69 | 2010-06-14 21:41:44 +0200 | [diff] [blame] | 165 | endif |
| 166 | |
| 167 | ifeq ($(BR2_PACKAGE_FFMPEG_OUTDEVS),y) |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 168 | FFMPEG_CONF_OPTS += --enable-outdevs |
Luca Ceresoli | 56e4d69 | 2010-06-14 21:41:44 +0200 | [diff] [blame] | 169 | else |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 170 | FFMPEG_CONF_OPTS += --disable-outdevs |
Luca Ceresoli | 56e4d69 | 2010-06-14 21:41:44 +0200 | [diff] [blame] | 171 | endif |
| 172 | |
Thomas Petazzoni | 9eaad20 | 2010-12-13 17:27:44 +0100 | [diff] [blame] | 173 | ifeq ($(BR2_TOOLCHAIN_HAS_THREADS),y) |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 174 | FFMPEG_CONF_OPTS += --enable-pthreads |
Thomas Petazzoni | 9eaad20 | 2010-12-13 17:27:44 +0100 | [diff] [blame] | 175 | else |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 176 | FFMPEG_CONF_OPTS += --disable-pthreads |
Luca Ceresoli | 1329340 | 2010-06-14 21:41:42 +0200 | [diff] [blame] | 177 | endif |
| 178 | |
| 179 | ifeq ($(BR2_PACKAGE_ZLIB),y) |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 180 | FFMPEG_CONF_OPTS += --enable-zlib |
Luca Ceresoli | 1329340 | 2010-06-14 21:41:42 +0200 | [diff] [blame] | 181 | FFMPEG_DEPENDENCIES += zlib |
| 182 | else |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 183 | FFMPEG_CONF_OPTS += --disable-zlib |
Luca Ceresoli | 1329340 | 2010-06-14 21:41:42 +0200 | [diff] [blame] | 184 | endif |
| 185 | |
Bernd Kuhls | 62ab07e | 2014-01-02 18:59:44 +0100 | [diff] [blame] | 186 | ifeq ($(BR2_PACKAGE_BZIP2),y) |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 187 | FFMPEG_CONF_OPTS += --enable-bzlib |
Bernd Kuhls | 62ab07e | 2014-01-02 18:59:44 +0100 | [diff] [blame] | 188 | FFMPEG_DEPENDENCIES += bzip2 |
Arnout Vandecappelle (Essensium/Mind) | 4e20ad1 | 2012-01-22 13:04:16 +0100 | [diff] [blame] | 189 | else |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 190 | FFMPEG_CONF_OPTS += --disable-bzlib |
Arnout Vandecappelle (Essensium/Mind) | 4e20ad1 | 2012-01-22 13:04:16 +0100 | [diff] [blame] | 191 | endif |
Bernd Kuhls | 62ab07e | 2014-01-02 18:59:44 +0100 | [diff] [blame] | 192 | |
Bernd Kuhls | 632df1d | 2015-10-17 14:31:58 +0200 | [diff] [blame] | 193 | ifeq ($(BR2_PACKAGE_FDK_AAC)$(BR2_PACKAGE_FFMPEG_NONFREE),yy) |
| 194 | FFMPEG_CONF_OPTS += --enable-libfdk-aac |
| 195 | FFMPEG_DEPENDENCIES += fdk-aac |
| 196 | else |
| 197 | FFMPEG_CONF_OPTS += --disable-libfdk-aac |
| 198 | endif |
| 199 | |
Bernd Kuhls | 5f7411e | 2015-10-17 21:38:56 +0200 | [diff] [blame] | 200 | ifeq ($(BR2_PACKAGE_GNUTLS),y) |
| 201 | FFMPEG_CONF_OPTS += --enable-gnutls --disable-openssl |
| 202 | FFMPEG_DEPENDENCIES += gnutls |
| 203 | else |
| 204 | FFMPEG_CONF_OPTS += --disable-gnutls |
Bernd Kuhls | 62ab07e | 2014-01-02 18:59:44 +0100 | [diff] [blame] | 205 | ifeq ($(BR2_PACKAGE_OPENSSL),y) |
Peter Korsgaard | 457b646 | 2014-01-13 13:11:39 +0100 | [diff] [blame] | 206 | # openssl isn't license compatible with GPL |
| 207 | ifeq ($(BR2_PACKAGE_FFMPEG_GPL)x$(BR2_PACKAGE_FFMPEG_NONFREE),yx) |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 208 | FFMPEG_CONF_OPTS += --disable-openssl |
Peter Korsgaard | 457b646 | 2014-01-13 13:11:39 +0100 | [diff] [blame] | 209 | else |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 210 | FFMPEG_CONF_OPTS += --enable-openssl |
Bernd Kuhls | 62ab07e | 2014-01-02 18:59:44 +0100 | [diff] [blame] | 211 | FFMPEG_DEPENDENCIES += openssl |
Peter Korsgaard | 457b646 | 2014-01-13 13:11:39 +0100 | [diff] [blame] | 212 | endif |
Bernd Kuhls | 62ab07e | 2014-01-02 18:59:44 +0100 | [diff] [blame] | 213 | else |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 214 | FFMPEG_CONF_OPTS += --disable-openssl |
Bernd Kuhls | 62ab07e | 2014-01-02 18:59:44 +0100 | [diff] [blame] | 215 | endif |
Bernd Kuhls | 5f7411e | 2015-10-17 21:38:56 +0200 | [diff] [blame] | 216 | endif |
Bernd Kuhls | 62ab07e | 2014-01-02 18:59:44 +0100 | [diff] [blame] | 217 | |
Bernd Kuhls | af127a6 | 2016-07-24 17:53:18 +0200 | [diff] [blame] | 218 | ifeq ($(BR2_PACKAGE_FFMPEG_GPL)$(BR2_PACKAGE_LIBEBUR128),yy) |
| 219 | FFMPEG_DEPENDENCIES += libebur128 |
| 220 | endif |
| 221 | |
Bernd Kuhls | 632df1d | 2015-10-17 14:31:58 +0200 | [diff] [blame] | 222 | ifeq ($(BR2_PACKAGE_LIBOPENH264),y) |
| 223 | FFMPEG_CONF_OPTS += --enable-libopenh264 |
| 224 | FFMPEG_DEPENDENCIES += libopenh264 |
| 225 | else |
| 226 | FFMPEG_CONF_OPTS += --disable-libopenh264 |
| 227 | endif |
| 228 | |
Bernd Kuhls | 62ab07e | 2014-01-02 18:59:44 +0100 | [diff] [blame] | 229 | ifeq ($(BR2_PACKAGE_LIBVORBIS),y) |
| 230 | FFMPEG_DEPENDENCIES += libvorbis |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 231 | FFMPEG_CONF_OPTS += \ |
Bernd Kuhls | 62ab07e | 2014-01-02 18:59:44 +0100 | [diff] [blame] | 232 | --enable-libvorbis \ |
| 233 | --enable-muxer=ogg \ |
| 234 | --enable-encoder=libvorbis |
| 235 | endif |
| 236 | |
Bernd Kuhls | 17240db | 2014-07-15 21:19:03 +0200 | [diff] [blame] | 237 | ifeq ($(BR2_PACKAGE_LIBVA),y) |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 238 | FFMPEG_CONF_OPTS += --enable-vaapi |
Bernd Kuhls | 17240db | 2014-07-15 21:19:03 +0200 | [diff] [blame] | 239 | FFMPEG_DEPENDENCIES += libva |
| 240 | else |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 241 | FFMPEG_CONF_OPTS += --disable-vaapi |
Bernd Kuhls | 17240db | 2014-07-15 21:19:03 +0200 | [diff] [blame] | 242 | endif |
| 243 | |
Bernd Kuhls | c26132c | 2016-07-07 22:49:14 +0200 | [diff] [blame] | 244 | ifeq ($(BR2_PACKAGE_LIBVDPAU),y) |
| 245 | FFMPEG_CONF_OPTS += --enable-vdpau |
| 246 | FFMPEG_DEPENDENCIES += libvdpau |
| 247 | else |
| 248 | FFMPEG_CONF_OPTS += --disable-vdpau |
| 249 | endif |
| 250 | |
Bernd Kuhls | d9ea464 | 2016-08-15 17:03:39 +0200 | [diff] [blame] | 251 | # To avoid a circular dependency only use opencv if opencv itself does |
| 252 | # not depend on ffmpeg. |
| 253 | ifeq ($(BR2_PACKAGE_OPENCV_LIB_IMGPROC)x$(BR2_PACKAGE_OPENCV_WITH_FFMPEG),yx) |
| 254 | FFMPEG_CONF_OPTS += --enable-libopencv |
| 255 | FFMPEG_DEPENDENCIES += opencv |
Bernd Kuhls | 1b69855 | 2016-09-05 16:51:20 +0200 | [diff] [blame^] | 256 | else ifeq ($(BR2_PACKAGE_OPENCV3_LIB_IMGPROC)x$(BR2_PACKAGE_OPENCV3_WITH_FFMPEG),yx) |
| 257 | FFMPEG_CONF_OPTS += --enable-libopencv |
| 258 | FFMPEG_DEPENDENCIES += opencv3 |
Bernd Kuhls | d9ea464 | 2016-08-15 17:03:39 +0200 | [diff] [blame] | 259 | else |
| 260 | FFMPEG_CONF_OPTS += --disable-libopencv |
| 261 | endif |
| 262 | |
David du Colombier | ad58c88 | 2014-09-30 15:28:05 +0200 | [diff] [blame] | 263 | ifeq ($(BR2_PACKAGE_OPUS),y) |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 264 | FFMPEG_CONF_OPTS += --enable-libopus |
David du Colombier | ad58c88 | 2014-09-30 15:28:05 +0200 | [diff] [blame] | 265 | FFMPEG_DEPENDENCIES += opus |
| 266 | else |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 267 | FFMPEG_CONF_OPTS += --disable-libopus |
David du Colombier | ad58c88 | 2014-09-30 15:28:05 +0200 | [diff] [blame] | 268 | endif |
| 269 | |
David du Colombier | 8a966c8 | 2014-09-30 15:28:04 +0200 | [diff] [blame] | 270 | ifeq ($(BR2_PACKAGE_LIBVPX),y) |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 271 | FFMPEG_CONF_OPTS += --enable-libvpx |
David du Colombier | 8a966c8 | 2014-09-30 15:28:04 +0200 | [diff] [blame] | 272 | FFMPEG_DEPENDENCIES += libvpx |
| 273 | else |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 274 | FFMPEG_CONF_OPTS += --disable-libvpx |
David du Colombier | 8a966c8 | 2014-09-30 15:28:04 +0200 | [diff] [blame] | 275 | endif |
| 276 | |
Bernd Kuhls | 0c14259 | 2015-08-01 16:20:41 +0200 | [diff] [blame] | 277 | ifeq ($(BR2_PACKAGE_LIBASS),y) |
| 278 | FFMPEG_CONF_OPTS += --enable-libass |
| 279 | FFMPEG_DEPENDENCIES += libass |
| 280 | else |
| 281 | FFMPEG_CONF_OPTS += --disable-libass |
| 282 | endif |
| 283 | |
| 284 | ifeq ($(BR2_PACKAGE_LIBBLURAY),y) |
| 285 | FFMPEG_CONF_OPTS += --enable-libbluray |
| 286 | FFMPEG_DEPENDENCIES += libbluray |
| 287 | else |
| 288 | FFMPEG_CONF_OPTS += --disable-libbluray |
| 289 | endif |
| 290 | |
| 291 | ifeq ($(BR2_PACKAGE_RTMPDUMP),y) |
| 292 | FFMPEG_CONF_OPTS += --enable-librtmp |
| 293 | FFMPEG_DEPENDENCIES += rtmpdump |
| 294 | else |
| 295 | FFMPEG_CONF_OPTS += --disable-librtmp |
| 296 | endif |
| 297 | |
| 298 | ifeq ($(BR2_PACKAGE_LAME),y) |
| 299 | FFMPEG_CONF_OPTS += --enable-libmp3lame |
| 300 | FFMPEG_DEPENDENCIES += lame |
| 301 | else |
| 302 | FFMPEG_CONF_OPTS += --disable-libmp3lame |
| 303 | endif |
| 304 | |
| 305 | ifeq ($(BR2_PACKAGE_LIBMODPLUG),y) |
| 306 | FFMPEG_CONF_OPTS += --enable-libmodplug |
| 307 | FFMPEG_DEPENDENCIES += libmodplug |
| 308 | else |
| 309 | FFMPEG_CONF_OPTS += --disable-libmodplug |
| 310 | endif |
| 311 | |
| 312 | ifeq ($(BR2_PACKAGE_SPEEX),y) |
| 313 | FFMPEG_CONF_OPTS += --enable-libspeex |
| 314 | FFMPEG_DEPENDENCIES += speex |
| 315 | else |
| 316 | FFMPEG_CONF_OPTS += --disable-libspeex |
| 317 | endif |
| 318 | |
| 319 | ifeq ($(BR2_PACKAGE_LIBTHEORA),y) |
| 320 | FFMPEG_CONF_OPTS += --enable-libtheora |
| 321 | FFMPEG_DEPENDENCIES += libtheora |
| 322 | else |
| 323 | FFMPEG_CONF_OPTS += --disable-libtheora |
| 324 | endif |
| 325 | |
| 326 | ifeq ($(BR2_PACKAGE_WAVPACK),y) |
| 327 | FFMPEG_CONF_OPTS += --enable-libwavpack |
| 328 | FFMPEG_DEPENDENCIES += wavpack |
| 329 | else |
| 330 | FFMPEG_CONF_OPTS += --disable-libwavpack |
| 331 | endif |
| 332 | |
Steve Kenton | 0ff42f1 | 2015-01-26 19:22:35 -0600 | [diff] [blame] | 333 | # ffmpeg freetype support require fenv.h which is only |
Peter Korsgaard | 64a4980 | 2015-01-31 08:18:30 +0100 | [diff] [blame] | 334 | # available/working on glibc. |
| 335 | # The microblaze variant doesn't provide the needed exceptions |
| 336 | ifeq ($(BR2_PACKAGE_FREETYPE)$(BR2_TOOLCHAIN_USES_GLIBC)x$(BR2_microblaze),yyx) |
Steve Kenton | 0ff42f1 | 2015-01-26 19:22:35 -0600 | [diff] [blame] | 337 | FFMPEG_CONF_OPTS += --enable-libfreetype |
| 338 | FFMPEG_DEPENDENCIES += freetype |
| 339 | else |
| 340 | FFMPEG_CONF_OPTS += --disable-libfreetype |
| 341 | endif |
| 342 | |
| 343 | ifeq ($(BR2_PACKAGE_FONTCONFIG),y) |
| 344 | FFMPEG_CONF_OPTS += --enable-fontconfig |
| 345 | FFMPEG_DEPENDENCIES += fontconfig |
| 346 | else |
| 347 | FFMPEG_CONF_OPTS += --disable-fontconfig |
| 348 | endif |
| 349 | |
David du Colombier | 3182056 | 2014-10-05 18:29:57 +0200 | [diff] [blame] | 350 | ifeq ($(BR2_PACKAGE_X264)$(BR2_PACKAGE_FFMPEG_GPL),yy) |
| 351 | FFMPEG_CONF_OPTS += --enable-libx264 |
| 352 | FFMPEG_DEPENDENCIES += x264 |
| 353 | else |
| 354 | FFMPEG_CONF_OPTS += --disable-libx264 |
| 355 | endif |
| 356 | |
Bernd Kuhls | d6a6958 | 2015-11-01 19:47:29 +0100 | [diff] [blame] | 357 | ifeq ($(BR2_PACKAGE_X265)$(BR2_PACKAGE_FFMPEG_GPL),yy) |
| 358 | FFMPEG_CONF_OPTS += --enable-libx265 |
| 359 | FFMPEG_DEPENDENCIES += x265 |
| 360 | else |
| 361 | FFMPEG_CONF_OPTS += --disable-libx265 |
| 362 | endif |
| 363 | |
Bernd Kuhls | 62ab07e | 2014-01-02 18:59:44 +0100 | [diff] [blame] | 364 | ifeq ($(BR2_X86_CPU_HAS_MMX),y) |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 365 | FFMPEG_CONF_OPTS += --enable-yasm |
Bernd Kuhls | 8eb78ba | 2014-01-13 06:48:11 +0100 | [diff] [blame] | 366 | FFMPEG_DEPENDENCIES += host-yasm |
Bernd Kuhls | 62ab07e | 2014-01-02 18:59:44 +0100 | [diff] [blame] | 367 | else |
Bernd Kuhls | bfb8df2 | 2015-06-20 21:44:55 +0200 | [diff] [blame] | 368 | ifeq ($(BR2_x86_i586),y) |
| 369 | # Needed to work around a bug with gcc 5.x: |
| 370 | # error: 'asm' operand has impossible constraints |
| 371 | FFMPEG_CONF_OPTS += --disable-inline-asm |
| 372 | endif |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 373 | FFMPEG_CONF_OPTS += --disable-yasm |
| 374 | FFMPEG_CONF_OPTS += --disable-mmx |
Bernd Kuhls | 62ab07e | 2014-01-02 18:59:44 +0100 | [diff] [blame] | 375 | endif |
| 376 | |
| 377 | ifeq ($(BR2_X86_CPU_HAS_SSE),y) |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 378 | FFMPEG_CONF_OPTS += --enable-sse |
Bernd Kuhls | 62ab07e | 2014-01-02 18:59:44 +0100 | [diff] [blame] | 379 | else |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 380 | FFMPEG_CONF_OPTS += --disable-sse |
Bernd Kuhls | 62ab07e | 2014-01-02 18:59:44 +0100 | [diff] [blame] | 381 | endif |
| 382 | |
| 383 | ifeq ($(BR2_X86_CPU_HAS_SSE2),y) |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 384 | FFMPEG_CONF_OPTS += --enable-sse2 |
Bernd Kuhls | 62ab07e | 2014-01-02 18:59:44 +0100 | [diff] [blame] | 385 | else |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 386 | FFMPEG_CONF_OPTS += --disable-sse2 |
Bernd Kuhls | 62ab07e | 2014-01-02 18:59:44 +0100 | [diff] [blame] | 387 | endif |
| 388 | |
| 389 | ifeq ($(BR2_X86_CPU_HAS_SSE3),y) |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 390 | FFMPEG_CONF_OPTS += --enable-sse3 |
Bernd Kuhls | 62ab07e | 2014-01-02 18:59:44 +0100 | [diff] [blame] | 391 | else |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 392 | FFMPEG_CONF_OPTS += --disable-sse3 |
Bernd Kuhls | 62ab07e | 2014-01-02 18:59:44 +0100 | [diff] [blame] | 393 | endif |
| 394 | |
| 395 | ifeq ($(BR2_X86_CPU_HAS_SSSE3),y) |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 396 | FFMPEG_CONF_OPTS += --enable-ssse3 |
Bernd Kuhls | 62ab07e | 2014-01-02 18:59:44 +0100 | [diff] [blame] | 397 | else |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 398 | FFMPEG_CONF_OPTS += --disable-ssse3 |
Gustavo Zacarias | 3f6aa3e | 2011-02-28 11:18:21 -0300 | [diff] [blame] | 399 | endif |
| 400 | |
Bernd Kuhls | 0e8e3c2 | 2014-01-02 18:59:45 +0100 | [diff] [blame] | 401 | ifeq ($(BR2_X86_CPU_HAS_SSE4),y) |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 402 | FFMPEG_CONF_OPTS += --enable-sse4 |
Bernd Kuhls | 0e8e3c2 | 2014-01-02 18:59:45 +0100 | [diff] [blame] | 403 | else |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 404 | FFMPEG_CONF_OPTS += --disable-sse4 |
Bernd Kuhls | 0e8e3c2 | 2014-01-02 18:59:45 +0100 | [diff] [blame] | 405 | endif |
| 406 | |
| 407 | ifeq ($(BR2_X86_CPU_HAS_SSE42),y) |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 408 | FFMPEG_CONF_OPTS += --enable-sse42 |
Bernd Kuhls | 0e8e3c2 | 2014-01-02 18:59:45 +0100 | [diff] [blame] | 409 | else |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 410 | FFMPEG_CONF_OPTS += --disable-sse42 |
Bernd Kuhls | 0e8e3c2 | 2014-01-02 18:59:45 +0100 | [diff] [blame] | 411 | endif |
| 412 | |
Steven Noonan | 1cd92d2 | 2015-03-18 15:01:11 -0700 | [diff] [blame] | 413 | ifeq ($(BR2_X86_CPU_HAS_AVX),y) |
| 414 | FFMPEG_CONF_OPTS += --enable-avx |
| 415 | else |
| 416 | FFMPEG_CONF_OPTS += --disable-avx |
| 417 | endif |
| 418 | |
| 419 | ifeq ($(BR2_X86_CPU_HAS_AVX2),y) |
| 420 | FFMPEG_CONF_OPTS += --enable-avx2 |
| 421 | else |
| 422 | FFMPEG_CONF_OPTS += --disable-avx2 |
| 423 | endif |
| 424 | |
Gustavo Zacarias | 9e77eaf | 2012-12-21 02:40:31 +0000 | [diff] [blame] | 425 | # Explicitly disable everything that doesn't match for ARM |
| 426 | # FFMPEG "autodetects" by compiling an extended instruction via AS |
| 427 | # This works on compilers that aren't built for generic by default |
Thomas Petazzoni | 0ac115d | 2014-10-21 22:26:49 +0200 | [diff] [blame] | 428 | ifeq ($(BR2_ARM_CPU_ARMV4),y) |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 429 | FFMPEG_CONF_OPTS += --disable-armv5te |
Gustavo Zacarias | 1b269dd | 2011-03-01 13:20:00 -0300 | [diff] [blame] | 430 | endif |
Thomas Petazzoni | 0ac115d | 2014-10-21 22:26:49 +0200 | [diff] [blame] | 431 | ifeq ($(BR2_ARM_CPU_ARMV6)$(BR2_ARM_CPU_ARMV7A),y) |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 432 | FFMPEG_CONF_OPTS += --enable-armv6 |
Gustavo Zacarias | 9e77eaf | 2012-12-21 02:40:31 +0000 | [diff] [blame] | 433 | else |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 434 | FFMPEG_CONF_OPTS += --disable-armv6 --disable-armv6t2 |
Gustavo Zacarias | 1b269dd | 2011-03-01 13:20:00 -0300 | [diff] [blame] | 435 | endif |
Thomas Petazzoni | 3300e00 | 2014-10-21 22:26:50 +0200 | [diff] [blame] | 436 | ifeq ($(BR2_ARM_CPU_HAS_VFPV2),y) |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 437 | FFMPEG_CONF_OPTS += --enable-vfp |
Gustavo Zacarias | 9e77eaf | 2012-12-21 02:40:31 +0000 | [diff] [blame] | 438 | else |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 439 | FFMPEG_CONF_OPTS += --disable-vfp |
Gustavo Zacarias | 1b269dd | 2011-03-01 13:20:00 -0300 | [diff] [blame] | 440 | endif |
Peter Korsgaard | ce8a7d5 | 2012-12-13 23:25:30 +0100 | [diff] [blame] | 441 | ifeq ($(BR2_ARM_CPU_HAS_NEON),y) |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 442 | FFMPEG_CONF_OPTS += --enable-neon |
Thomas Petazzoni | ae7becf | 2016-08-10 23:29:03 +0200 | [diff] [blame] | 443 | else |
| 444 | FFMPEG_CONF_OPTS += --disable-neon |
Gustavo Zacarias | 1b269dd | 2011-03-01 13:20:00 -0300 | [diff] [blame] | 445 | endif |
Gustavo Zacarias | 9e77eaf | 2012-12-21 02:40:31 +0000 | [diff] [blame] | 446 | |
Thomas Petazzoni | fdd0f8d | 2016-08-10 23:29:04 +0200 | [diff] [blame] | 447 | ifeq ($(BR2_mips)$(BR2_mipsel)$(BR2_mips64)$(BR2_mips64el),y) |
Bernd Kuhls | 0fff250 | 2014-01-13 22:23:06 +0100 | [diff] [blame] | 448 | ifeq ($(BR2_MIPS_SOFT_FLOAT),y) |
Vicente Olivert Riera | 9aee557 | 2016-07-02 15:32:15 +0200 | [diff] [blame] | 449 | FFMPEG_CONF_OPTS += --disable-mipsfpu |
Bernd Kuhls | 0fff250 | 2014-01-13 22:23:06 +0100 | [diff] [blame] | 450 | else |
Vicente Olivert Riera | 9aee557 | 2016-07-02 15:32:15 +0200 | [diff] [blame] | 451 | FFMPEG_CONF_OPTS += --enable-mipsfpu |
Bernd Kuhls | 0fff250 | 2014-01-13 22:23:06 +0100 | [diff] [blame] | 452 | endif |
Thomas Petazzoni | fdd0f8d | 2016-08-10 23:29:04 +0200 | [diff] [blame] | 453 | endif # MIPS |
Bernd Kuhls | 0fff250 | 2014-01-13 22:23:06 +0100 | [diff] [blame] | 454 | |
Cody P Schafer | 40e58da | 2014-05-12 22:28:17 -0700 | [diff] [blame] | 455 | ifeq ($(BR2_POWERPC_CPU_HAS_ALTIVEC),y) |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 456 | FFMPEG_CONF_OPTS += --enable-altivec |
Mike Williams | 29a0768 | 2011-05-12 16:12:40 -0400 | [diff] [blame] | 457 | else |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 458 | FFMPEG_CONF_OPTS += --disable-altivec |
Mike Williams | 29a0768 | 2011-05-12 16:12:40 -0400 | [diff] [blame] | 459 | endif |
Gustavo Zacarias | 1b269dd | 2011-03-01 13:20:00 -0300 | [diff] [blame] | 460 | |
Thomas Petazzoni | 665e13c | 2014-12-03 22:41:29 +0100 | [diff] [blame] | 461 | ifeq ($(BR2_STATIC_LIBS),) |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 462 | FFMPEG_CONF_OPTS += --enable-pic |
Danomi Manchego | 255aab7 | 2014-09-08 22:06:44 -0400 | [diff] [blame] | 463 | else |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 464 | FFMPEG_CONF_OPTS += --disable-pic |
Bernd Kuhls | 62ab07e | 2014-01-02 18:59:44 +0100 | [diff] [blame] | 465 | endif |
| 466 | |
Vicente Olivert Riera | 30a87d3 | 2016-08-15 17:03:37 +0200 | [diff] [blame] | 467 | # Default to --cpu=generic for MIPS architecture, in order to avoid a |
| 468 | # warning from ffmpeg's configure script. |
| 469 | ifeq ($(BR2_mips)$(BR2_mipsel)$(BR2_mips64)$(BR2_mips64el),y) |
| 470 | FFMPEG_CONF_OPTS += --cpu=generic |
| 471 | else ifneq ($(call qstrip,$(BR2_GCC_TARGET_CPU)),) |
Thomas Petazzoni | ae2850b | 2014-10-21 22:27:10 +0200 | [diff] [blame] | 472 | FFMPEG_CONF_OPTS += --cpu=$(BR2_GCC_TARGET_CPU) |
Karoly Kasza | d402daa | 2014-11-07 09:44:16 +0100 | [diff] [blame] | 473 | else ifneq ($(call qstrip,$(BR2_GCC_TARGET_ARCH)),) |
Thomas Petazzoni | ae2850b | 2014-10-21 22:27:10 +0200 | [diff] [blame] | 474 | FFMPEG_CONF_OPTS += --cpu=$(BR2_GCC_TARGET_ARCH) |
| 475 | endif |
| 476 | |
Vicente Olivert Riera | 30a87d3 | 2016-08-15 17:03:37 +0200 | [diff] [blame] | 477 | |
Vicente Olivert Riera | 8849e80 | 2015-10-15 13:22:55 +0100 | [diff] [blame] | 478 | FFMPEG_CONF_OPTS += $(call qstrip,$(BR2_PACKAGE_FFMPEG_EXTRACONF)) |
| 479 | |
Luca Ceresoli | 1329340 | 2010-06-14 21:41:42 +0200 | [diff] [blame] | 480 | # Override FFMPEG_CONFIGURE_CMDS: FFmpeg does not support --target and others |
| 481 | define FFMPEG_CONFIGURE_CMDS |
| 482 | (cd $(FFMPEG_SRCDIR) && rm -rf config.cache && \ |
| 483 | $(TARGET_CONFIGURE_OPTS) \ |
| 484 | $(TARGET_CONFIGURE_ARGS) \ |
Luca Ceresoli | 1329340 | 2010-06-14 21:41:42 +0200 | [diff] [blame] | 485 | $(FFMPEG_CONF_ENV) \ |
| 486 | ./configure \ |
Bernd Kuhls | 79449c2 | 2014-10-03 11:50:46 +0200 | [diff] [blame] | 487 | --enable-cross-compile \ |
Luca Ceresoli | 1329340 | 2010-06-14 21:41:42 +0200 | [diff] [blame] | 488 | --cross-prefix=$(TARGET_CROSS) \ |
| 489 | --sysroot=$(STAGING_DIR) \ |
Peter Korsgaard | e18087a | 2011-01-01 11:49:01 +0100 | [diff] [blame] | 490 | --host-cc="$(HOSTCC)" \ |
Luca Ceresoli | 1329340 | 2010-06-14 21:41:42 +0200 | [diff] [blame] | 491 | --arch=$(BR2_ARCH) \ |
Bernd Kuhls | 62ab07e | 2014-01-02 18:59:44 +0100 | [diff] [blame] | 492 | --target-os="linux" \ |
Bernd Kuhls | 12a3ecf | 2014-08-10 14:46:46 +0200 | [diff] [blame] | 493 | --disable-stripping \ |
Danomi Manchego | a9a5a81 | 2014-09-08 22:06:46 -0400 | [diff] [blame] | 494 | --pkg-config="$(PKG_CONFIG_HOST_BINARY)" \ |
Luca Ceresoli | 97a4296 | 2011-06-20 17:59:54 +0200 | [diff] [blame] | 495 | $(SHARED_STATIC_LIBS_OPTS) \ |
Thomas De Schampheleire | aaffd20 | 2014-09-27 21:32:44 +0200 | [diff] [blame] | 496 | $(FFMPEG_CONF_OPTS) \ |
Luca Ceresoli | 1329340 | 2010-06-14 21:41:42 +0200 | [diff] [blame] | 497 | ) |
| 498 | endef |
| 499 | |
Arnout Vandecappelle (Essensium/Mind) | e1502eb | 2012-07-03 00:07:32 +0200 | [diff] [blame] | 500 | $(eval $(autotools-package)) |