gnu: x265: Update to 3.4.
* gnu/packages/patches/x265-arm-flags.patch: Update patch. * gnu/packages/video.scm (x265): Update to 3.4. [arguments]: Remove obsolete substitution. Disable the newly-added assembly optimizations on AArch64, as they are not implemented for all targets we build.
parent
cd03e2cb2f
commit
afdc16d904
|
@ -1,4 +1,7 @@
|
||||||
https://sources.debian.org/src/x265/2.9-3/debian/patches/0001-Fix-arm-flags.patch/
|
Fix build flags for ARMv7.
|
||||||
|
|
||||||
|
Taken from Debian:
|
||||||
|
https://salsa.debian.org/multimedia-team/x265/-/blob/master/debian/patches/0001-Fix-arm-flags.patch
|
||||||
|
|
||||||
From: Sebastian Ramacher <sramacher@debian.org>
|
From: Sebastian Ramacher <sramacher@debian.org>
|
||||||
Date: Wed, 26 Apr 2017 22:05:06 +0200
|
Date: Wed, 26 Apr 2017 22:05:06 +0200
|
||||||
|
@ -9,23 +12,20 @@ Subject: Fix arm* flags
|
||||||
1 file changed, 1 insertion(+), 5 deletions(-)
|
1 file changed, 1 insertion(+), 5 deletions(-)
|
||||||
|
|
||||||
diff --git a/source/CMakeLists.txt b/source/CMakeLists.txt
|
diff --git a/source/CMakeLists.txt b/source/CMakeLists.txt
|
||||||
index 33b6523..25aecbb 100644
|
|
||||||
--- a/source/CMakeLists.txt
|
--- a/source/CMakeLists.txt
|
||||||
+++ b/source/CMakeLists.txt
|
+++ b/source/CMakeLists.txt
|
||||||
@@ -72,7 +72,7 @@ elseif(ARMMATCH GREATER "-1")
|
@@ -77,7 +77,7 @@ elseif(ARMMATCH GREATER "-1")
|
||||||
endif()
|
add_definitions(-DX265_ARCH_ARM=1 -DX265_ARCH_ARM64=1 -DHAVE_ARMV6=0)
|
||||||
|
else()
|
||||||
message(STATUS "Detected ARM target processor")
|
message(STATUS "Detected ARM target processor")
|
||||||
set(ARM 1)
|
- add_definitions(-DX265_ARCH_ARM=1 -DX265_ARCH_ARM64=0 -DHAVE_ARMV6=1)
|
||||||
- add_definitions(-DX265_ARCH_ARM=1 -DHAVE_ARMV6=1)
|
+ add_definitions(-DX265_ARCH_ARM=1)
|
||||||
+ # add_definitions(-DX265_ARCH_ARM=1 -DHAVE_ARMV6=1)
|
endif()
|
||||||
else()
|
else()
|
||||||
message(STATUS "CMAKE_SYSTEM_PROCESSOR value `${CMAKE_SYSTEM_PROCESSOR}` is unknown")
|
message(STATUS "CMAKE_SYSTEM_PROCESSOR value `${CMAKE_SYSTEM_PROCESSOR}` is unknown")
|
||||||
message(STATUS "Please add this value near ${CMAKE_CURRENT_LIST_FILE}:${CMAKE_CURRENT_LIST_LINE}")
|
@@ -252,10 +252,7 @@ if(GCC)
|
||||||
@@ -230,12 +230,8 @@ if(GCC)
|
else()
|
||||||
if(ARM AND CROSS_COMPILE_ARM)
|
find_package(Neon)
|
||||||
set(ARM_ARGS -march=armv6 -mfloat-abi=soft -mfpu=vfp -marm -fPIC)
|
|
||||||
elseif(ARM)
|
|
||||||
- find_package(Neon)
|
|
||||||
if(CPU_HAS_NEON)
|
if(CPU_HAS_NEON)
|
||||||
- set(ARM_ARGS -mcpu=native -mfloat-abi=hard -mfpu=neon -marm -fPIC)
|
- set(ARM_ARGS -mcpu=native -mfloat-abi=hard -mfpu=neon -marm -fPIC)
|
||||||
add_definitions(-DHAVE_NEON)
|
add_definitions(-DHAVE_NEON)
|
||||||
|
@ -33,4 +33,4 @@ index 33b6523..25aecbb 100644
|
||||||
- set(ARM_ARGS -mcpu=native -mfloat-abi=hard -mfpu=vfp -marm)
|
- set(ARM_ARGS -mcpu=native -mfloat-abi=hard -mfpu=vfp -marm)
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
add_definitions(${ARM_ARGS})
|
endif()
|
||||||
|
|
|
@ -611,7 +611,7 @@ available.")
|
||||||
(define-public x265
|
(define-public x265
|
||||||
(package
|
(package
|
||||||
(name "x265")
|
(name "x265")
|
||||||
(version "3.3")
|
(version "3.4")
|
||||||
(outputs '("out" "static"))
|
(outputs '("out" "static"))
|
||||||
(source
|
(source
|
||||||
(origin
|
(origin
|
||||||
|
@ -621,7 +621,7 @@ available.")
|
||||||
(string-append "https://download.videolan.org/videolan/x265/"
|
(string-append "https://download.videolan.org/videolan/x265/"
|
||||||
"x265_" version ".tar.gz")))
|
"x265_" version ".tar.gz")))
|
||||||
(sha256
|
(sha256
|
||||||
(base32 "170b61cgpcs5n35qps0p40dqs1q81vkgagzbs4zv7pzls6718vpj"))
|
(base32 "0wl62hfsdqpf3r3z3s6l9bz7pdb1rcik5ll00b3yaadplqipy162"))
|
||||||
(patches (search-patches "x265-arm-flags.patch"))
|
(patches (search-patches "x265-arm-flags.patch"))
|
||||||
(modules '((guix build utils)))
|
(modules '((guix build utils)))
|
||||||
(snippet '(begin
|
(snippet '(begin
|
||||||
|
@ -638,8 +638,7 @@ available.")
|
||||||
#:configure-flags
|
#:configure-flags
|
||||||
;; Ensure position independent code for everyone.
|
;; Ensure position independent code for everyone.
|
||||||
(list "-DENABLE_PIC=TRUE"
|
(list "-DENABLE_PIC=TRUE"
|
||||||
,@(if (string-prefix? "armhf" (or (%current-system)
|
,@(if (target-arm?)
|
||||||
(%current-target-system)))
|
|
||||||
'("-DENABLE_ASSEMBLY=OFF")
|
'("-DENABLE_ASSEMBLY=OFF")
|
||||||
'())
|
'())
|
||||||
(string-append "-DCMAKE_INSTALL_PREFIX="
|
(string-append "-DCMAKE_INSTALL_PREFIX="
|
||||||
|
@ -650,9 +649,6 @@ available.")
|
||||||
(lambda _
|
(lambda _
|
||||||
(delete-file-recursively "build")
|
(delete-file-recursively "build")
|
||||||
(chdir "source")
|
(chdir "source")
|
||||||
;; recognize armv8 in 32-bit mode as ARM
|
|
||||||
(substitute* "CMakeLists.txt"
|
|
||||||
(("armv6l") "armv8l"))
|
|
||||||
#t))
|
#t))
|
||||||
(add-before 'configure 'build-12-bit
|
(add-before 'configure 'build-12-bit
|
||||||
(lambda* (#:key (configure-flags '()) #:allow-other-keys)
|
(lambda* (#:key (configure-flags '()) #:allow-other-keys)
|
||||||
|
|
Reference in New Issue