From f7ff0f34d57b7636878168fcf8dac8252eae7c5634c70206d89550be36074796 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ismail=20D=C3=B6nmez?= Date: Fri, 28 Jun 2019 08:28:01 +0000 Subject: [PATCH 1/4] - OBS-URL: https://build.opensuse.org/package/show/multimedia:libs/ffmpeg-4?expand=0&rev=73 --- ...open-faac-mp3lame-opencore-x264-x265-xvid.patch | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/ffmpeg-4.1-dlopen-faac-mp3lame-opencore-x264-x265-xvid.patch b/ffmpeg-4.1-dlopen-faac-mp3lame-opencore-x264-x265-xvid.patch index 41a6c09..38e1de8 100644 --- a/ffmpeg-4.1-dlopen-faac-mp3lame-opencore-x264-x265-xvid.patch +++ b/ffmpeg-4.1-dlopen-faac-mp3lame-opencore-x264-x265-xvid.patch @@ -141,7 +141,17 @@ Index: ffmpeg-4.1.3/libavcodec/libfdk-aacdec.c =================================================================== --- ffmpeg-4.1.3.orig/libavcodec/libfdk-aacdec.c +++ ffmpeg-4.1.3/libavcodec/libfdk-aacdec.c -@@ -37,6 +37,54 @@ +@@ -17,7 +17,9 @@ + * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + */ + ++#ifndef CONFIG_LIBFDK_AAC_DLOPEN + #include ++#endif + + #include "libavutil/channel_layout.h" + #include "libavutil/common.h" +@@ -37,6 +39,54 @@ #define AAC_PCM_MAX_OUTPUT_CHANNELS AAC_PCM_OUTPUT_CHANNELS #endif @@ -196,7 +206,7 @@ Index: ffmpeg-4.1.3/libavcodec/libfdk-aacdec.c enum ConcealMethod { CONCEAL_METHOD_SPECTRAL_MUTING = 0, CONCEAL_METHOD_NOISE_SUBSTITUTION = 1, -@@ -224,6 +272,11 @@ static av_cold int fdk_aac_decode_init(A +@@ -224,6 +274,11 @@ static av_cold int fdk_aac_decode_init(A FDKAACDecContext *s = avctx->priv_data; AAC_DECODER_ERROR err; From 04de1162ee49a0a64d69f0eadc28bb79e8de6c13c495382e5f638e650822e5b2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ismail=20D=C3=B6nmez?= Date: Tue, 2 Jul 2019 09:03:42 +0000 Subject: [PATCH 2/4] Revert last OBS-URL: https://build.opensuse.org/package/show/multimedia:libs/ffmpeg-4?expand=0&rev=74 --- ...1-dlopen-faac-mp3lame-opencore-x264-x265-xvid.patch | 10 ---------- 1 file changed, 10 deletions(-) diff --git a/ffmpeg-4.1-dlopen-faac-mp3lame-opencore-x264-x265-xvid.patch b/ffmpeg-4.1-dlopen-faac-mp3lame-opencore-x264-x265-xvid.patch index 38e1de8..7382b4b 100644 --- a/ffmpeg-4.1-dlopen-faac-mp3lame-opencore-x264-x265-xvid.patch +++ b/ffmpeg-4.1-dlopen-faac-mp3lame-opencore-x264-x265-xvid.patch @@ -141,16 +141,6 @@ Index: ffmpeg-4.1.3/libavcodec/libfdk-aacdec.c =================================================================== --- ffmpeg-4.1.3.orig/libavcodec/libfdk-aacdec.c +++ ffmpeg-4.1.3/libavcodec/libfdk-aacdec.c -@@ -17,7 +17,9 @@ - * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. - */ - -+#ifndef CONFIG_LIBFDK_AAC_DLOPEN - #include -+#endif - - #include "libavutil/channel_layout.h" - #include "libavutil/common.h" @@ -37,6 +39,54 @@ #define AAC_PCM_MAX_OUTPUT_CHANNELS AAC_PCM_OUTPUT_CHANNELS #endif From 61d3999e3d1546cb48d232833d390281f3eef4f3e33df9499ce828dc8d1f6f6d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ismail=20D=C3=B6nmez?= Date: Thu, 4 Jul 2019 12:18:23 +0000 Subject: [PATCH 3/4] - Add back pkgconfig(fdk-aac) BuildRequires since we still need the headers at compile time. - Fix include paths in ffmpeg-4.1-dlopen-faac-mp3lame-opencore-x264-x265-xvid.patch OBS-URL: https://build.opensuse.org/package/show/multimedia:libs/ffmpeg-4?expand=0&rev=75 --- ...open-faac-mp3lame-opencore-x264-x265-xvid.patch | 14 +++++++------- ffmpeg-4.changes | 8 ++++++++ ffmpeg-4.spec | 3 +++ 3 files changed, 18 insertions(+), 7 deletions(-) diff --git a/ffmpeg-4.1-dlopen-faac-mp3lame-opencore-x264-x265-xvid.patch b/ffmpeg-4.1-dlopen-faac-mp3lame-opencore-x264-x265-xvid.patch index 7382b4b..916d362 100644 --- a/ffmpeg-4.1-dlopen-faac-mp3lame-opencore-x264-x265-xvid.patch +++ b/ffmpeg-4.1-dlopen-faac-mp3lame-opencore-x264-x265-xvid.patch @@ -83,7 +83,7 @@ Index: ffmpeg-4.1.3/configure enabled libfdk_aac && { check_pkg_config libfdk_aac fdk-aac "fdk-aac/aacenc_lib.h" aacEncOpen || { require libfdk_aac fdk-aac/aacenc_lib.h aacEncOpen -lfdk-aac && warn "using libfdk without pkg-config"; } } -+enabled libfdk_aac_dlopen && enable libfdk_aac && add_cppflags "-I$(dirname `readlink -f $0`)/localinc" ++enabled libfdk_aac_dlopen && enable libfdk_aac && add_cppflags "-I/usr/include/fdk-aac" flite_extralibs="-lflite_cmu_time_awb -lflite_cmu_us_awb -lflite_cmu_us_kal -lflite_cmu_us_kal16 -lflite_cmu_us_rms -lflite_cmu_us_slt -lflite_usenglish -lflite_cmulex -lflite" enabled libflite && require libflite "flite/flite.h" flite_init $flite_extralibs enabled fontconfig && enable libfontconfig @@ -91,16 +91,16 @@ Index: ffmpeg-4.1.3/configure { require libmfx "mfx/mfxvideo.h" MFXInit "-llibmfx $advapi32_extralibs" && warn "using libmfx without pkg-config"; } } enabled libmodplug && require_pkg_config libmodplug libmodplug libmodplug/modplug.h ModPlug_Load enabled libmp3lame && require "libmp3lame >= 3.98.3" lame/lame.h lame_set_VBR_quality -lmp3lame $libm_extralibs -+enabled libmp3lame_dlopen && enable libmp3lame && add_cppflags "-I$(dirname `readlink -f $0`)/localinc" ++enabled libmp3lame_dlopen && enable libmp3lame && add_cppflags "-I/usr/include/lame" enabled libmysofa && { check_pkg_config libmysofa libmysofa mysofa.h mysofa_load || require libmysofa mysofa.h mysofa_load -lmysofa $zlib_extralibs; } enabled libnpp && { check_lib libnpp npp.h nppGetLibVersion -lnppig -lnppicc -lnppc -lnppidei || check_lib libnpp npp.h nppGetLibVersion -lnppi -lnppc -lnppidei || die "ERROR: libnpp not found"; } enabled libopencore_amrnb && require libopencore_amrnb opencore-amrnb/interf_dec.h Decoder_Interface_init -lopencore-amrnb -+enabled libopencore_amrnb_dlopen && enable libopencore_amrnb && add_cppflags "-I$(dirname `readlink -f $0`)/localinc" ++enabled libopencore_amrnb_dlopen && enable libopencore_amrnb && add_cppflags "-I/usr/include/opencore-amrnb" enabled libopencore_amrwb && require libopencore_amrwb opencore-amrwb/dec_if.h D_IF_init -lopencore-amrwb -+enabled libopencore_amrwb_dlopen && enable libopencore_amrwb && add_cppflags "-I$(dirname `readlink -f $0`)/localinc" ++enabled libopencore_amrwb_dlopen && enable libopencore_amrwb && add_cppflags "-I/usr/include/opencore-amrwb" enabled libopencv && { check_headers opencv2/core/core_c.h && { check_pkg_config libopencv opencv opencv2/core/core_c.h cvCreateImageHeader || require libopencv opencv2/core/core_c.h cvCreateImageHeader -lopencv_core -lopencv_imgproc; } || @@ -108,14 +108,14 @@ Index: ffmpeg-4.1.3/configure warn "using libx264 without pkg-config"; } } && require_cpp_condition libx264 x264.h "X264_BUILD >= 118" && check_cpp_condition libx262 x264.h "X264_MPEG2" -+enabled libx264_dlopen && enable libx264 && add_cppflags "-I$(dirname `readlink -f $0`)/localinc" ++enabled libx264_dlopen && enable libx264 enabled libx265 && require_pkg_config libx265 x265 x265.h x265_api_get && require_cpp_condition libx265 x265.h "X265_BUILD >= 68" -+enabled libx265_dlopen && enable libx265 && add_cppflags "-I$(dirname `readlink -f $0`)/localinc" ++enabled libx265_dlopen && enable libx265 enabled libxavs && require libxavs "stdint.h xavs.h" xavs_encoder_encode "-lxavs $pthreads_extralibs $libm_extralibs" enabled libxavs2 && require_pkg_config libxavs2 "xavs2 >= 1.2.77" "stdint.h xavs2.h" xavs2_api_get enabled libxvid && require libxvid xvid.h xvid_global -lxvidcore -+enabled libxvid_dlopen && enable libxvid && add_cppflags "-I$(dirname `readlink -f $0`)/localinc" ++enabled libxvid_dlopen && enable libxvid enabled libzimg && require_pkg_config libzimg "zimg >= 2.7.0" zimg.h zimg_get_api_version enabled libzmq && require_pkg_config libzmq libzmq zmq.h zmq_ctx_new enabled libzvbi && require_pkg_config libzvbi zvbi-0.2 libzvbi.h vbi_decoder_new && diff --git a/ffmpeg-4.changes b/ffmpeg-4.changes index 5c0213e..84d4492 100644 --- a/ffmpeg-4.changes +++ b/ffmpeg-4.changes @@ -1,3 +1,11 @@ +------------------------------------------------------------------- +Tue Jul 2 09:04:55 UTC 2019 - Ismail Dönmez + +- Add back pkgconfig(fdk-aac) BuildRequires since we still need + the headers at compile time. +- Fix include paths in + ffmpeg-4.1-dlopen-faac-mp3lame-opencore-x264-x265-xvid.patch + ------------------------------------------------------------------- Tue Jun 11 11:12:43 UTC 2019 - Ismail Dönmez diff --git a/ffmpeg-4.spec b/ffmpeg-4.spec index 7278530..8779052 100644 --- a/ffmpeg-4.spec +++ b/ffmpeg-4.spec @@ -207,6 +207,9 @@ BuildRequires: pkgconfig(zimg) %endif BuildRequires: pkgconfig(zlib) BuildRequires: pkgconfig(zvbi-0.2) >= 0.2.28 +%if %{with fdk_aac_dlopen} +BuildRequires: pkgconfig(fdk-aac) +%endif %if %{with librtmp} BuildRequires: pkgconfig(librtmp) %endif From acbe2814fda0e912d5d4fa089605ea83f97d0575aae3eddd6e68e852b807b17f Mon Sep 17 00:00:00 2001 From: Jan Engelhardt Date: Sat, 6 Jul 2019 22:46:19 +0000 Subject: [PATCH 4/4] Accepting request 713762 from home:iznogood:branches:multimedia:libs - Add pkgconfig(libva-drm), pkgconfig(libva-x11) BuildRequires: and conditional pkgconfig(libmfx) BuildRequires: Build intel-mediasdk support when possible. OBS-URL: https://build.opensuse.org/request/show/713762 OBS-URL: https://build.opensuse.org/package/show/multimedia:libs/ffmpeg-4?expand=0&rev=76 --- ffmpeg-4.changes | 7 +++++++ ffmpeg-4.spec | 12 ++++++++++++ 2 files changed, 19 insertions(+) diff --git a/ffmpeg-4.changes b/ffmpeg-4.changes index 84d4492..2d313be 100644 --- a/ffmpeg-4.changes +++ b/ffmpeg-4.changes @@ -1,3 +1,10 @@ +------------------------------------------------------------------- +Sat Jul 6 21:43:04 UTC 2019 - Bjørn Lie + +- Add pkgconfig(libva-drm), pkgconfig(libva-x11) BuildRequires: and + conditional pkgconfig(libmfx) BuildRequires: Build intel-mediasdk + support when possible. + ------------------------------------------------------------------- Tue Jul 2 09:04:55 UTC 2019 - Ismail Dönmez diff --git a/ffmpeg-4.spec b/ffmpeg-4.spec index 8779052..eebc29c 100644 --- a/ffmpeg-4.spec +++ b/ffmpeg-4.spec @@ -165,6 +165,8 @@ BuildRequires: pkgconfig(libraw1394) BuildRequires: pkgconfig(libssh) BuildRequires: pkgconfig(libv4l2) BuildRequires: pkgconfig(libva) >= 0.35.0 +BuildRequires: pkgconfig(libva-drm) +BuildRequires: pkgconfig(libva-x11) BuildRequires: pkgconfig(libwebp) >= 0.4 BuildRequires: pkgconfig(libxml-2.0) %if %{with zmq} @@ -202,6 +204,11 @@ BuildRequires: pkgconfig(xcb-shm) BuildRequires: pkgconfig(xcb-xfixes) BuildRequires: pkgconfig(xext) BuildRequires: pkgconfig(xfixes) +%if 0%{?suse_version} >= 1550 +%ifarch x86_64 +BuildRequires: pkgconfig(libmfx) +%endif +%endif %if %{with zimg} BuildRequires: pkgconfig(zimg) %endif @@ -666,6 +673,11 @@ LDFLAGS="%_lto_cflags" \ %endif %if %{with lv2} --enable-lv2 \ +%endif +%if 0%{?suse_version} >= 1550 +%ifarch x86_64 + --enable-libmfx \ +%endif %endif --enable-vaapi \ --enable-vdpau \