diff --git a/.gitignore b/.gitignore index dfb6aee..b9b4b92 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,2 @@ /SVT-HEVC-1.4.1.tar.gz +/SVT-HEVC-1.4.3.tar.gz diff --git a/d313b632ede3c47945e42289672c08013bc6a56f.patch b/d313b632ede3c47945e42289672c08013bc6a56f.patch deleted file mode 100644 index 2fbec2e..0000000 --- a/d313b632ede3c47945e42289672c08013bc6a56f.patch +++ /dev/null @@ -1,55 +0,0 @@ -From d313b632ede3c47945e42289672c08013bc6a56f Mon Sep 17 00:00:00 2001 -From: Austin Hu -Date: Thu, 19 Sep 2019 06:28:28 +0800 -Subject: [PATCH] Don't compile the binaries as executable stack. - -Signed-off-by: Austin Hu ---- - Source/Lib/ASM_SSE2/x64Macro.asm | 14 ++++++++++++++ - Source/Lib/ASM_SSE2/x64inc.asm | 14 ++++++++++++++ - 2 files changed, 28 insertions(+) - -diff --git a/Source/Lib/ASM_SSE2/x64Macro.asm b/Source/Lib/ASM_SSE2/x64Macro.asm -index eaeeac61..7dcb9038 100644 ---- a/Source/Lib/ASM_SSE2/x64Macro.asm -+++ b/Source/Lib/ASM_SSE2/x64Macro.asm -@@ -28,3 +28,17 @@ - punpckl%1 xmm%8, xmm%9 ; 67 66 65 64 63 62 61 60 73 63 72 62 71 61 70 60 75 65 55 45 74 64 54 44 76 66 56 46 36 26 16 06 - punpckh%1 xmm%13, xmm%9 ; 77 76 75 74 73 72 71 70 77 67 76 66 75 65 74 64 77 67 57 47 76 66 56 46 77 67 57 47 37 27 17 07 - %endmacro -+ -+%define FORMAT_ELF 0 -+%ifidn __OUTPUT_FORMAT__,elf -+ %define FORMAT_ELF 1 -+%elifidn __OUTPUT_FORMAT__,elf32 -+ %define FORMAT_ELF 1 -+%elifidn __OUTPUT_FORMAT__,elf64 -+ %define FORMAT_ELF 1 -+%endif -+ -+; This is needed for ELF, otherwise the GNU linker assumes the stack is executable by default. -+%if FORMAT_ELF -+ [SECTION .note.GNU-stack noalloc noexec nowrite progbits] -+%endif -diff --git a/Source/Lib/ASM_SSE2/x64inc.asm b/Source/Lib/ASM_SSE2/x64inc.asm -index 4440b060..a884545b 100644 ---- a/Source/Lib/ASM_SSE2/x64inc.asm -+++ b/Source/Lib/ASM_SSE2/x64inc.asm -@@ -323,3 +323,17 @@ bits 64 - %endif - %endmacro - %define NEED_EMMS 1 -+ -+%define FORMAT_ELF 0 -+%ifidn __OUTPUT_FORMAT__,elf -+ %define FORMAT_ELF 1 -+%elifidn __OUTPUT_FORMAT__,elf32 -+ %define FORMAT_ELF 1 -+%elifidn __OUTPUT_FORMAT__,elf64 -+ %define FORMAT_ELF 1 -+%endif -+ -+; This is needed for ELF, otherwise the GNU linker assumes the stack is executable by default. -+%if FORMAT_ELF -+ [SECTION .note.GNU-stack noalloc noexec nowrite progbits] -+%endif diff --git a/sources b/sources index ce172f9..800c627 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (SVT-HEVC-1.4.1.tar.gz) = 0a41068e7ecbb7d7ec2bd709bfb8b8da3028dbdc7c5c52d1e5bc689722c61fc359312c55ab1b043c9a0d7e8957fce43075f6ec1b24363b0551e4b17c12b5a30f +SHA512 (SVT-HEVC-1.4.3.tar.gz) = 93ab43c05b1dc7154f08d848e3ac2dd1ec5ee278abbb022718e8c8601efa4a25179144dbf0c9950da4c27052a53604d37edec471fce46b309e3c84eb99dd88c4 diff --git a/svt-hevc-build.patch b/svt-hevc-build.patch new file mode 100644 index 0000000..a972876 --- /dev/null +++ b/svt-hevc-build.patch @@ -0,0 +1,34 @@ +diff -uNdr SVT-HEVC-1.4.3_orig/CMakeLists.txt SVT-HEVC-1.4.3/CMakeLists.txt +--- SVT-HEVC-1.4.3_orig/CMakeLists.txt 2019-12-14 23:28:40.000000000 +0300 ++++ SVT-HEVC-1.4.3/CMakeLists.txt 2019-12-30 11:09:01.437899907 +0300 +@@ -119,8 +119,7 @@ + endif() + endif() + set(release_flags_to_test +- -O2 +- -O3) ++ -O2) + set(debug_flags_to_test + -O0) + +diff -uNdr SVT-HEVC-1.4.3_orig/gstreamer-plugin/meson.build SVT-HEVC-1.4.3/gstreamer-plugin/meson.build +--- SVT-HEVC-1.4.3_orig/gstreamer-plugin/meson.build 2019-12-14 23:28:40.000000000 +0300 ++++ SVT-HEVC-1.4.3/gstreamer-plugin/meson.build 2019-12-30 11:09:01.446899587 +0300 +@@ -17,7 +17,6 @@ + plugins_install_dir = '@0@/gstreamer-1.0'.format(get_option('libdir')) + + # common meson configuration +-svthevcenc_dep = dependency('SvtHevcEnc') + + cc = meson.get_compiler('c') + cc_flags = [ +@@ -47,7 +46,7 @@ + + gstSvtHevcEnc = library('gstsvthevcenc', + 'gstsvthevcenc.c', +- dependencies: [gstbase_dep, gstpbutils_dep , gstvideo_dep, svthevcenc_dep], +- install: true, ++ dependencies: [gstbase_dep, gstpbutils_dep , gstvideo_dep], ++ install: true, include_directories : include_directories('../Source/API'), link_args : '-lSvtHevcEnc', + install_dir: plugins_install_dir + ) diff --git a/svt-hevc.spec b/svt-hevc.spec index eb13db2..948e763 100644 --- a/svt-hevc.spec +++ b/svt-hevc.spec @@ -1,13 +1,13 @@ Name: svt-hevc -Version: 1.4.1 -Release: 2%{?dist} +Version: 1.4.3 +Release: 1%{?dist} Summary: Scalable Video Technology for HEVC Encoder License: BSD-2-Clause-Patent URL: https://github.com/OpenVisualCloud/SVT-HEVC Source0: %url/archive/v%{version}/SVT-HEVC-%{version}.tar.gz -# https://github.com/OpenVisualCloud/SVT-HEVC/issues/364 -Patch0: d313b632ede3c47945e42289672c08013bc6a56f.patch +# Correct build flags and gstreamer plugin +Patch0: svt-hevc-build.patch BuildRequires: gcc BuildRequires: cmake @@ -48,11 +48,6 @@ This package provides %{name}-based GStreamer plug-in. %prep %autosetup -p1 -n SVT-HEVC-%{version} -# Remove unneeded flags -sed -i 's|-O3)|)|' CMakeLists.txt -# Patch build gstreamer plugin -sed -e "s|install: true,|install: true, include_directories : include_directories('../Source/API'), link_args : '-lSvtHevcEnc',|" \ --e "/svthevcenc_dep =/d" -e 's|, svthevcenc_dep||' -e "s|svthevcenc_dep.found()|true|" -i gstreamer-plugin/meson.build %build @@ -93,6 +88,9 @@ popd %{_libdir}/gstreamer-1.0/libgstsvthevcenc.so %changelog +* Mon Dec 30 2019 Vasiliy Glazov - 1.4.3-1 +- Update to 1.4.3 + * Tue Sep 17 2019 Vasiliy Glazov - 1.4.1-2 - Correct build gstreamer plugin