@@ -1323,8 +1323,11 @@ (define-public x265
(arguments
`(#:tests? #f ; tests are skipped if ENABLE_ASSEMBLY is TRUE.
#:configure-flags
- ;; Ensure position independent code for everyone.
(list "-DENABLE_PIC=TRUE"
+ "-DLINKED_10BIT=ON"
+ "-DLINKED_12BIT=ON"
+ "-DEXTRA_LIB=x265_main10.a;x265_main12.a"
+ "-DEXTRA_LINK_FLAGS=-L../build-10bit -L../build-12bit"
(string-append "-DCMAKE_INSTALL_PREFIX="
(assoc-ref %outputs "out")))
#:phases
@@ -1343,7 +1346,7 @@ (define-public x265
(lambda* (#:key (configure-flags '()) #:allow-other-keys #:rest args)
(mkdir "../build-12bit")
(with-directory-excursion "../build-12bit"
- (apply invoke
+ (invoke
"cmake" "../source"
,@(if (target-aarch64?)
'("-DENABLE_ASSEMBLY=OFF")
@@ -1355,8 +1358,9 @@ (define-public x265
"-DHIGH_BIT_DEPTH=ON"
"-DEXPORT_C_API=OFF"
"-DENABLE_CLI=OFF"
- "-DMAIN12=ON"
- configure-flags)
+ "-DENABLE_SHARED=OFF"
+ "-DENABLE_PIC=TRUE"
+ "-DMAIN12=ON")
(substitute* (cons "cmake_install.cmake"
(append
(find-files "CMakeFiles/x265-shared.dir")
@@ -1367,7 +1371,7 @@ (define-public x265
(lambda* (#:key (configure-flags '()) #:allow-other-keys #:rest args)
(mkdir "../build-10bit")
(with-directory-excursion "../build-10bit"
- (apply invoke
+ (invoke
"cmake" "../source"
,@(if (target-aarch64?)
'("-DENABLE_ASSEMBLY=OFF")
@@ -1379,19 +1383,14 @@ (define-public x265
"-DHIGH_BIT_DEPTH=ON"
"-DEXPORT_C_API=OFF"
"-DENABLE_CLI=OFF"
- configure-flags)
+ "-DENABLE_SHARED=OFF"
+ "-DENABLE_PIC=TRUE")
(substitute* (cons "cmake_install.cmake"
(append
(find-files "CMakeFiles/x265-shared.dir")
(find-files "CMakeFiles/x265-static.dir")))
(("libx265") "libx265_main10"))
((assoc-ref %standard-phases 'build)))))
- (add-after 'install 'install-more-libs
- (lambda args
- (with-directory-excursion "../build-12bit"
- ((assoc-ref %standard-phases 'install)))
- (with-directory-excursion "../build-10bit"
- ((assoc-ref %standard-phases 'install)))))
(add-before 'strip 'move-static-libs
(lambda* (#:key outputs #:allow-other-keys)
(let ((out (assoc-ref outputs "out"))