[PATCH 0/2] x265: Link all library variants.

  • Done
  • quality assurance status badge
Details
One participant
  • Efraim Flashner
Owner
unassigned
Submitted by
Efraim Flashner
Severity
normal
E
E
Efraim Flashner wrote on 29 Oct 08:31 +0100
(address . guix-patches@gnu.org)(name . Efraim Flashner)(address . efraim@flashner.co.il)
cover.1730186934.git.efraim@flashner.co.il
I've been working on and off on this for several years, and I finally
managed to link together all the library variants from this package.
That's the default 8-bit and the 10- and 12-bit variants.

Efraim Flashner (2):
gnu: x265: Only build with nasm on x86_64-linux.
gnu: x265: Link together all library variants.

gnu/packages/video.scm | 29 ++++++++++++++---------------
1 file changed, 14 insertions(+), 15 deletions(-)


base-commit: 4491dec50a97dbdebd7dd6d41a5596358b155b79
--
Efraim Flashner <efraim@flashner.co.il> ????? ?????
GPG key = A28B F40C 3E55 1372 662D 14F7 41AA E7DC CA3D 8351
Confidentiality cannot be guaranteed on emails sent or received unencrypted
E
E
Efraim Flashner wrote on 29 Oct 08:32 +0100
[PATCH 1/2] gnu: x265: Only build with nasm on x86_64-linux.
(address . 74079@debbugs.gnu.org)(name . Efraim Flashner)(address . efraim@flashner.co.il)
d3f81a9301478158a774a85a3bb461cb1f4b50c6.1730186934.git.efraim@flashner.co.il
* gnu/packages/video.scm (x265)[native-inputs]: Only use nasm when
building for x86_64-linux.

Change-Id: Id47f8bef4df0aef6cf574a39e4509024bb3a9479
---
gnu/packages/video.scm | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)

Toggle diff (21 lines)
diff --git a/gnu/packages/video.scm b/gnu/packages/video.scm
index 92c0acef3ca..bb07a21e981 100644
--- a/gnu/packages/video.scm
+++ b/gnu/packages/video.scm
@@ -1317,9 +1317,9 @@ (define-public x265
(build-system cmake-build-system)
(native-inputs
;; XXX: ASM optimization fails on i686-linux, see <https://bugs.gnu.org/41768>.
- (if (string-prefix? "i686" (%current-system))
- '()
- `(("nasm" ,nasm))))
+ (if (target-x86-64?)
+ (list nasm)
+ '()))
(arguments
`(#:tests? #f ; tests are skipped if ENABLE_ASSEMBLY is TRUE.
#:configure-flags
--
Efraim Flashner <efraim@flashner.co.il> ????? ?????
GPG key = A28B F40C 3E55 1372 662D 14F7 41AA E7DC CA3D 8351
Confidentiality cannot be guaranteed on emails sent or received unencrypted
E
E
Efraim Flashner wrote on 29 Oct 08:32 +0100
[PATCH 2/2] gnu: x265: Link together all library variants.
(address . 74079@debbugs.gnu.org)(name . Efraim Flashner)(address . efraim@flashner.co.il)
5ef0d25dc28ffa266a2c5f036627df4f040cef35.1730186934.git.efraim@flashner.co.il
* gnu/packages/video.scm (x265)[arguments]: Adjust the 'configure-flags
to link the 10bit and 12bit variants of the libraries. Adjust the
'build-12-bit and 'build-10-bit phases to not build the shared
libraries. Remove 'install-more-libs phase.

Change-Id: I338e9a3d216e35e6e38fe6ccfd29236d14054306
---
gnu/packages/video.scm | 23 +++++++++++------------
1 file changed, 11 insertions(+), 12 deletions(-)

Toggle diff (73 lines)
diff --git a/gnu/packages/video.scm b/gnu/packages/video.scm
index bb07a21e981..d9ac0a22806 100644
--- a/gnu/packages/video.scm
+++ b/gnu/packages/video.scm
@@ -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"))
--
Efraim Flashner <efraim@flashner.co.il> ????? ?????
GPG key = A28B F40C 3E55 1372 662D 14F7 41AA E7DC CA3D 8351
Confidentiality cannot be guaranteed on emails sent or received unencrypted
E
E
Efraim Flashner wrote 6 days ago
Re: bug#74079: Acknowledgement ([PATCH 0/2] x265: Link all library variants.)
(address . 74079-done@debbugs.gnu.org)
Z2QW-BWlLoXMbaOJ@3900XT
Patches pushed to the rust-team branch.

--
Efraim Flashner <efraim@flashner.co.il> ????? ?????
GPG key = A28B F40C 3E55 1372 662D 14F7 41AA E7DC CA3D 8351
Confidentiality cannot be guaranteed on emails sent or received unencrypted
-----BEGIN PGP SIGNATURE-----

iQIzBAABCAAdFiEEoov0DD5VE3JmLRT3Qarn3Mo9g1EFAmdkFvUACgkQQarn3Mo9
g1FCfA/9FjyI9UhEt33HcVSEdj1zapxUdWbSahbrdwFaxEVP6d+OzIha3RvJMO8B
AYKTFbfcRE2yALdgFXuUZpG7H0yo1ZUOQa2ZH5KPraOkCaz6oL66ypP3mnr8ezQ9
ShK/SXwR1ZIJuKB/9hhgRm2OJV6Jyj45+NeJbm1nA9edMaMvWoGq1+W5iqCtC+51
kfY6nD1Wdnzpih88yZS64x/dw4MG92u09m0fKijNZEX+uotQhEayM/S2ZiitkJkn
HMh2wJw+6pNi3GvSzeZP4xO0XGwThlPXozuBN4oH5qvDScWtKqwMx1/9debgR0Mx
tvnPUB/Op0j0x9fGJe1W8vBLXp/8vakmdhBCDj10iAdbfHypVKN2cdFdqolzF4on
abf1c8nEK9azUUTfFTkNWkO9YZ8obo7xL0qaR9RwWAElMuAzYeRlla9pxJc3z+5J
bQ1i9U+ZNG/+LRa6MqQc+3zR8XlbreKlV8xrUxORf9Fni2u/pTGWfcErAtESyQLP
JPIinCL79DGNxWir0WHU2uVuaL5uFYWDVqgGRg6JT6SfHsIjUv8g2sJ4DoKCUeXA
qm9CQfI8rcsigtvVLgHIjEgTtjJK2h/PjSlMv45pEwimynaxX7PTMR0SBFmmTz/o
LyWzW1QkWlXirZGIw6QQWzfDbH+6u0dSiN0mEGDHYgnWe+nNz2A=
=kmAY
-----END PGP SIGNATURE-----


Closed
?
Your comment

Commenting via the web interface is currently disabled.

To comment on this conversation send an email to 74079@debbugs.gnu.org

To respond to this issue using the mumi CLI, first switch to it
mumi current 74079
Then, you may apply the latest patchset in this issue (with sign off)
mumi am -- -s
Or, compose a reply to this issue
mumi compose
Or, send patches to this issue
mumi send-email *.patch